aws-ecr-migration

Management project which migrates docker images to/from ECR repositories.


Keywords
AWS, SDK, ECR, Docker, Container, Backup, Restore, Migration, Infrastructure, Cloud, Lambda
License
GPL-3.0
Install
pip install aws-ecr-migration==1.2.1

Documentation

AWS ECR Migration

Short description

Project used to migrate docker images between cloud and a local machine.

Prerequisites

Local prerequisites

  • Docker installed.
  • This project installed with:
pip install aws-ecr-migration

or:

./install.sh

Cloud prerequisites

  • ECR repository created

Usage

Pulling from ECR repository

from aws_ecr_migration.manage import Manager
from aws_ecr_migration.aws_credentials import AwsCredentials

manager = Manager(
    credentials=AwsCredentials(), 
    remote_repository='remote/repository'
)

manager.pull()

Pushing an image to ECR repository

from aws_ecr_migration.manage import Manager
from aws_ecr_migration.aws_credentials import AwsCredentials

manager = Manager(
    credentials=AwsCredentials(), 
    remote_repository='remote/repository'
)

manager.push_image('myimage')

Pushing a running container to ECR repository

from aws_ecr_migration.manage import Manager
from aws_ecr_migration.aws_credentials import AwsCredentials

manager = Manager(
    credentials=AwsCredentials(), 
    remote_repository='remote/repository'
)

manager.push_container('mycontainer')