os/users/hensoko/hosts.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

18 lines
337 B
Nix
Raw Normal View History

2023-11-18 11:52:53 +00:00
{ 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)
;
}