strongswan-swanctl: fix module by setting the new SWANCTL_DIR envvar

This commit is contained in:
Bas van Dijk 2019-03-08 15:59:21 +01:00 committed by Nikola Knezevic
parent 81042e810f
commit e44e2455d3

View File

@ -65,9 +65,12 @@ in {
after = [ "network-online.target" "keys.target" ]; after = [ "network-online.target" "keys.target" ];
wants = [ "keys.target" ]; wants = [ "keys.target" ];
path = with pkgs; [ kmod iproute iptables utillinux ]; path = with pkgs; [ kmod iproute iptables utillinux ];
environment.STRONGSWAN_CONF = pkgs.writeTextFile { environment = {
name = "strongswan.conf"; STRONGSWAN_CONF = pkgs.writeTextFile {
text = cfg.strongswan.extraConfig; name = "strongswan.conf";
text = cfg.strongswan.extraConfig;
};
SWANCTL_DIR = "/etc/swanctl";
}; };
restartTriggers = [ config.environment.etc."swanctl/swanctl.conf".source ]; restartTriggers = [ config.environment.etc."swanctl/swanctl.conf".source ];
serviceConfig = { serviceConfig = {