Copy docker image between repositories

前端 未结 2 741
萌比男神i
萌比男神i 2021-02-12 21:47

I have 2 private docker repositories. Is any way how can I copy one image from one repository to the second one?

相关标签:
2条回答
  • 2021-02-12 22:05

    You can pull the image, tag it and push it to the new registry.

    Example:

    docker pull old-registry/app
    docker tag old-registry/app new-registry/app
    docker push new-registry/app
    
    0 讨论(0)
  • 2021-02-12 22:12

    Can be done with https://github.com/containers/skopeo

    Example for the README:

    skopeo copy docker://quay.io/buildah/stable docker://registry.internal.company.com/buildah
    

    The advantage is that Skopeo does not require Docker on the machine it runs on.

    0 讨论(0)
提交回复
热议问题