rclone: check existence of file rather than using cat (#7799)

It's not really clear why this was done in the first place, and
furthermore it means that the secrets have been getting printed to
stdout and appear on the system journal as a result.
This commit is contained in:
Kylie McClain
2025-09-10 07:27:41 -04:00
committed by GitHub
parent a60021a8c9
commit 3c97248d6f

View File

@@ -252,7 +252,7 @@ in
injectSecret =
remote:
lib.mapAttrsToList (secret: secretFile: ''
if ! cat "${secretFile}"; then
if [[ ! -r "${secretFile}" ]]; then
echo "Secret \"${secretFile}\" not found"
cleanup
fi