From 53cf10d42aa268650b0b61705f8b241eb3e7d2b4 Mon Sep 17 00:00:00 2001 From: Bertrand Goareguer <bertrand.goareguer@gmail.com> Date: Mon, 20 Jun 2022 21:35:57 +0000 Subject: [PATCH] fix(skopeo): authenticate with skopeo inspect --- templates/gitlab-ci-docker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/gitlab-ci-docker.yml b/templates/gitlab-ci-docker.yml index 080a7b2..3a31457 100644 --- a/templates/gitlab-ci-docker.yml +++ b/templates/gitlab-ci-docker.yml @@ -670,7 +670,7 @@ docker-publish: fi skopeo copy --src-authfile /skopeo/.docker/src-config.json --dest-authfile /skopeo/.docker/dest-config.json ${DOCKER_PUBLISH_ARGS} docker://$DOCKER_SNAPSHOT_IMAGE docker://$DOCKER_RELEASE_IMAGE log_info "Well done your image is published and can be downloaded by doing: docker pull $DOCKER_RELEASE_IMAGE" - - docker_digest=$(skopeo inspect --format='{{ .Digest }}' "docker://$DOCKER_RELEASE_IMAGE") + - docker_digest=$(skopeo inspect --authfile /skopeo/.docker/dest-config.json --format='{{ .Digest }}' "docker://$DOCKER_RELEASE_IMAGE") - docker_repository=${DOCKER_RELEASE_IMAGE%%:*} - docker_tag=${DOCKER_RELEASE_IMAGE#*:} - echo "docker_image=$DOCKER_RELEASE_IMAGE" > docker.env -- GitLab