Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mdlavin/copy-docker-image
Copy a Docker image between registries without a full Docker installation
https://github.com/mdlavin/copy-docker-image
docker docker-image docker-registry
Last synced: about 1 month ago
JSON representation
Copy a Docker image between registries without a full Docker installation
- Host: GitHub
- URL: https://github.com/mdlavin/copy-docker-image
- Owner: mdlavin
- Created: 2017-04-11T19:38:25.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-08-29T08:27:20.000Z (over 6 years ago)
- Last Synced: 2024-07-31T21:56:39.785Z (5 months ago)
- Topics: docker, docker-image, docker-registry
- Language: Go
- Homepage:
- Size: 14.6 KB
- Stars: 36
- Watchers: 3
- Forks: 16
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-docker - copy-docker-image - Copy a Docker image between registries without a full Docker installation by [@mdlavin](https://github.com/mdlavin) (Docker Images / Builder)
- awesome-docker - copy-docker-image - Copy a Docker image between registries without a full Docker installation by [@mdlavin](https://github.com/mdlavin) (Docker Images / Builder)
README
# copy-docker-image - Copy docker images without a full docker installation
[![Build Status](https://travis-ci.org/mdlavin/copy-docker-image.svg?branch=master)](https://travis-ci.org/mdlavin/copy-docker-image)## Overview
When doing automated deployments, especially when using AWS ECR in multiple accounts, you might want to copy images from one registry to another without the need for a full docker installation. At LifeOmic we wanted to orchestrate the copying of images while executing inside a container without exposing a full Docker socket just for image manipulation.
To copy an image between two anonymous repositories, you can use a command line like:
```
$ copy-docker-image --src-repo http://registry1/ --dest-repo http://registry2 --repo project
```To specify an image tag, just add a --tag argument like:
```
$ copy-docker-image --src-repo http://registry1/ --dest-repo http://registry2 --repo project --tag v1
```## Integration with AWS ECR
Because copy to AWS ECR was common a special URL format was added to automatically look up the right HTTPS URL and authorization token. Assuming a AWS CLI profile has been created for your account you can use a command like:
```
$ copy-docker-image --src-repo http://registry1/ --dest-repo ecr: --repo project
```
## InstallationPre-built binaries for tagged releases are available on the [releases page](https://github.com/mdlavin/copy-docker-image/releases).