2019-04-12 17:14:25 +00:00
|
|
|
---
|
2021-08-18 12:38:32 +00:00
|
|
|
- name: Converge
|
|
|
|
hosts: all
|
|
|
|
roles:
|
|
|
|
- ansible-role-influxdb
|
2019-04-12 17:14:25 +00:00
|
|
|
vars:
|
2021-08-18 13:57:48 +00:00
|
|
|
influxdb_api_password: password
|
2019-04-12 17:14:25 +00:00
|
|
|
influxdb_users:
|
2021-08-18 13:57:48 +00:00
|
|
|
- name: '{{ influxdb_api_user }}'
|
|
|
|
password: '{{ influxdb_api_password }}'
|
2019-04-12 17:14:25 +00:00
|
|
|
admin: yes
|
2021-08-18 12:38:32 +00:00
|
|
|
- name: test
|
2019-04-12 17:14:25 +00:00
|
|
|
password: test2
|
2021-08-18 13:30:41 +00:00
|
|
|
grants:
|
|
|
|
- database: test_db
|
|
|
|
privilege: WRITE
|
2021-08-18 12:38:32 +00:00
|
|
|
- name: user_absent
|
2019-04-12 17:14:25 +00:00
|
|
|
state: absent
|
|
|
|
influxdb_databases:
|
2021-08-18 12:38:32 +00:00
|
|
|
- test_db
|
2019-04-12 17:14:25 +00:00
|
|
|
influxdb_config:
|
|
|
|
'[collectd]':
|
|
|
|
enabled: true
|
|
|
|
port: 25826
|
|
|
|
database: collectd
|
|
|
|
typesdb: /usr/share/collectd/types.db
|
|
|
|
|
|
|
|
pre_tasks:
|
2021-08-18 12:38:32 +00:00
|
|
|
- name: update apt cache
|
|
|
|
ansible.builtin.apt:
|
|
|
|
update_cache: true
|
|
|
|
|
2019-04-12 17:14:25 +00:00
|
|
|
- name: install collectd package
|
2021-08-18 12:38:32 +00:00
|
|
|
ansible.builtin.package:
|
|
|
|
name:
|
|
|
|
- collectd-core
|