From 3aae87a9213691b2d34cc1d5077830ad7c134e98 Mon Sep 17 00:00:00 2001 From: Mark Hansen Date: Sat, 20 Feb 2021 17:05:37 +1100 Subject: [PATCH] Allow testing docker_push step in my own repo With my own container registry Before, I mistakenly thought that merge requests ran with the credentials of graphviz/graphviz, now I see they only run with the credentials of the source repo (markhnsn/graphviz). So it's safe to run this on any master branch, even forks. --- .gitlab-ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9c5dc8509..0736208ec 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -629,7 +629,9 @@ deployment: only: refs: # Only master should be pushed to :latest, not unmerged merge-requests. - - master@graphviz/graphviz + # It's ok for this to run on other repos (not just graphviz/graphviz) as + # they have their own container registries. + - master script: - docker pull $CI_REGISTRY_IMAGE/$IMAGE:$CI_COMMIT_SHA # Re-tag, push to :latest tag -- 2.40.0