From 033ac0b400533a505213fcf5dc54b8e2eb5d19ef Mon Sep 17 00:00:00 2001 From: bluepython508 <16466646+bluepython508@users.noreply.github.com> Date: Sat, 28 Sep 2024 11:14:52 +0100 Subject: [PATCH] Exit on failed get-authkey --- flake.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/flake.nix b/flake.nix index d8c2b5e..be2f012 100644 --- a/flake.nix +++ b/flake.nix @@ -87,6 +87,7 @@ DynamicUser = true; RuntimeDirectory = name; ExecStartPre = "!${pkgs.writeShellScript "get-authkey" '' + set -e TS_API_CLIENT_ID=${cfg.clientId} TS_API_CLIENT_SECRET=$(cat ${cfg.clientSecretFile}) ${get-authkey}/bin/get-authkey -ephemeral -tags ${lib.concatStringsSep "," cfg.tags} > $RUNTIME_DIRECTORY/authkey chown ${name}:${name} $RUNTIME_DIRECTORY/authkey ''}";