question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot manage subzones that are more than one level under parent

See original GitHub issue

When attempting to add NS records for a subzone that is more than one level under the parent zone OctoDNS refuses to add the record.

I would expect to be able to configure the zone in the parent zone add a zone between the parent and child.

domain.tld.yaml

---
zone.stg:
  ttl: 600
  type: NS
  values:
    - ns1.domain.tld
    - ns2.domain.tld

zone.stg.domain.tld.yaml

---
record:
  ttl: 60
  type: A
  values:
    - 1.2.3.4

stg.domain.tld.yaml does not exist, nor is stg.domain.tld. configured in OctoDNS config, nor does stg.domain.tld. exist in any DNS server.

Results in:

Traceback (most recent call last):
  File "/usr/local/bin/octodns-sync", line 11, in <module>
    load_entry_point('octodns', 'console_scripts', 'octodns-sync')()
  File "/octodns/octodns/cmds/sync.py", line 39, in main
    dry_run=not args.doit, force=args.force)
  File "/octodns/octodns/manager.py", line 302, in sync
    plans = [p for f in futures for p in f.result()]
  File "/octodns/octodns/manager.py", line 56, in result
    return self.func(*self.args, **self.kwargs)
  File "/octodns/octodns/manager.py", line 224, in _populate_and_plan
    source.populate(zone)
  File "/octodns/octodns/provider/yaml.py", line 77, in populate
    self._populate_from_file(filename, zone, lenient)
  File "/octodns/octodns/provider/yaml.py", line 62, in _populate_from_file
    zone.add_record(record, lenient=lenient)
  File "/octodns/octodns/zone.py", line 68, in add_record
    .format(record.fqdn))
octodns.zone.SubzoneRecordException: Record zone.stg.domain.tld. is under a managed subzone

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
nakatocommented, Jul 18, 2019

OctoDNS doesn’t really support adding NS records to subzones, except in the case of PowerDNS, where it is defined in the provider configuration. Issue #38 seems to contain the details on this, and a NS record on '' would be silently dropped anyways in zone.py

As I use PowerDNS, my Zone’s get their self-referencing NS ('') records set via the provider plugin, however this doesn’t create NS records in the parent zone pointing to the child zone. So while zone.stg.domain.tld works by luck of domain.tld being delegated to my nameserver, domain.tld is not able to appropriately delegate the nameservers of zone.stg.domain.tld.


Additionally, this config also demonstrates the issue, with the same crash.

domain.tld.yaml

stg:
  ttl: 600
  type: A
  value: 1.2.3.4

zone.stg.domain.tld.yaml

---
record:
  ttl: 60
  type: A
  values:
    - 1.2.3.4
0reactions
github-actions[bot]commented, Feb 5, 2022

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 7 days.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot manage subzones that are more than one level under ...
When attempting to add NS records for a subzone that is more than one level under the parent zone OctoDNS refuses to add...
Read more >
Parent Zones and Child Zones (Cut Nodes) in Managed DNS
A child zone is a separate, fully functional zone that is technically a subdomain of another zone. For example, it is possible to...
Read more >
Removing Zones - NIOS Admin Guide
You cannot remove a zone and reparent its subzones if at least one of the subzones is a delegated zone. You must first...
Read more >
Configure a hierarchy of teams - Azure DevOps - Microsoft Learn
In this article, we show how to configure teams that best support the different backlog views of management and feature teams.
Read more >
Creating a subdomain that uses Amazon Route 53 as the ...
For more information, see GetHostedZone in the Amazon Route 53 API Reference. Using the method provided by the DNS service of the parent...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found