!MthpOIxqJhTgrMNxDS:nixos.org

NixOS ACME / LetsEncrypt

115 Members
Another day, another cert renewal47 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
7 Feb 2024
@netpleb:matrix.orgnetpleb how do you guys install your zone? do you use something like environment.etc."bind/zones/example.com.zone".source = ./example.com.zone where ./example.com.zone is in the git repo (I am using flakes) 23:29:36
@netpleb:matrix.orgnetpleb * how do you guys install your zone? do you use something like environment.etc."bind/zones/example.com.zone".source = ./example.com.zone; where ./example.com.zone is in the git repo (I am using flakes) 23:29:50
8 Feb 2024
@netpleb:matrix.orgnetpleb finally fixed it...had to make a oneshot service that chmod --recursive named:named /etc/bind/zones so that named has permission to load some .jnl file which apparently it needs to do the acme stuff. 01:09:16
@symys:dailyaslbot.twilightparadox.comsymys joined the room.18:51:42
@netpleb:matrix.orgnetpleb to round this "issue" out for anyone else who comes along trying to figure out something similar: it turns out that when you follow the "fully self-hosted example using bind" in the manual, there is a subtle thing which probably goes unnoticed for many, namely
bind.zones.*.file = "/var/db/bind/${name}"; is in a directory which needs to be read/writable by bind. On my machine that directory had not yet even been created, and never actually was. This is because I had instead set bind.zones.*.file = ./zone-file-in-my-git-repo which means that Nix put the zone file into the nix store (which is fine as far as I am concerned) but the problem is that bind tries to create the .jnl file right next to it when doing the acme updates, which it obviously cannot do. So that is what threw the permission denied error which took a while to track down.
18:56:44
@netpleb:matrix.orgnetpleb so, in the end, what I am wondering is whether this is actually an issue with the bind package and module, and not the secruity.acme module. What do you guys think? 18:57:22
@netpleb:matrix.orgnetpleb * to round this "issue" out for anyone else who comes along trying to figure out something similar: it turns out that when you follow the "fully self-hosted example using bind" in the manual, there is a subtle thing which probably goes unnoticed for many, namely
bind.zones.*.file = "/var/db/bind/${name}"; is in a directory which needs to be read/writable by bind. On my machine that directory had not yet even been created, and never actually was. This is because I had instead set bind.zones.*.file = ./zone-file-in-my-git-repo which means that Nix put the zone file into the nix store (which is fine as far as I am concerned) but the problem is that bind tries to create the .jnl file right next to it when doing the acme updates, which it obviously cannot do. So that is what threw the permission denied error which took a while to track down. (and for which I am grateful to K900 ⚡️ for your patience in helping me get there!)
18:58:44

Show newer messages


Back to Room ListRoom Version: 6