Files
ansible-role-ddclient/templates/ddclient.conf.j2
T
patrick 9057c453ad fix: wire up exec, fw auth vars, and prune dead detection keys
- Template now emits `exec=` so ddclient_exec actually toggles dry-run (was documented and defaulted but never written to the config).
- Rename fw_login/fw_password defaults to ddclient_fw_login/ddclient_fw_password to match what the template reads; previous names were silently dead.
- Drop unused address/interface/command/skip keys from the ddclient_ipv{4,6}_detection defaults — the template only reads method/source/skip_pattern. Fix the `# Method:` comments to list the v4/v6-suffixed names actually in use.
2026-06-24 21:42:25 -04:00

102 lines
3.1 KiB
Django/Jinja
Executable File

# {{ ansible_managed }}
# /etc/ddclient.conf
# ============================================================
# Daemon Settings
# ============================================================
daemon={{ ddclient_daemon_interval }}
foreground={{ ddclient_foreground | ternary('yes', 'no') }}
{% if ddclient_pid %}
pid={{ ddclient_pid }}
{% endif %}
{% if ddclient_cache %}
cache={{ ddclient_cache }}
{% endif %}
# ============================================================
# Network Settings
# ============================================================
ssl={{ ddclient_ssl | ternary('yes', 'no') }}
{% if ddclient_proxy %}
proxy={{ ddclient_proxy }}
{% endif %}
{% if ddclient_timeout %}
timeout={{ ddclient_timeout }}
{% endif %}
# ============================================================
# Logging Settings
# ============================================================
syslog={{ ddclient_syslog | ternary('yes', 'no') }}
{% if ddclient_facility %}
facility={{ ddclient_facility }}
{% endif %}
{% if ddclient_priority %}
priority={{ ddclient_priority }}
{% endif %}
{% if ddclient_mail %}
mail={{ ddclient_mail }}
{% endif %}
{% if ddclient_mail_failure %}
mail-failure={{ ddclient_mail_failure }}
{% endif %}
verbose={{ ddclient_verbose | ternary('yes', 'no') }}
quiet={{ ddclient_quiet | ternary('yes', 'no') }}
debug={{ ddclient_debug | ternary('yes', 'no') }}
# ============================================================
# Update Behavior
# ============================================================
exec={{ ddclient_exec | ternary('yes', 'no') }}
retry={{ ddclient_retry | ternary('yes', 'no') }}
force={{ ddclient_force | ternary('yes', 'no') }}
{% if ddclient_postscript %}
postscript={{ ddclient_postscript }}
{% endif %}
# ============================================================
# IP Detection Method
# ============================================================
# Disable the legacy use setting
use=no
{% if ddclient_ipv4_detection is defined and ddclient_ipv4_detection %}
usev4={{ ddclient_ipv4_detection.method }}
{{ ddclient_ipv4_detection.method }}={{ ddclient_ipv4_detection.source }}
{% if ddclient_ipv4_detection.skip_pattern is defined %}
{{ ddclient_ipv4_detection.method }}-skip='{{ ddclient_ipv4_detection.skip_pattern }}'
{% endif %}
{% endif %}
{% if ddclient_ipv6_detection is defined and ddclient_ipv6_detection %}
usev6={{ ddclient_ipv6_detection.method }}
{{ ddclient_ipv6_detection.method }}={{ ddclient_ipv6_detection.source }}
{% if ddclient_ipv6_detection.skip_pattern is defined %}
{{ ddclient_ipv6_detection.method }}-skip='{{ ddclient_ipv6_detection.skip_pattern }}'
{% endif %}
{% endif %}
{% if ddclient_fw_login is defined %}
fw-login={{ ddclient_fw_login }}
{% if ddclient_fw_password is defined %}
fw-password={{ ddclient_fw_password }}
{% endif %}
{% endif %}
# ============================================================
# Protocol Configurations
# ============================================================
{% for proto in ddclient_protocols %}
{% for key, value in proto.items() %}
{% if key != 'domains' %}
{{ key }}={{ value }}
{% endif %}
{% endfor %}
{{ proto.domains | join(',') }}
{% endfor %}