ansible-core deprecates injecting top-level facts as variables (INJECT_FACTS_AS_VARS) and will stop doing so in 2.24. Convert all remaining bare fact references (ansible_default_ipv4/ipv6, os_family, distribution_release, date_time, ...) to the ansible_facts[] form. Also fixes a typo (ansbile_date_time) in the postfix backup task.
23 lines
842 B
Django/Jinja
Executable File
23 lines
842 B
Django/Jinja
Executable File
server:
|
|
ip-freebind: yes
|
|
{% if wg_local_ip is defined %}
|
|
interface: {{ wg_local_ip | ansible.utils.ipaddr('address') }}
|
|
{% else %}
|
|
interface: {{ ansible_facts['default_ipv4']['address'] }}
|
|
{% endif %}
|
|
interface: 127.0.0.1
|
|
interface: 127.0.0.53
|
|
interface: ::1
|
|
outgoing-interface: {{ ansible_facts['default_ipv4']['address'] }}
|
|
{% if ansible_facts['default_ipv6'] is defined %}
|
|
outgoing-interface: {{ ansible_facts['default_ipv6']['address'] }}
|
|
{% endif %}
|
|
access-control: 192.168.1.0/24 allow
|
|
access-control: 192.168.3.0/24 allow
|
|
access-control: 172.16.0.0/24 allow
|
|
extended-statistics: yes
|
|
statistics-cumulative: yes
|
|
|
|
remote-control:
|
|
control-enable: yes
|
|
control-interface: 127.0.0.1 |