Useful commands to know when dealing with AWS infrastructure from the command line.

AWS and ECR

Log into ECR from the command line

Its really tempting to use a command like this:

AWS_PROFILE=sandbox aws ecr get-login-password --region <region>| \
    docker login --username AWS --password-stdin <account>.dkr.ecr.<region>.amazonaws.com

But you should see the following message :

WARNING! Your password will be stored unencrypted in ${HOME}/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store

Login Succeeded