diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9166b6a98d1047c5feae076c3b5a2fd7f7ce9ba6..32d9b88b845dda2a891427aa1606cc1fa563944d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -70,6 +70,11 @@ docker_store_images_changes: docker_build_image_devices: extends: .base_docker_images script: + - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh apsct-sim $tag + - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh apspu-sim $tag + - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh recv-sim $tag + - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh sdptr-sim $tag + - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh unb2-sim $tag - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh device-apsct $tag - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh device-apspu $tag - bash $CI_PROJECT_DIR/sbin/tag_and_push_docker_image.sh device-boot $tag diff --git a/sbin/tag_and_push_docker_image.sh b/sbin/tag_and_push_docker_image.sh index 805c34f057e7d7a4e4e958946ed2335490b89a10..42d9a9861fb8d874ecc21ae3937e2aaefbc8419a 100755 --- a/sbin/tag_and_push_docker_image.sh +++ b/sbin/tag_and_push_docker_image.sh @@ -112,8 +112,12 @@ if [ ! -z "${1+x}" ] && [ "${1}" == "pull" ]; then tag="${2}" for image in "${LOCAL_IMAGES[@]}"; do - local_url="${LOCAL_DOCKER_REGISTRY_HOST}/${LOCAL_DOCKER_REGISTRY_USER}/${image}" - # Pull images, at least one of the two immages must succeed + # Set, splits tuple into $1 and $2. this shadows previous variables + # shellcheck disable=SC2086 + set -- $image + local_url="${LOCAL_DOCKER_REGISTRY_HOST}/${LOCAL_DOCKER_REGISTRY_USER}/${1}" + # Pull images, at least one of the two images must succeed + echo "docker pull ${local_url}:${tag}" docker pull "${local_url}:${tag}" || docker pull "${local_url}:latest" || exit 1 done