HEDNS: support init command#4289
Conversation
Register CredsMetadata so the HEDNS provider appears in the `dnscontrol init` wizard. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
| DisplayName: "Hurricane Electric DNS", | ||
| Kind: providers.KindDNS, | ||
| DocsURL: "https://docs.dnscontrol.org/provider/hedns", | ||
| PortalURL: "https://dns.he.net/", // TODO: Verify |
There was a problem hiding this comment.
Yes, this is the correct URL, I'm not sure why this is TODO as this is very easy to verify, was this Claude submission actually reviewed?
| { | ||
| Key: "username", | ||
| Label: "Username", | ||
| Help: "Your dns.he.net account username.", |
There was a problem hiding this comment.
I would change this (as the account is broader than just DNS):
| Help: "Your dns.he.net account username.", | |
| Help: "Your Hurricane Electric account username.", |
| { | ||
| Key: "password", | ||
| Label: "Password", | ||
| Help: "Your dns.he.net account password.", |
There was a problem hiding this comment.
| Help: "Your dns.he.net account password.", | |
| Help: "Your Hurricane Electric account password.", |
| { | ||
| Key: "session-file-path", | ||
| Label: "Session file path (optional)", | ||
| Help: "Path to a directory where the .hedns-session file is stored to reuse the authenticated session. Leave blank to log in each run.", | ||
| }, |
There was a problem hiding this comment.
For this, I'd be inclined to set the default to ., as without this the user will get the suprising behaviour only being able to issue one command every 30 seconds if TOTP is enabled.
| { | |
| Key: "session-file-path", | |
| Label: "Session file path (optional)", | |
| Help: "Path to a directory where the .hedns-session file is stored to reuse the authenticated session. Leave blank to log in each run.", | |
| }, | |
| { | |
| Key: "session-file-path", | |
| Label: "Session file path (optional)", | |
| Help: "Path to a directory where the .hedns-session file is stored to reuse the authenticated session. Leave blank to log in each run.", | |
| Default: ".", | |
| }, |
While this is slightly less secure, it is documented in the associated documentation, and since this is for the init getting started workflow, I would favour useability in this instance.
|
Thanks for the submission, mostly looks good with a some minor suggestions/alterations. |
Summary
Register
CredsMetadatafor HEDNS so the provider is offered by thednscontrol initwizard.Fields mirror the entries in
integrationTest/profiles.json.CC: @rblenkinsopp
Test plan
go build ./...passesdnscontrol initlists HEDNS as an option// TODO: Verifyannotations in the diff (e.g.PortalURL)🤖 Generated with Claude Code