The restored godaddy-dns.py implements list, get-a and add-a only, so an add-cname example was documenting a subcommand that does not exist -- the same failure mode as the script the doc used to point at. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
103 lines
3.2 KiB
Markdown
103 lines
3.2 KiB
Markdown
---
|
|
title: GoDaddy DNS Management
|
|
type: reference
|
|
tags:
|
|
- dns
|
|
aliases: []
|
|
related:
|
|
- [[caddy]]
|
|
- [[services]]
|
|
- [[expose-service-contabo]]
|
|
- [[usenet]]
|
|
- [[expose-service-edge2]]
|
|
updated: 2026-08-24
|
|
---
|
|
# GoDaddy DNS Management
|
|
|
|
## Script Location
|
|
|
|
`~/bin/godaddy-dns.py` on **cortex** (100.64.0.14). Restored 2026-08-24 — the
|
|
original copy was lost in a host rebuild and these docs pointed at a script
|
|
that no longer existed anywhere on the fleet for some time; that cost real
|
|
time mid-deploy. Python 3 standard library only, no pip installs.
|
|
|
|
## THE RECORD-SET TRAP
|
|
|
|
GoDaddy's API has two kinds of write endpoints for A records:
|
|
|
|
- `PUT /v1/domains/<domain>/records/A/<name>` — replaces only `<name>`. Safe.
|
|
- `PUT /v1/domains/<domain>/records/A` and `PUT /v1/domains/<domain>/records`
|
|
— **replace every record of that type on the whole domain.**
|
|
|
|
Both `k7zvx.com` and `echo6.co` front live production services (mail, auth,
|
|
forge, vpn, vault, matrix, element, and more). Calling one of the record-SET
|
|
endpoints to "add" a record would wipe every other A record on the zone.
|
|
`godaddy-dns.py` only ever uses the single-record endpoint to write, and does
|
|
not implement the record-set endpoints at all. `add-a` always reads the full
|
|
A-record list before and after and prints a diff, so you can see nothing
|
|
else changed.
|
|
|
|
## API Credentials
|
|
|
|
Stored in `/home/zvx/projects/.ref/credentials` as:
|
|
- `GODADDY_API_KEY`
|
|
- `GODADDY_API_SECRET`
|
|
|
|
## Key IPs for DNS Records
|
|
|
|
| Purpose | IP |
|
|
|---------|-----|
|
|
| External (home [[services]]) | `199.6.36.163` |
|
|
| edge1 (mail/autodiscover/autoconfig only — mail-only host, rebuilt [[2026-06-19]]) | `5.189.158.149` |
|
|
| edge2 (front door: auth/forge/vpn/vault/matrix/element/notes/proxmox) | `184.174.35.153` |
|
|
|
|
## Managed Domains
|
|
|
|
arclightvanguard.com, echo6.co, echo6.org, happylittlellc.com, idahomesh.com, k7zvx.com, lpmesh.com, maliceinwonderland.org, matthewwayne.com, smugglersden.co, underdogs.cc
|
|
|
|
## Subcommands
|
|
|
|
`godaddy-dns.py` currently supports A records only:
|
|
|
|
- `list <domain>` — list all A records for a domain
|
|
- `get-a <domain> <name>` — show the A record(s) for one name
|
|
- `add-a <domain> <name> <ip> [--ttl SECONDS] [--dry-run]` — add/update a
|
|
single A record via the safe single-record endpoint; prints a before/after
|
|
diff of the whole domain's A records
|
|
|
|
There is no CNAME/MX/delete/multi-domain support — add-a is add-or-update
|
|
(PUT to the single-record endpoint), and there is no destructive delete or
|
|
record-set command by design (see the trap above).
|
|
|
|
## Usage Examples
|
|
|
|
```bash
|
|
# List all A records for a domain
|
|
godaddy-dns.py list echo6.co
|
|
|
|
# Look up one record
|
|
godaddy-dns.py get-a echo6.co www
|
|
|
|
# Add/update an A record
|
|
godaddy-dns.py add-a echo6.co www 199.6.36.163
|
|
|
|
# Preview a change without writing anything
|
|
godaddy-dns.py add-a echo6.co www 199.6.36.163 --dry-run
|
|
```
|
|
|
|
## Common Patterns
|
|
|
|
### Point subdomain to home network
|
|
```bash
|
|
godaddy-dns.py add-a echo6.co newservice 199.6.36.163
|
|
```
|
|
|
|
### Point subdomain to edge2 (front door — auth, forge, vpn, vault, matrix, element, notes, proxmox)
|
|
```bash
|
|
godaddy-dns.py add-a echo6.co auth 184.174.35.153
|
|
```
|
|
|
|
### Point subdomain to edge1 (mail, autodiscover, autoconfig only)
|
|
```bash
|
|
godaddy-dns.py add-a echo6.co mail 5.189.158.149
|
|
```
|