1

I am trying to migrate from gitlab-ce to gitlab.com. This includes Docker registry as well. What I need to migrate Gitlab Docker Registry to hosted Docker registry (Nexus3). This might be manually done I imagine, but is there any more efficient way to do it?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
Badr
  • 694
  • 1
  • 7
  • 26

1 Answers1

1

Normally I used the following workflow for each tag:

docker pull SRC_REGISTRY_HOST/<REPOSITORY:TAG
docker tag SRC_REGISTRY_HOST/<REPOSITORY:TAG DEST_REGISTRY_HOST/<REPOSITORY:TAG
docker push DEST_REGISTRY_HOST/<REPOSITORY:TAG

But I couldn't find it clean so I wrote a small tool to automate all the steps and just use the following:

docker run --rm -it smqasims/imagesync --src SRC_REGISTRY_HOST/<REPOSITORY> --dest DEST_REGISTRY_HOST/<REPOSITORY

This will sync both the repositories and is faster/manageable compared to the other workflow.

Qasim Sarfraz
  • 5,822
  • 2
  • 20
  • 26