From 3c97248d6f896232355735e34bb518ae9f130c5d Mon Sep 17 00:00:00 2001 From: Kylie McClain Date: Wed, 10 Sep 2025 07:27:41 -0400 Subject: [PATCH] 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. --- modules/programs/rclone.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/programs/rclone.nix b/modules/programs/rclone.nix index 1e71e73de..9e92609bb 100644 --- a/modules/programs/rclone.nix +++ b/modules/programs/rclone.nix @@ -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