From 8b20e9e944a95b83875f5db42885cc8af6f83323 Mon Sep 17 00:00:00 2001 From: Devin Buhl Date: Wed, 17 Jan 2024 20:45:36 -0500 Subject: [PATCH] fix: encrypt sops files that are not already encrypted in sops task Signed-off-by: Devin Buhl --- .taskfiles/Sops/Taskfile.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.taskfiles/Sops/Taskfile.yaml b/.taskfiles/Sops/Taskfile.yaml index ba5ae71c..c9291299 100644 --- a/.taskfiles/Sops/Taskfile.yaml +++ b/.taskfiles/Sops/Taskfile.yaml @@ -14,7 +14,7 @@ tasks: - test -f "{{.SOPS_AGE_FILE}}" encrypt: - desc: Encrypt all Kubernetes SOPS secrets + desc: Encrypt all Kubernetes SOPS secrets that are not already encrypted cmds: - for: { var: file } task: .encrypt-file @@ -22,7 +22,7 @@ tasks: file: "{{.ITEM}}" vars: file: - sh: find {{.KUBERNETES_DIR}} -type f -name "*.sops.*" + sh: find "{{.KUBERNETES_DIR}}" -type f -name "*.sops.*" -exec grep -L "ENC\[AES256_GCM" {} \; .encrypt-file: internal: true