deployment: added dns
This commit is contained in:
parent
fcc22aaf7d
commit
f19516a7a4
|
@ -0,0 +1,23 @@
|
|||
{config, pkgs, nixpkgs, system, dns, ...}:
|
||||
let
|
||||
util = dns.util.${system};
|
||||
in
|
||||
{
|
||||
networking.domain = "beherbergung.mission-lifeline.de";
|
||||
|
||||
services.bind = {
|
||||
enable = true;
|
||||
zones = {
|
||||
"${config.networking.domain}" = {
|
||||
master = true;
|
||||
file = util.writeZone "${config.networking.domain}" (import (./dns + "/${config.networking.domain}.nix") {inherit dns;});
|
||||
};
|
||||
"beherbergung.broenradio.org" = { ## not required in future (but till the NS-record of beherbergung.mission-lifeline.de is configured)
|
||||
master = true;
|
||||
file = util.writeZone "beherbergung.broenradio.org" (import (./dns + "/${config.networking.domain}.nix") {inherit dns;});
|
||||
};
|
||||
};
|
||||
};
|
||||
networking.firewall.allowedTCPPorts = [ 53 ];
|
||||
networking.firewall.allowedUDPPorts = [ 53 ];
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
{ dns, ... }:
|
||||
|
||||
with dns.lib.combinators; {
|
||||
SOA = {
|
||||
nameServer = #"ns1";
|
||||
"ns1.broenradio.org.";
|
||||
|
||||
adminEmail = "dns-admin@mission-lifeline.de";
|
||||
serial = 2022031001;
|
||||
};
|
||||
|
||||
NS = [
|
||||
#"ns1"
|
||||
#"ns2"
|
||||
"ns1.broenradio.org."
|
||||
"ns2.broenradio.org."
|
||||
];
|
||||
|
||||
A = [ "88.198.203.104" ];
|
||||
AAAA = [ "2a01:4f8:c0c:cf13::1" ];
|
||||
|
||||
subdomains = rec {
|
||||
server1 = host "88.198.203.104" "2a01:4f8:c0c:cf13::1";
|
||||
|
||||
ns1 = server1;
|
||||
ns2 = server1; ## TODO
|
||||
|
||||
backend = server1;
|
||||
search = server1;
|
||||
submission = server1;
|
||||
|
||||
binarycache = server1;
|
||||
grafana = server1;
|
||||
|
||||
prometheus-server1 = server1;
|
||||
loki-server1 = server1;
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue