- Configure your AWS Credentials:
aws configure
- Login to the ECR:
aws ecr get-login-password --region us-east-1 | docker login --username AWS --password-stdin 657608969216.dkr.ecr.us-east-1.amazonaws.com/invest-pro-api
- Build and Push the Docker Image:
export VERSION="0.0.2"
export REPOSITORY="657608969216.dkr.ecr.us-east-1.amazonaws.com/invest-pro-api"
docker build -t invest-pro-api:$VERSION .
docker tag invest-pro-api:$VERSION $REPOSITORY:$VERSION
docker tag invest-pro-api:$VERSION $REPOSITORY:latest
docker push "$REPOSITORY":"$VERSION"
docker push "$REPOSITORY":latest
cd Projects
ssh -i "gbrotas-keypair.pem" [email protected]
sudo yum install -y nginx certbot python-certbot-nginx
sudo certbot certonly --nginx -d myportfolio-api.brottas.com