mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-10 04:49:19 -08:00
29 lines
524 B
Nix
29 lines
524 B
Nix
{ config, lib, tf, pkgs, ... }:
|
|
|
|
{
|
|
kw.secrets.variables = {
|
|
katdns-key = {
|
|
path = "secrets/katdns";
|
|
field = "notes";
|
|
};
|
|
};
|
|
|
|
network.firewall.public = {
|
|
tcp.ports = [ 53 ];
|
|
udp.ports = [ 53 ];
|
|
};
|
|
|
|
secrets.files.katdns-keyfile = {
|
|
text = "${tf.variables.katdns-key.ref}";
|
|
owner = "knot";
|
|
group = "knot";
|
|
};
|
|
|
|
services.knot = {
|
|
enable = true;
|
|
extraConfig = builtins.readFile ./knot.yaml;
|
|
keyFiles = [
|
|
config.secrets.files.katdns-keyfile.path
|
|
];
|
|
};
|
|
}
|