From 9159b3f7bd357f8069d833067787db9c3b3fd239 Mon Sep 17 00:00:00 2001 From: Jan Zickermann <jan.zickermann@dataport.de> Date: Tue, 10 Dec 2024 13:06:32 +0100 Subject: [PATCH] #2 OZG-7121 pipeline: Use references for helm --- .gitlab-ci.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f57a9bb..75486c2 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -41,9 +41,10 @@ test: test-helm: stage: test - extends: .helm - script: + before_script: + - !reference [ .helm, before_script ] - helm plugin install https://github.com/helm-unittest/helm-unittest.git + script: - helm template ./src/main/helm/ -f src/test/helm-linter-values.yaml - helm lint -f src/test/helm-linter-values.yaml ./src/main/helm/ - cd src/main/helm && helm unittest -f '../../test/helm/**/*test.yaml' . @@ -96,7 +97,9 @@ push-merge-request-helm-nexus: # Snapshot jobs push-snapshot-image-gitlab: stage: publish - extends: .get-version + before_script: + - !reference [.get-version, before_script] + - !reference [.helm, before_script] script: - export IMAGE_TAGS="${CI_REGISTRY_IMAGE}:${PROJECT_VERSION}-main+${CI_COMMIT_SHORT_SHA},${CI_REGISTRY_IMAGE}:snapshot-latest" - mvn deploy -Pgitlab-deploy $MAVEN_DEPLOY_CLI_OPTS $MAVEN_CLI_OPTS -- GitLab