A step-by-step guide to deploying a Docker image to Amazon ECR and running it on Amazon EC2.
Build an image from a base image pulled from Docker Hub, create a container on a specified port from that image and push the image to Amazon ECR repository.
In this tutorial, I will show how to push an image to AWS. All the steps shown below were performed on Ubuntu 18 with Docker version 19.03.6 and AWS CLI version 2 installed.