dns/ddclient: switch to usev[46] use for #3307

This commit is contained in:
Franco Fichtner
2023-04-13 08:40:14 +02:00
parent d315c19ee8
commit db794e2bf3
@@ -4,9 +4,7 @@ pid=/var/run/ddclient.pid # record PID in file.
{% if not helpers.empty('OPNsense.DynDNS.general.verbose') %}
verbose=yes
{% endif %}
{% if not helpers.empty('OPNsense.DynDNS.general.allowipv6') %}
ipv6=yes
{% endif %}
{% set accounts = [] %}
{% set force_ssl = [] %}
{% if helpers.exists('OPNsense.DynDNS.accounts.account') and OPNsense.DynDNS.general.backend|default('ddclient') == 'ddclient' %}
@@ -23,10 +21,12 @@ ipv6=yes
ssl=yes
{% endif %}
{% for account in accounts %}
{% if account.checkip == 'if' %}
use=if, if={{physical_interface(account.interface)}}, \
{% if account.checkip == 'if' %}
{% if not helpers.empty('OPNsense.DynDNS.general.allowipv6') %}
usev6=ifv6, \
{% endif %}
usev4=ifv4, if={{physical_interface(account.interface)}}, \
{% elif account.checkip.startswith('web_') %}
{% if account.interface %}
use=cmd, cmd="/usr/local/opnsense/scripts/ddclient/checkip -i {{physical_interface(account.interface)}} -t {{account.force_ssl}} -s {{account.checkip[4:]}} --timeout {{account.checkip_timeout|default('10')}}",