Skip to content

Commit

Permalink
Merge pull request #13 from romainbureau/master
Browse files Browse the repository at this point in the history
set telegraf hostname in defaults.
  • Loading branch information
dj-wasabi authored Sep 20, 2016
2 parents ec63b2a + ad1a443 commit b95a679
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

#telegraf_agent_version: 0.10.1
telegraf_agent_version: 1.0.0
telegraf_agent_hostname: "{{ ansible_fqdn }}"
telegraf_agent_version_sub_l: _beta2
telegraf_agent_version_sub_u: -beta2
telegraf_agent_interval: 10
Expand Down
4 changes: 2 additions & 2 deletions templates/telegraf.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
[agent]
interval = "{{ telegraf_agent_interval }}s"
debug = {{ telegraf_agent_debug | lower }}
hostname = "{{ ansible_fqdn }}"
hostname = "{{ telegraf_agent_hostname }}"
round_interval = {{ telegraf_agent_round_interval | lower }}
flush_interval = "{{ telegraf_agent_flush_interval }}s"
flush_jitter = "{{ telegraf_agent_flush_jitter }}s"
Expand Down Expand Up @@ -75,4 +75,4 @@
{% endfor %}
{% endif %}
{% endfor %}
{% endif %}
{% endif %}

0 comments on commit b95a679

Please sign in to comment.