Skip to content
Snippets Groups Projects
Commit ce5b5799 authored by Florian Sesser's avatar Florian Sesser
Browse files

Fix VPN key generation script

parent b429a91f
No related branches found
No related tags found
5 merge requests!315update production,!314update production,!313update production,!312update production,!306Fix VPN key generation script
Pipeline #2149 passed
...@@ -9,11 +9,9 @@ ...@@ -9,11 +9,9 @@
{ pathToGrid }: { pathToGrid }:
let let
grid = import pathToGrid; grid = import pathToGrid;
vpnConfig = node: node.services.private-storage.monitoring.vpn or null; vpnIP = node: node.config.grid.monitoringvpnIPv4 or null; # "or null" since "network" in grid doesn't have a monitoringIPv4
vpnClientIP = node: (vpnConfig node).client.ip or null; in rec
vpnServerIP = node: (vpnConfig node).server.ip or null;
in
{ {
"serverIP" = vpnServerIP grid.monitoring; serverIP = vpnIP grid.monitoring;
"clientIPs" = builtins.filter (x: x != null) (map vpnClientIP (builtins.attrValues grid)); clientIPs = builtins.filter (x: x != serverIP && x != null) (map vpnIP (builtins.attrValues grid));
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment