Add template for the x509 input plugin
Related-PROD: PROD-26137 (PROD:26137)
Change-Id: I3a6b896de58c20f899a4bc19dca5f4170706f804
diff --git a/telegraf/files/input/_tls.conf b/telegraf/files/input/_tls.conf
new file mode 100644
index 0000000..1ffa77c
--- /dev/null
+++ b/telegraf/files/input/_tls.conf
@@ -0,0 +1,12 @@
+{%- if values.tls_ca is defined %}
+ tls_ca = values.tls_ca
+{%- endif %}
+{%- if values.tls_cert is defined %}
+ tls_cert = values.tls_cert
+{%- endif %}
+{%- if values.tls_key is defined %}
+ tls_key = values.tls_key
+{%- endif %}
+{%- if values.insecure_skip_verify is defined %}
+ insecure_skip_verify = values.insecure_skip_verify
+{%- endif %}
diff --git a/telegraf/files/input/x509.conf b/telegraf/files/input/x509.conf
new file mode 100644
index 0000000..aa82a8f
--- /dev/null
+++ b/telegraf/files/input/x509.conf
@@ -0,0 +1,10 @@
+[[inputs.x509_cert]]
+{%- include 'telegraf/files/input/_common.conf' %}
+{%- if values.sources is defined %}
+ sources = {{ values.sources }}
+{%- endif %}
+{%- if values.timeout is defined %}
+ timeout = "{{ values.timeout }}"
+{%- endif %}
+{%- include 'telegraf/files/input/_tls.conf' %}
+{%- include 'telegraf/files/input/_filters.conf' %}