You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(deploy): find the mail record being replaced, not just apex ones
The previous commit replaced records selected from `listRecords(domain, type)`.
That is not a portable server-side filter: Porkbun implements it as
`retrieveByNameType` scoped to the zone apex, so a TXT listing returned the apex
SPF and omitted every subdomain record. `_dmarc` and `<selector>._domainkey`
read as absent, the replacement found nothing to remove, and it created a second
record beside the existing one.
Caught in production on theopentimes.org: the deploy meant to relax DMARC from
quarantine to none published `p=none` alongside the old `p=quarantine`. Two
DMARC records is not a redundant policy — RFC 7489 has receivers ignore the
policy entirely — so a change intended to soften enforcement removed DMARC
outright, while the zone looked more configured than before. The stale record
has been removed and the domain is back to a single p=none.
Selection now happens over a full zone listing, in `selectRecordsAt`, with
`zoneFqdn` normalizing the several ways providers spell a name (relative,
absolute, `@`, empty, mixed case) so the two sides of the comparison cannot
silently fail to match. Both are pure and covered.
A failed delete also no longer proceeds to the create. Leaving the zone
untouched is always better than half-replacing it, and an unchecked delete is
precisely what turns one bad response into a duplicate record.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
0 commit comments