DEV Community

Cover image for Pushing a docker container to Amazon Elastic Container Registry
Luiz Calaça
Luiz Calaça

Posted on

Pushing a docker container to Amazon Elastic Container Registry

Hi, Devs!

First of all, go to AWS Console and access on search field: Amazon ECR. Access the option view push commands.

AWS ECR

Execute the login command in your local console in your machine:

aws ecr get-login-password --region us-east-1 | docker login --username AWS --password-stdin<idaws>.dkr.ecr.us-east-1.amazonaws.com
Enter fullscreen mode Exit fullscreen mode

After build your docker image before tag it:

docker build -t <namebuild> .
Enter fullscreen mode Exit fullscreen mode
docker tag <namebuild> <idaws>.dkr.ecr.us-east-1.amazonaws.com/<namebuild>
Enter fullscreen mode Exit fullscreen mode

Now you could push it:

docker push <idaws>.dkr.ecr.us-east-1.amazonaws.com/<namebuild>
Enter fullscreen mode Exit fullscreen mode

You'll see in the list your image, now you could just refers the image name to others AWS services like Kubernetes.

AWS

That'all!

Contacts
Email: luizcalaca@gmail.com
Instagram: https://www.instagram.com/luizcalaca
Linkedin: https://www.linkedin.com/in/luizcalaca/
Twitter: https://twitter.com/luizcalaca

Heroku

Simplify your DevOps and maximize your time.

Since 2007, Heroku has been the go-to platform for developers as it monitors uptime, performance, and infrastructure concerns, allowing you to focus on writing code.

Learn More

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay