ci(gitlab-ci): move buildah yum install inside script

This commit is contained in:
Sarah Vaupel 2024-09-12 01:05:40 +02:00
parent e9cbb0771d
commit f8886e02a7

View File

@ -82,11 +82,11 @@ setup:containers:frontend: &setup-container
variables:
IMAGE_TYPE: frontend
before_script: &container-before
- yum install wget -y
- IMAGE_VERSION=`cat ${IMAGE_TYPE}-image-version`
- IMAGE_TAG=${IMAGE_TYPE}/${CI_COMMIT_REF_SLUG}:${IMAGE_VERSION}
- REGISTRY_DESTINATION=${CI_REGISTRY_IMAGE}/${IMAGE_TYPE}/${CI_COMMIT_REF_SLUG}:${IMAGE_VERSION}
script:
- yum install wget -y
- wget --header "PRIVATE-TOKEN:${REGISTRY_AUTH_TOKEN}" "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/registry/repositories?tags=true" -o wget.log -O .gitlab-ci/.container-registry-contents.json
- IMAGE_EXISTS=`grep \""${REGISTRY_DESTINATION}"\" .gitlab-ci/.container-registry-contents.json || :`
- test "${CI_JOB_MANUAL}" = true && echo "Force rebuilding container."