From 7dfe7dd93842831934e61230432e75884dda812a Mon Sep 17 00:00:00 2001 From: Paul Lecuq Date: Fri, 10 Feb 2023 13:48:03 +0100 Subject: [PATCH] updated telegraf state --- states/telegraf/defaults.yaml | 1 + states/telegraf/telegraf.conf.j2 | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/states/telegraf/defaults.yaml b/states/telegraf/defaults.yaml index 0071e4f..42ea572 100644 --- a/states/telegraf/defaults.yaml +++ b/states/telegraf/defaults.yaml @@ -30,6 +30,7 @@ telegraf: - '"overlay"' - '"aufs"' - '"squashfs"' + - '"fuse.rclone"' diskio: httpjson: name: "ipinfo" diff --git a/states/telegraf/telegraf.conf.j2 b/states/telegraf/telegraf.conf.j2 index e76b3fb..aad5c41 100644 --- a/states/telegraf/telegraf.conf.j2 +++ b/states/telegraf/telegraf.conf.j2 @@ -1,7 +1,7 @@ ## {{ salt['pillar.get']('salt_managed', default='Salt Managed') }} {%- from "telegraf/map.jinja" import telegraf with context %} {% macro cfg(value) -%} -{% if value is not none -%} +{% if value -%} {% for paramname, paramvalue in value.items() -%} {{ ' ' }}{{ paramname }} = {% if paramvalue is sameas True or paramvalue is sameas False %}{{ paramvalue|string|lower }}{% elif paramvalue is iterable and paramvalue is not string %}[{{ paramvalue|join(",") }}]{% else %}"{{ paramvalue }}"{% endif %} {% endfor %}