wg-home: remove dead code
This commit is contained in:
@@ -6,7 +6,6 @@
|
|||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.sane.services.wg-home;
|
cfg = config.sane.services.wg-home;
|
||||||
server-cfg = config.sane.hosts.by-name."servo".wg-home;
|
|
||||||
mkPeer = { ips, pubkey, endpoint }: {
|
mkPeer = { ips, pubkey, endpoint }: {
|
||||||
publicKey = pubkey;
|
publicKey = pubkey;
|
||||||
allowedIPs = builtins.map (k: if builtins.match ".*/.*" k != null then k else "${k}/32") ips;
|
allowedIPs = builtins.map (k: if builtins.match ".*/.*" k != null then k else "${k}/32") ips;
|
||||||
@@ -26,11 +25,6 @@ let
|
|||||||
inherit (p) pubkey endpoint;
|
inherit (p) pubkey endpoint;
|
||||||
ips = [ p.ip ];
|
ips = [ p.ip ];
|
||||||
}) hosts;
|
}) hosts;
|
||||||
# make a single peer which routes all the given hosts
|
|
||||||
mkServerPeer = hosts: mkPeer {
|
|
||||||
inherit (server-cfg) pubkey endpoint;
|
|
||||||
ips = (builtins.map (h: h.ip) hosts) ++ [ "0.0.0.0/0" ];
|
|
||||||
};
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options = with lib; {
|
options = with lib; {
|
||||||
|
Reference in New Issue
Block a user