Added disnix hook options
svn path=/nixos/trunk/; revision=12596
This commit is contained in:
parent
4c3627f16e
commit
c5fea583e2
@ -1534,6 +1534,16 @@ in
|
||||
default = false;
|
||||
description = "Whether to enable Disnix";
|
||||
};
|
||||
|
||||
activateHook = mkOption {
|
||||
default = "";
|
||||
description = "Custom script or executable that activates services through Disnix";
|
||||
};
|
||||
|
||||
deactivateHook = mkOption {
|
||||
default = "";
|
||||
description = "Custom script or executable that deactivates services through Disnix";
|
||||
};
|
||||
};
|
||||
|
||||
httpd = {
|
||||
|
@ -19,6 +19,6 @@ in
|
||||
sleep 3
|
||||
end script
|
||||
|
||||
respawn ${pkgs.bash}/bin/sh -c 'export PATH=/var/run/current-system/sw/bin:$PATH; export HOME=/root; ${pkgs.disnix}/bin/disnix-service'
|
||||
respawn ${pkgs.bash}/bin/sh -c 'export PATH=/var/run/current-system/sw/bin:$PATH; export HOME=/root; export DISNIX_ACTIVATE=${cfg.activateHook}; export DISNIX_DEACTIVATE_HOOK=${cfg.deactivateHook}; ${pkgs.disnix}/bin/disnix-service'
|
||||
'';
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user