haproxy::dns: fully-qualify halb CNAME targets #489

Merged
benvin merged 1 commits from benvin/halb-cname-fqdn into develop 2026-07-19 01:37:06 +10:00
Owner

Why

The halb publishes service CNAMEs (git.unkin.net, dashboard.ceph.unkin.net, and every other halb-fronted name) with a bare target label, e.g.:

git.unkin.net.  300  IN  CNAME  au-syd1-prod-halb-vrrp.

dns-updater builds the RR with dns.NewRR and no $ORIGIN, so a bare value becomes root-absolute (au-syd1-prod-halb-vrrp.) and dead-ends in NXDOMAIN. Once the k8s bind became authoritative for these zones, that broke resolution of every halb-fronted service (git, the Ceph dashboard, ...). au-syd1-prod-halb-vrrp.unkin.net / .main.unkin.net resolve fine (198.18.19.17) — only the CNAME target was truncated.

Change (site/profiles/manifests/haproxy/dns.pp)

Emit fully-qualified CNAME targets (trailing dot), the FQDN form dns-updater expects (per its own test fixture au-syd1-prod-halb.main.unkin.net.):

  • vrrp cnames: ${location_environment}-halb-vrrp.${domain}.
  • non-vrrp cnames: ${location_environment}-halb.${domain}.

The matching A records are already published in main.unkin.net/unkin.net just above, so the targets resolve to the VIP.

## Why The halb publishes service CNAMEs (`git.unkin.net`, `dashboard.ceph.unkin.net`, and every other halb-fronted name) with a **bare target label**, e.g.: ``` git.unkin.net. 300 IN CNAME au-syd1-prod-halb-vrrp. ``` `dns-updater` builds the RR with `dns.NewRR` and **no $ORIGIN**, so a bare value becomes root-absolute (`au-syd1-prod-halb-vrrp.`) and dead-ends in NXDOMAIN. Once the k8s bind became authoritative for these zones, that broke resolution of every halb-fronted service (git, the Ceph dashboard, ...). `au-syd1-prod-halb-vrrp.unkin.net` / `.main.unkin.net` resolve fine (198.18.19.17) — only the CNAME target was truncated. ## Change (`site/profiles/manifests/haproxy/dns.pp`) Emit **fully-qualified** CNAME targets (trailing dot), the FQDN form `dns-updater` expects (per its own test fixture `au-syd1-prod-halb.main.unkin.net.`): - vrrp cnames: `${location_environment}-halb-vrrp.${domain}.` - non-vrrp cnames: `${location_environment}-halb.${domain}.` The matching A records are already published in `main.unkin.net`/`unkin.net` just above, so the targets resolve to the VIP.
unkinben added 1 commit 2026-07-19 00:46:26 +10:00
haproxy::dns: fully-qualify halb CNAME targets
ci/woodpecker/pr/puppet-lint Pipeline was successful
ci/woodpecker/pr/ruby-validate Pipeline was successful
ci/woodpecker/pr/yamllint Pipeline was successful
ci/woodpecker/pr/bolt-validate Pipeline was successful
ci/woodpecker/pr/erb-validate Pipeline was successful
ci/woodpecker/pr/epp-validate Pipeline was successful
ci/woodpecker/pr/puppet-validate Pipeline was successful
ci/woodpecker/pr/ruby-check Pipeline was successful
318d30808c
The halb published service CNAMEs (git.unkin.net, dashboard.ceph.unkin.net, ...)
with a bare target label ("au-syd1-prod-halb-vrrp"). dns-updater parses the
record value with no $ORIGIN, so a bare label becomes root-absolute
("au-syd1-prod-halb-vrrp.") and dead-ends in NXDOMAIN -- breaking every
halb-fronted name once the k8s bind became authoritative.

Emit fully-qualified targets (trailing dot) for both the vrrp and non-vrrp
CNAMEs, matching the FQDN value dns-updater expects:
- au-syd1-prod-halb-vrrp.<domain>. and au-syd1-prod-halb.<domain>.
benvin merged commit 918c4f20e1 into develop 2026-07-19 01:37:06 +10:00
benvin deleted branch benvin/halb-cname-fqdn 2026-07-19 01:37:07 +10:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: unkin/puppet-prod#489