This commit is contained in:
2024-06-14 10:38:25 +08:00
commit 133692dcb4
9 changed files with 159 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
- name: Install node-exporter from IPFS gateway
hosts: all
become: yes
user: root
tasks:
- name: Download the deb file from IPFS gateway
get_url:
url: http://192.168.1.13:8080/ipfs/QmeexpjtcrKDQhFdvMyVqQuBf7fNVurkzC1YWkFFDumDgj
dest: /tmp/node-exporter.deb
- name: Install the deb package
apt:
deb: /tmp/node-exporter.deb
- name: Clean up the deb file
file:
path: /tmp/node-exporter
state: absent
- name: Ensure node-exporter service is enabled and started
systemd:
name: node-exporter
enabled: yes
state: started