Files
no-secrets-athq-ansible/roles/monitoring-master/tasks/logs.yaml

32 lines
579 B
YAML

- name: Copy telegraf-key
copy:
src: influxdb.key
dest: /etc/apt/trusted.gpg.d/influxdb.asc
mode: 0644
notify:
apt update
- name: Add Influx repo
copy:
src: influxdb.list
dest: /etc/apt/sources.list.d/influxdb.list
mode: 0644
notify:
apt update
- meta: flush_handlers
- name: Install Telegraf
apt:
pkg:
- telegraf
- name: Copy telegraf config files
template:
src: "{{ item }}"
dest: /etc/telegraf/telegraf.d/
with_items:
- telegraf_influxdb.conf
- telegraf_rsyslog_input.conf
notify: restart telegraf