StackExchange / dnscontrol

Infrastructure as code for DNS!
https://dnscontrol.org/
MIT License
3.07k stars 389 forks source link

Preview of records if zone doesn't exist yet #3007

Open Koopzington opened 2 months ago

Koopzington commented 2 months ago

Could we make preview display the records that would be created even if the zone doesn't exist yet? Right now (at least for the Hetzner DNS Provider if that's relevant) i only get to see the created records when i push and let dnscontrol automatically create the zone. It would be nice if we could review them in the preview output first though.

tlimoncelli commented 2 months ago

Hi there!

I'm having difficulty reproducing this. Can you send me sample output?

Also, please include the output of dnscontrol version

Thanks!

Koopzington commented 2 months ago
var REG_NONE = NewRegistrar('none')
var DSP_HETZNER = NewDnsProvider('hetzner')

D('example.org', REG_NONE, DnsProvider(DSP_HETZNER),
    A('@', '127.0.0.1')
)

image Same result with a freshly pulled 4.12.0

tlimoncelli commented 2 months ago

Would you please try again with the ppreview command? I have a hunch this bug may not appear in the new code.

(ppreview is the future replacement for preview. it is a rewrite from scratch with many new features)

Koopzington commented 2 months ago

image