Properly tag images when building them

This commit is contained in:
Lukas Eipert 2021-12-08 12:44:00 +01:00
parent db5a4f37ea
commit 94ebd90c7f
2 changed files with 2 additions and 2 deletions

View file

@ -21,5 +21,5 @@
.build_and_deploy_custom:
extends: .deploy
script:
- ./scripts/custom-docker-build --label "ci_pipeline_url=$CI_PIPELINE_URL" --label "ci_job_url=$CI_JOB_URL" -t "$CI_REGISTRY_IMAGE:$1"
- ./scripts/custom-docker-build --label "ci_pipeline_url=$CI_PIPELINE_URL" --label "ci_job_url=$CI_JOB_URL"
- ./scripts/custom-docker-push

View file

@ -288,7 +288,7 @@ function build_custom_if_needed() {
# This re-uses and builds an existing image if needed
docker pull --quiet "$full_image" || true
docker_command=$(generate_command $@ --cache-from="$full_image_name" )
docker_command=$(generate_command $@ --cache-from="$full_image_name" -t "$full_image_name")
echo "Docker command:"
printf "\t%s" "$docker_command"
eval $docker_command