Update template
Some checks reported errors
continuous-integration/drone/push Build encountered an error
Some checks reported errors
continuous-integration/drone/push Build encountered an error
This commit is contained in:
parent
ee12fbfcc8
commit
78f202b11f
2 changed files with 8 additions and 0 deletions
|
|
@ -13,5 +13,7 @@ wireguard_port: 51820
|
||||||
# wireguard_postdown:
|
# wireguard_postdown:
|
||||||
wireguard_persistent_keepalive: 20
|
wireguard_persistent_keepalive: 20
|
||||||
wireguard_save_config: true
|
wireguard_save_config: true
|
||||||
|
# wireguard_endpoint_port: "51820"
|
||||||
|
# wireguard_endpoint_ip: "x.x.x.x"
|
||||||
|
|
||||||
skip_conf: false
|
skip_conf: false
|
||||||
|
|
|
||||||
|
|
@ -53,7 +53,13 @@ AllowedIPs = {{hostvars[host].wireguard_allowed_ips}}
|
||||||
{% else %}
|
{% else %}
|
||||||
AllowedIPs = {{ hostvars[host].wireguard_address.split('/')[0] }}/32
|
AllowedIPs = {{ hostvars[host].wireguard_address.split('/')[0] }}/32
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
{% if hostvars[host].wireguard_endpoint_ip is defined and hostvars[host].wireguard_endpoint_port is defined %}
|
||||||
|
Endpoint = {{ hostvars[host].wireguard_endpoint_ip }}:{{ hostvars[host].wireguard_endpoint_port }}
|
||||||
|
{% elif hostvars[host].wireguard_endpoint_ip is defined %}
|
||||||
|
Endpoint = {{ hostvars[host].wireguard_endpoint_ip }}:{{ hostvars[host].wireguard_port }}
|
||||||
|
{% else %}
|
||||||
Endpoint = {{ hostvars[host].ansible_default_ipv4.address }}:{{ wireguard_port }}
|
Endpoint = {{ hostvars[host].ansible_default_ipv4.address }}:{{ wireguard_port }}
|
||||||
|
{% endif %}
|
||||||
{% if hostvars[host].wireguard_persistent_keepalive is defined %}
|
{% if hostvars[host].wireguard_persistent_keepalive is defined %}
|
||||||
PersistentKeepalive = {{hostvars[host].wireguard_persistent_keepalive}}
|
PersistentKeepalive = {{hostvars[host].wireguard_persistent_keepalive}}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue