mirror of
https://github.com/jhd3197/ServerKit.git
synced 2026-11-09 05:24:49 +09:00
#3 managed_dns_records ledger (migration 026) — the single source of truth for records ServerKit created in a connected provider zone, written by every write path (zones page, DDNS, WordPress auto-DNS, email). #4 DnsOwnershipService.guarded_upsert/guarded_delete: automatic paths refuse to overwrite or delete a record ServerKit didn't create (the user's own records), while the explicit Zones page adopts a matching record and takes ownership. Wired into both CF paths (DNSZoneService._cloudflare_sync and DNSProviderService._cloudflare_set_record/_delete_record). ensure_a_record now surfaces a 'foreign_record' reason instead of clobbering. #5 Live zone mirror: CloudflareClient.list_records + DNSZoneService.list_provider_records classify every live record as serverkit vs external; GET /api/v1/dns/<id>/mirror. Tests: test_dns_ownership.py. Existing set_record mocks updated for the new source kwarg. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>