diff options
author | Valérian Galliat <val@codejam.info> | 2016-04-11 09:35:28 -0400 |
---|---|---|
committer | Valérian Galliat <val@codejam.info> | 2016-04-11 09:58:52 -0400 |
commit | 26dc7e503da14c3142541a3a741303e745d4ab33 (patch) | |
tree | ce98877216f7b7a573bbb085d74ef1b4c60d1c3d /nixos/modules/services/networking/shout.nix | |
parent | e8b3532d26c15f308c4b597128da8b3b9554e932 (diff) | |
download | nixlib-26dc7e503da14c3142541a3a741303e745d4ab33.tar nixlib-26dc7e503da14c3142541a3a741303e745d4ab33.tar.gz nixlib-26dc7e503da14c3142541a3a741303e745d4ab33.tar.bz2 nixlib-26dc7e503da14c3142541a3a741303e745d4ab33.tar.lz nixlib-26dc7e503da14c3142541a3a741303e745d4ab33.tar.xz nixlib-26dc7e503da14c3142541a3a741303e745d4ab33.tar.zst nixlib-26dc7e503da14c3142541a3a741303e745d4ab33.zip |
Shout: fix infinite loop in service configuration
Fixes #14594.
Diffstat (limited to 'nixos/modules/services/networking/shout.nix')
-rw-r--r-- | nixos/modules/services/networking/shout.nix | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/nixos/modules/services/networking/shout.nix b/nixos/modules/services/networking/shout.nix index 761ecbcd173d..3664c2857739 100644 --- a/nixos/modules/services/networking/shout.nix +++ b/nixos/modules/services/networking/shout.nix @@ -11,7 +11,7 @@ let mv config.js $out ''; - configFile = if (cfg.configFile != null) then cfg.configFile else '' + finalConfigFile = if (cfg.configFile != null) then cfg.configFile else '' var _ = require('${pkgs.shout}/lib/node_modules/shout/node_modules/lodash') module.exports = _.merge( @@ -48,7 +48,7 @@ in { configFile = mkOption { type = types.nullOr types.lines; - default = configFile; + default = null; description = '' Contents of Shout's <filename>config.js</filename> file. @@ -95,7 +95,7 @@ in { wantedBy = [ "multi-user.target" ]; wants = [ "network-online.target" ]; after = [ "network-online.target" ]; - preStart = "ln -sf ${pkgs.writeText "config.js" configFile} ${shoutHome}/config.js"; + preStart = "ln -sf ${pkgs.writeText "config.js" finalConfigFile} ${shoutHome}/config.js"; script = concatStringsSep " " [ "${pkgs.shout}/bin/shout" (if cfg.private then "--private" else "--public") |