From 94fa54632d460d7ac68c635260cbd79c8ed082f1 Mon Sep 17 00:00:00 2001 From: Zhaofeng Li Date: Mon, 14 Oct 2024 10:23:29 -0600 Subject: [PATCH] nixos: Use lib.getExe Co-authored-by: Adam Stephens --- nixos/atticd.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nixos/atticd.nix b/nixos/atticd.nix index 2ca17bf..9059bfc 100644 --- a/nixos/atticd.nix +++ b/nixos/atticd.nix @@ -26,7 +26,7 @@ let export ATTIC_SERVER_TOKEN_HS256_SECRET_BASE64="dGVzdCBzZWNyZXQ=" export ATTIC_SERVER_DATABASE_URL="sqlite://:memory:" - ${cfg.package}/bin/atticd --mode check-config -f $configFile + ${lib.getExe cfg.package} --mode check-config -f $configFile cat <$configFile >$out ''; @@ -204,7 +204,7 @@ in requires = lib.optionals hasLocalPostgresDB [ "postgresql.service" ]; serviceConfig = { - ExecStart = "${cfg.package}/bin/atticd -f ${checkedConfigFile} --mode ${cfg.mode}"; + ExecStart = "${lib.getExe cfg.package} -f ${checkedConfigFile} --mode ${cfg.mode}"; EnvironmentFile = cfg.environmentFile; StateDirectory = "atticd"; # for usage with local storage and sqlite DynamicUser = true;