From f5d5c3e5387806cf95984ea91f15bb14c8972d76 Mon Sep 17 00:00:00 2001 From: Max Date: Thu, 4 Aug 2022 23:25:16 +0200 Subject: [PATCH] cluster/services/wireguard: add external etcd node to mesh net --- cluster/services/wireguard/mesh.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/cluster/services/wireguard/mesh.nix b/cluster/services/wireguard/mesh.nix index c154968..a2a7471 100644 --- a/cluster/services/wireguard/mesh.nix +++ b/cluster/services/wireguard/mesh.nix @@ -11,6 +11,13 @@ let allowedIPs = [ "${peerLink.extra.meshIp}/32" ] ++ peerLink.extra.extraRoutes; endpoint = peerLink.tuple; }; + extraPeers = [ + { + publicKey = "Veol/Yw5Nf3eZVSGynLZIuR2kvnyGynexzQ8GhdDQWo="; + allowedIPs = [ "10.1.1.151/32" ]; + endpoint = "pve-etcd-node-fb2465761cf3ce658e6b410bbcf1f2db.fly.dev:51280"; + } + ]; in { age.secrets.wireguard-key-core = { @@ -30,7 +37,7 @@ in ips = [ "${link.extra.meshIp}/24" ]; listenPort = link.port; privateKeyFile = config.age.secrets.wireguard-key-core.path; - peers = map mkPeer cluster.config.services.wireguard.otherNodes.mesh; + peers = map mkPeer cluster.config.services.wireguard.otherNodes.mesh ++ extraPeers; }; }; };