From 803ebd310f8cb8afa4323fc29cbce3592d7255ff Mon Sep 17 00:00:00 2001 From: Francois Ferrand Date: Wed, 23 Oct 2024 11:46:48 +0200 Subject: [PATCH] Fix zkop install to support sha1 When an SHA1 is used which is not the tip of the branch, it is not available after a `git clone` (which fetches only commits reachable from current branches). This causes issues if a build is started while the component branch with the commit has been rewritten (rebase...) To overcome this, the safe way is to explicitely fetch the commit: which works for any commit (branch, tag, sha1). Issue: ZENKO-4876 --- .github/actions/deploy/action.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/actions/deploy/action.yaml b/.github/actions/deploy/action.yaml index 1fc7708f0c..8710005de1 100644 --- a/.github/actions/deploy/action.yaml +++ b/.github/actions/deploy/action.yaml @@ -64,8 +64,9 @@ runs: docker pull ${OPERATOR_IMAGE_NAME}:${OPERATOR_IMAGE_TAG} kind load docker-image ${OPERATOR_IMAGE_NAME}:${OPERATOR_IMAGE_TAG} cd ./.github/scripts/end2end - git clone https://${GIT_ACCESS_TOKEN}@github.com/scality/zenko-operator.git operator + git init operator cd operator + git fetch --depth 1 --no-tags https://${GIT_ACCESS_TOKEN}@github.com/scality/zenko-operator.git ${OPERATOR_IMAGE_TAG} git checkout ${OPERATOR_IMAGE_TAG} tilt ci env: