From 04487ed6bf3a0d7e4119e75fa093071b49906bbd Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 19 Sep 2021 17:30:52 +0200 Subject: [PATCH] dns: Don't include subdomains stuff in dyndns update, because this probably ain't gonna work --- src/yunohost/dns.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/yunohost/dns.py b/src/yunohost/dns.py index d26cc3ca4..4ac62fb46 100644 --- a/src/yunohost/dns.py +++ b/src/yunohost/dns.py @@ -160,7 +160,14 @@ def _build_dns_conf(base_domain): ipv4 = get_public_ip() ipv6 = get_public_ip(6) - subdomains = _list_subdomains_of(base_domain) + # If this is a ynh_dyndns_domain, we're not gonna include all the subdomains in the conf + # Because dynette only accept a specific list of name/type + # And the wildcard */A already covers the bulk of use cases + if any(base_domain.endswith("." + ynh_dyndns_domain) for ynh_dyndns_domain in YNH_DYNDNS_DOMAINS): + subdomains = [] + else: + subdomains = _list_subdomains_of(base_domain) + domains_settings = {domain: domain_config_get(domain, export=True) for domain in [base_domain] + subdomains}