Compare commits
No commits in common. "91ed1abe655ac270be4e6f6c006af6fa4edd25bf" and "25a90c1b33d76845252fdd9381e5b114604253b5" have entirely different histories.
91ed1abe65
...
25a90c1b33
|
@ -93,11 +93,13 @@ in
|
|||
in
|
||||
mapAttrsToList
|
||||
(name: peer: {
|
||||
wireguardPeerConfig = {
|
||||
PublicKey = peer.wireguardKey;
|
||||
AllowedIPs = [ peer.ipv4 peer.ipv6 ]
|
||||
++ optionals peer.isRouter [ "10.127.0.0/16" "fd70:81ca:0f8f::/48" ];
|
||||
Endpoint = mkIf (canDirectPeer host peer) "${peer.endpoint}:${toString peer.port}";
|
||||
PersistentKeepalive = mkIf (peer.subnet != host.subnet) cfg.persistentKeepalive;
|
||||
};
|
||||
})
|
||||
(filterAttrs (name: peer: peer != host && (canDirectPeer host peer || canDirectPeer peer host)) hosts);
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue