A role for deploying and configuring Telegraf and extensions on unix hosts using Ansible.
Supported targets:
- Ubuntu 16.04 "Xenial"
- Debian 7 "Wheezy"
- Debian 8 "Jessie"
- Debian 9 "Stretch"
This roles comes preloaded with almost every available default. You can override each one in your hosts/group vars, in your inventory, or in your play. See the annotated defaults in defaults/main.yml
for help in configuration. All provided variables start with telegraf__
.
telegraf__
- desc
- eNiXHosting.influxdata-repo ansible role. Automatically pulled if you use ansible-galaxy.
Clone this repo into your roles directory:
$ git clone https://gitlab.enix.org/ansible/ansible-telegraf.git roles/telegraf
Or use Ansible galaxy requirements.yml
# telegraf from eNiXHosting
- src: eNiXHosting.telegraf
name: telegraf
And add it to your play's roles:
- hosts: all
roles:
- role telegraf:
telegraf__var: true
You can also use the role as a playbook. You will be asked which hosts to provision, and you can further configure the play by using --extra-vars
.
$ ansible-playbook -i inventory --extra-vars='{...}' main.yml
- Handle
[global_tags]
configuration - Handle
[agent]
configuration - Handle
[[outputs:influxdb]]
configuration - Handle plugins configuration using generic
/etc/telegraf/telegraf.d/
Prerelease with only installation
GPLv2
Laurent Corbes [email protected] - http://www.enix.fr