1
0
mirror of https://github.com/kmein/niveum synced 2026-03-19 03:21:10 +01:00

feat(hu-berlin): update vpn certs and make vpns contradict each other

This commit is contained in:
2021-02-06 11:17:13 +01:00
parent 8e19069d4c
commit 6ef578d644

View File

@@ -63,17 +63,20 @@ in {
systemd.services.hu-vpn = { systemd.services.hu-vpn = {
enable = true; enable = true;
wants = [ "network-online.target" ]; wants = [ "network-online.target" ];
conflicts = [ "openvpn-hu-berlin.service" ];
script = '' script = ''
${pkgs.openfortivpn}/bin/openfortivpn -c ${pkgs.writeText "hu-berlin.config" '' ${pkgs.openfortivpn}/bin/openfortivpn -c ${pkgs.writeText "hu-berlin.config" ''
host = forti-ssl.vpn.hu-berlin.de host = forti-ssl.vpn.hu-berlin.de
port = 443 port = 443
trusted-cert = e5a7d56543002ffe1e8962caa5fd6d94053aa702381458247b670877a66f3c6f trusted-cert = 42193a913d276d9eb86217612956e1e6464d6f07bed5393a4787c87adc4bd359
username = ${eduroam.identity} username = ${eduroam.identity}
password = ${eduroam.password} password = ${eduroam.password}
''} ''}
''; '';
}; };
systemd.services.openvpn-hu-berlin.conflicts = [ "hu-vpn.service" ];
services.openvpn.servers.hu-berlin = { services.openvpn.servers.hu-berlin = {
autoStart = false; autoStart = false;
authUserPass = { authUserPass = {