20 lines
730 B
Django/Jinja
20 lines
730 B
Django/Jinja
#jinja2: lstrip_blocks: "True", trim_blocks: "True"
|
|
# {{ ansible_managed }}
|
|
{% set definemerged = nft_define_default.copy() %}
|
|
{% set _ = definemerged.update(nft_define) %}
|
|
{% set _ = definemerged.update(nft_define_group) %}
|
|
{% if nft_merged_groups and hostvars[inventory_hostname]['nft_combined_rules'].nft_define_group is defined%}
|
|
{% set _ = definemerged.update(hostvars[inventory_hostname]['nft_combined_rules'].nft_define_group) %}
|
|
{% endif %}
|
|
{% set _ = definemerged.update(nft_define_host) %}
|
|
|
|
{% for definition in definemerged.values() %}
|
|
{% if definition.desc is defined %}
|
|
# {{ definition.desc }}
|
|
{% else %}
|
|
# {{ definition.name }}
|
|
{% endif %}
|
|
define {{ definition.name }} = {{ definition.value }}
|
|
|
|
{% endfor %}
|