From 6d6c0a4610b8a58f2cb2469c085cab099eb9c8ff Mon Sep 17 00:00:00 2001 From: Wayne Dovey Date: Wed, 6 Aug 2025 08:35:13 +1000 Subject: [PATCH] CI/CD Fix Module 3 Mark the repo directory as safe --- helm/cicd/templates/task-update-manifest.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/helm/cicd/templates/task-update-manifest.yaml b/helm/cicd/templates/task-update-manifest.yaml index 793241b..a521bc6 100644 --- a/helm/cicd/templates/task-update-manifest.yaml +++ b/helm/cicd/templates/task-update-manifest.yaml @@ -41,6 +41,9 @@ spec: git config --global user.email "$(params.git_user_email)" git config --global user.name "$(params.git_user_name)" + # Mark the repo directory as safe + git config --global --add safe.directory "$(workspaces.source.path)/$(params.git-root-directory)" + # Checkout target branch to avoid the detached HEAD state git checkout $(params.target-branch)