Do not try to create /run/agenix in when installing secrets

That is a job for agenixMountSecrets, which should have already
created a symlink there so the directory creation attempt would
fail anyway.
This commit is contained in:
Jan Tojnar 2022-01-06 22:55:10 +01:00
parent 26edd03a5a
commit 35ecba5704

View file

@ -24,7 +24,7 @@ let
echo "decrypting '${secretType.file}' to '$_truePath'..."
TMP_FILE="$_truePath.tmp"
mkdir -p "$(dirname "$_truePath")"
mkdir -p "$(dirname "${secretType.path}")"
[ "${secretType.path}" != "/run/agenix/${secretType.name}" ] && mkdir -p "$(dirname "${secretType.path}")"
(
umask u=r,g=,o=
LANG=${config.i18n.defaultLocale} ${ageBin} --decrypt ${identities} -o "$TMP_FILE" "${secretType.file}"