netz39-infra-ansible/group-docker_host.yml
Alexander Dahl 57db3bf0ca 🐳 Add telegraf container for Docker metrics in influxdb
All our hosts running docker can put their metrics into our influxdb
now.

Note: not all docker hosts do this (yet), because the influxdb is
currently only reachable from within the local space internal network in
our rooms.

Link: https://docs.ansible.com/ansible/latest/inventory_guide/intro_patterns.html
Link: https://galaxy.ansible.com/lespocky/telegraf_docker_in_docker
References: #760
2023-01-10 06:26:14 +01:00

20 lines
531 B
YAML

---
- hosts: docker_host
become: true
roles:
- role: docker_setup
- hosts: docker_host:&location_space
become: true
roles:
- role: lespocky.telegraf_docker_in_docker
vars:
tdid_conf_dir: "/etc/telegraf"
tdid_influxdb_org: "{{ influxdb_org }}"
tdid_influx_token: "{{ vault_tdid_influx_token }}"
tdid_docker_image: "telegraf:1.24-alpine"
tdid_influxdb_url: "https://influx.n39.eu"
tdid_influxdb_bucket: "system_metrics"
tdid_timezone: "{{ timezone }}"