diff --git a/tasks/git-clone-checkout/task.yaml b/tasks/git-clone-checkout/task.yaml index 05b7f83..77dd1c1 100644 --- a/tasks/git-clone-checkout/task.yaml +++ b/tasks/git-clone-checkout/task.yaml @@ -115,10 +115,6 @@ spec: #!/bin/sh set -eu - ls -al $HOME - cat $HOME/.gitconfig - cat $HOME/.git-credentials - if [ "$(params.sslVerify)" = "false" ]; then echo "[INFO] Disabling SSL verification" git config --global http.sslVerify false @@ -134,6 +130,8 @@ spec: if [ "$(params.deleteExisting)" = "true" ] && [ -d "$CLONE_DIR" ]; then echo "[INFO] Deleting existing directory $CLONE_DIR" rm -rf "$CLONE_DIR" + mkdir -p "$CLONE_DIR" + chown -R $(id -u):$(id -g) "$CLONE_DIR" fi echo "[INFO] Cloning repository..."