18 lines
337 B
Nix
18 lines
337 B
Nix
{ lib, ... }:
|
|
|
|
|
|
let
|
|
vpnHosts = [
|
|
{ ip = "10.0.1.11"; hosts = [ "giggles.vpn" ]; }
|
|
{ ip = "10.0.1.12"; hosts = [ "cox.vpn" ]; }
|
|
{ ip = "10.0.1.13"; hosts = [ "companion.vpn" ]; }
|
|
];
|
|
|
|
mkVpnHosts = e: {${e.ip} = e.hosts;};
|
|
in
|
|
{
|
|
networking.hosts =
|
|
lib.attrsets.mergeAttrsList (builtins.map mkVpnHosts vpnHosts)
|
|
;
|
|
}
|