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
This looks like a neat project. I'm struggling to figure out if it meets my use case.
My domain, example.com, has its DNS hosted with Cloudflare and I've created all the records with Pulumi. Unfortunately my Pulumi state got hosed so I'm looking to try migrating to this project.
I brought up a Nix server, hostname hub. I'd like to assign hub.example.com to its IP address declaratively. I have a flake-based config with each host in its own file. My initial goal is to try generating zone files to see if they look sensible/correct, then try working with cloudflare through octodns. I'm not sure which combination of baseDomains, subDomains and/or zones I need to pull this off. Here's what I have in flake.nix:
let
...
dnsConfig = {
# inherit nixosConfigurations;
extraConfig = import ./dns.nix;
};
in
...
packages = forAllSystems (
system:
let
generate = nixos-dns.utils.generate nixpkgs.legacyPackages.${system};
in
{
# nix build .#zoneFiles
zoneFiles = generate.zoneFiles dnsConfig;
}
);
When I build zones to sanity-check the result before trying to add octodns, I get an empty file. I can configure the zones if I make the config exactly like the example, but I'd rather not keep it all in dns.nix--I'd rather keep the config for each server with the server.
Here's what I don't get:
Is what I want possible with this project? (E.g. only configuring this specific subdomain and gradually migrating more domains over time.)
If so, what's the minimum I'd need to assign an A record to hub.example.com in a specific host configuration?
Can I generate a zone file with this config to sanity-check it first, or would that not work here? (E.g. maybe that only works if I'm configuring everything from the apex down?)
Thanks a bunch.
The text was updated successfully, but these errors were encountered:
Forgot to mention that I tried a few other variations of this, including putting subDomains directly in the host config. Everything I tried, except for just putting the records under zones in dns.nix, produced an empty zone file. So either I can't use that backend like this, or I'm configuring something wrong and don't know what combination I need.
This looks like a neat project. I'm struggling to figure out if it meets my use case.
My domain, example.com, has its DNS hosted with Cloudflare and I've created all the records with Pulumi. Unfortunately my Pulumi state got hosed so I'm looking to try migrating to this project.
I brought up a Nix server, hostname hub. I'd like to assign hub.example.com to its IP address declaratively. I have a flake-based config with each host in its own file. My initial goal is to try generating zone files to see if they look sensible/correct, then try working with cloudflare through octodns. I'm not sure which combination of baseDomains, subDomains and/or zones I need to pull this off. Here's what I have in flake.nix:
Then I have this dns.nix:
Then this individual host config:
When I build zones to sanity-check the result before trying to add octodns, I get an empty file. I can configure the zones if I make the config exactly like the example, but I'd rather not keep it all in dns.nix--I'd rather keep the config for each server with the server.
Here's what I don't get:
Thanks a bunch.
The text was updated successfully, but these errors were encountered: