Add prometheus-node-exporter role and add it to most hosts

This commit is contained in:
christian 2024-11-03 21:23:27 +01:00
parent 88b8d3b9ba
commit 261bd7d654
Signed by: c6ristian
SSH key fingerprint: SHA256:B3m+yzpaxGXSEcDBpPHfvza/DNC0wuX+CKMeGq8wgak
5 changed files with 47 additions and 2 deletions

View file

@ -108,6 +108,16 @@ all:
pretalx: pretalx:
wiki: wiki:
zammad: zammad:
prometheus_node_exporter_hosts:
hosts:
ccchoir:
tickets:
keycloak:
onlyoffice:
pad:
pretalx:
wiki:
zammad:
infrastructure_authorized_keys_hosts: infrastructure_authorized_keys_hosts:
hosts: hosts:
ccchoir: ccchoir:

View file

@ -82,6 +82,11 @@
roles: roles:
- nginx - nginx
- name: Ensure prometheus_node_exporter deployment on prometheus_node_exporter_hosts
hosts: prometheus_node_exporter_hosts
roles:
- prometheus_node_exporter
- name: Configure unattended upgrades - name: Configure unattended upgrades
hosts: all hosts: all
become: true become: true

View file

@ -98,9 +98,16 @@ scrape_configs:
- woodpecker-intern.hamburg.ccc.de:9100 - woodpecker-intern.hamburg.ccc.de:9100
- penpot-intern.hamburg.ccc.de:9100 - penpot-intern.hamburg.ccc.de:9100
- jitsi.hamburg.ccc.de:9100 - jitsi.hamburg.ccc.de:9100
# Wieske Physical Machines - onlyoffice-intern.hamburg.ccc.de:9100
- ccchoir-intern.hamburg.ccc.de:9100
- tickets-intern.hamburg.ccc.de:9100
- keycloak-intern.hamburg.ccc.de:9100
- onlyoffice-intern.hamburg.ccc.de:9100
- pad-intern.hamburg.ccc.de:9100
- wiki-intern.hamburg.ccc.de:9100
- zammad-intern.hamburg.ccc.de:9100
- labels: - labels:
site: wieske site: wieske
type: physical_machine type: physical_machine
targets: targets:
- chaosknoten.hamburg.ccc.de:9100 - chaosknoten.hamburg.ccc.de:9100

View file

@ -0,0 +1,9 @@
---
dependencies:
- role: distribution_check
vars:
distribution_check__distribution_support_spec:
- name: Debian
major_versions:
- "11"
- "12"

View file

@ -0,0 +1,14 @@
- name: make sure the `prometheus-node-exporter` package is installed
ansible.builtin.apt:
name: prometheus-node-exporter
state: present
allow_change_held_packages: true
update_cache: true
become: true
- name: make sure `prometheus-node-exporter.service` is started and ansibled
ansible.builtin.systemd:
name: prometheus-node-exporter.service
state: started
enabled: true
become: true