2020-01-24 16:16:23 +00:00
|
|
|
# Variables referenced two or more places in the configuration.
|
|
|
|
let
|
2020-04-28 18:08:59 +00:00
|
|
|
# Import computed host/interface data from vars.json.
|
2020-04-28 18:12:30 +00:00
|
|
|
gen = builtins.fromJSON (builtins.readFile ./vars.json);
|
2020-05-29 20:22:40 +00:00
|
|
|
server_ipv4 = gen.server_ipv4;
|
|
|
|
server_ipv6 = gen.server_ipv6;
|
2020-04-28 18:08:59 +00:00
|
|
|
hosts = gen.hosts;
|
|
|
|
interfaces = gen.interfaces;
|
2020-05-29 21:00:30 +00:00
|
|
|
wireguard = gen.wireguard;
|
2020-05-29 20:22:40 +00:00
|
|
|
|
2020-01-24 16:16:23 +00:00
|
|
|
in {
|
2020-04-27 18:27:17 +00:00
|
|
|
inherit server_ipv4;
|
|
|
|
inherit server_ipv6;
|
2020-04-28 18:08:59 +00:00
|
|
|
inherit hosts;
|
|
|
|
inherit interfaces;
|
2020-05-29 21:13:43 +00:00
|
|
|
inherit wireguard;
|
2020-04-27 18:27:17 +00:00
|
|
|
|
2020-01-04 22:16:31 +00:00
|
|
|
domain = "lan.servnerr.com";
|
|
|
|
localhost = {
|
|
|
|
ipv4 = "127.0.0.1";
|
|
|
|
ipv6 = "::1";
|
|
|
|
};
|
|
|
|
}
|