Commit 13ae3fd0 authored by Alfonso Tierno's avatar Alfonso Tierno
Browse files

parametrization of prometheus jinja2 template



it allows activating/desactivating blocks of prometheus jobs
by setting variables at begining

Signed-off-by: default avatartierno <alfonso.tiernosepulveda@telefonica.com>
parent 381ca211
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
{# change to 'true' or 'false' according to your requirements #}
{% set snmpexporter = true %}

{% if snmpexporter %}
-   job_name: '{{ JOB_NAME }}'
    static_configs:
      - targets:
@@ -12,4 +16,4 @@
        target_label: instance
      - target_label: __address__
        replacement: {{ EXPORTER_POD_IP }}:{{ EXPORTER_POD_PORT }}  # The SNMP exporter's real hostname:port.
{% endif %}