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 @@
{ pathToGrid }:
let
grid = import pathToGrid;
vpnConfig = node: node.services.private-storage.monitoring.vpn or null;
vpnClientIP = node: (vpnConfig node).client.ip or null;
vpnServerIP = node: (vpnConfig node).server.ip or null;
in
vpnIP = node: node.config.grid.monitoringvpnIPv4 or null; # "or null" since "network" in grid doesn't have a monitoringIPv4
in rec
{
"serverIP" = vpnServerIP grid.monitoring;
"clientIPs" = builtins.filter (x: x != null) (map vpnClientIP (builtins.attrValues grid));
serverIP = vpnIP grid.monitoring;
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.
Finish editing this message first!
Please register or to comment