Skip to content

Commit

Permalink
deployment keys: disable service if no key destinations are in /run/
Browse files Browse the repository at this point in the history
  • Loading branch information
jslight90 committed Nov 27, 2018
1 parent 204cafd commit a0b95d5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion nix/keys.nix
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,9 @@ in

systemd.services = (
{ nixops-keys =
{ enable = config.deployment.keys != {};
{ enable = lib.any (key: lib.hasPrefix "/run/" key.destDir) (
lib.attrValues config.deployment.keys
);
description = "Waiting for NixOps Keys";
wantedBy = [ "keys.target" ];
before = [ "keys.target" ];
Expand Down

0 comments on commit a0b95d5

Please sign in to comment.