dn42: fix wireguard
This commit is contained in:
parent
52387b4db7
commit
68f6b337c9
|
@ -70,12 +70,13 @@ in {
|
||||||
servers = builtins.mapAttrs (name: conf: mkServer name conf) openvpnNeighbors;
|
servers = builtins.mapAttrs (name: conf: mkServer name conf) openvpnNeighbors;
|
||||||
};
|
};
|
||||||
|
|
||||||
wireguard.interfaces =
|
networking.wireguard.enable = true;
|
||||||
|
networking.wireguard.interfaces =
|
||||||
let
|
let
|
||||||
wireguardNeighbors = lib.filterAttrs (_: conf: conf ? wireguard) neighbors;
|
wireguardNeighbors = lib.filterAttrs (_: conf: conf ? wireguard) neighbors;
|
||||||
in
|
in
|
||||||
builtins.mapAttrs (_: conf: {
|
builtins.mapAttrs (_: conf: {
|
||||||
inherit (conf.wireguard) privateKey;
|
inherit (conf.wireguard) listenPort privateKey;
|
||||||
ips = [ "${address4}/32" "${address6}/128" ];
|
ips = [ "${address4}/32" "${address6}/128" ];
|
||||||
peers = [ {
|
peers = [ {
|
||||||
inherit (conf.wireguard) endpoint publicKey;
|
inherit (conf.wireguard) endpoint publicKey;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user