mirror of
https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/snowflake.git
synced 2025-10-13 20:11:19 -04:00
Add Container Image Mirroring from Tor Gitlab to Docker Hub
This commit is contained in:
parent
f940d7d6ef
commit
d069a0a1b9
1 changed files with 21 additions and 0 deletions
|
@ -370,3 +370,24 @@ clean-image-tags:
|
||||||
when: always
|
when: always
|
||||||
- if: $CI_COMMIT_TAG
|
- if: $CI_COMMIT_TAG
|
||||||
when: always
|
when: always
|
||||||
|
|
||||||
|
mirror-image-to-dockerhub:
|
||||||
|
stage: container-build
|
||||||
|
needs:
|
||||||
|
- job: clean-image-tags
|
||||||
|
artifacts: false
|
||||||
|
variables:
|
||||||
|
DOCKERHUB_MIRROR_REPOURL: $DOCKERHUB_MIRROR_REPOURL
|
||||||
|
DOCKERHUB_USERNAME: $DOCKERHUB_MIRROR_USERNAME
|
||||||
|
DOCKERHUB_PASSWORD: $DOCKERHUB_MIRROR_PASSWORD
|
||||||
|
image:
|
||||||
|
name: gcr.io/go-containerregistry/crane:debug
|
||||||
|
entrypoint: [""]
|
||||||
|
rules:
|
||||||
|
- if: $CI_COMMIT_REF_NAME == "main"
|
||||||
|
when: always
|
||||||
|
- if: $CI_COMMIT_TAG
|
||||||
|
when: always
|
||||||
|
script:
|
||||||
|
- echo "$DOCKERHUB_PASSWORD" | crane auth login docker.io -u $DOCKERHUB_MIRROR_USERNAME --password-stdin
|
||||||
|
- crane cp -a containers.torproject.org/tpo/anti-censorship/pluggable-transports/snowflake $DOCKERHUB_MIRROR_REPOURL
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue