From fbcbb37dbbe34d20e6ee7f844307e80c0032f3f0 Mon Sep 17 00:00:00 2001 From: Lukas Kral Date: Mon, 13 Jun 2022 14:56:55 +0200 Subject: [PATCH] fix azure building pipeline Signed-off-by: Lukas Kral --- .azure/build-pipeline.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.azure/build-pipeline.yaml b/.azure/build-pipeline.yaml index e242374..e8cb348 100644 --- a/.azure/build-pipeline.yaml +++ b/.azure/build-pipeline.yaml @@ -54,6 +54,8 @@ jobs: env: DOCKER_REGISTRY: "quay.io" DOCKER_ORG: "strimzi-test-clients" + ${{ if startsWith(variables['build.sourceBranch'], 'refs/tags/') }}: + DOCKER_TAG: ${{ replace(variables['build.SourceBranch'], 'refs/tags/', '') }} ARCHITECTURES: 'amd64 s390x ppc64le arm64' - script: | docker login -u $DOCKER_USER -p $DOCKER_PASS $DOCKER_REGISTRY @@ -64,8 +66,10 @@ jobs: DOCKER_ORG: "strimzi-test-clients" DOCKER_USER: $(QUAY_USER) DOCKER_PASS: $(QUAY_PASS) + ${{ if startsWith(variables['build.sourceBranch'], 'refs/tags/') }}: + DOCKER_TAG: ${{ replace(variables['build.SourceBranch'], 'refs/tags/', '') }} ARCHITECTURES: 'amd64 s390x ppc64le arm64' - condition: and(succeeded(), eq(variables['build.sourceBranch'], 'refs/heads/main')) + condition: and(succeeded(), or(eq(variables['build.sourceBranch'], 'refs/heads/main'), startsWith(variables['build.sourceBranch'], 'refs/tags/'))) - task: PublishTestResults@2 inputs: testResultsFormat: JUnit