summaryrefslogtreecommitdiffstats
path: root/nixos
diff options
context:
space:
mode:
authorDomen Kožar <domen@dev.si>2014-10-19 15:49:08 +0200
committerDomen Kožar <domen@dev.si>2014-10-19 15:49:55 +0200
commit0854836fd2a1f6ac183e41bf49eba27725936273 (patch)
tree70a9c7ca3f93df1595e6fd6ba2cace9c6cff012e /nixos
parent36b981933f2a28cbfaacc5a0a87c8c8f1e8b4241 (diff)
systemd: include name of the unit when generating nix store path
Diffstat (limited to 'nixos')
-rw-r--r--nixos/modules/system/boot/systemd.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/nixos/modules/system/boot/systemd.nix b/nixos/modules/system/boot/systemd.nix
index d0fe69c15dd5..2a7985ded663 100644
--- a/nixos/modules/system/boot/systemd.nix
+++ b/nixos/modules/system/boot/systemd.nix
@@ -12,13 +12,13 @@ let
makeUnit = name: unit:
if unit.enable then
- pkgs.runCommand "unit" { preferLocalBuild = true; inherit (unit) text; }
+ pkgs.runCommand "unit-${name}" { preferLocalBuild = true; inherit (unit) text; }
''
mkdir -p $out
echo -n "$text" > $out/${shellEscape name}
''
else
- pkgs.runCommand "unit" { preferLocalBuild = true; }
+ pkgs.runCommand "unit-${name}-disabled" { preferLocalBuild = true; }
''
mkdir -p $out
ln -s /dev/null $out/${shellEscape name}