Skip to content

Instantly share code, notes, and snippets.

@Th0masStorm
Last active June 7, 2019 07:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Th0masStorm/b7c24d5cfa3d1e554aab6a8b6440a1ec to your computer and use it in GitHub Desktop.
Save Th0masStorm/b7c24d5cfa3d1e554aab6a8b6440a1ec to your computer and use it in GitHub Desktop.
Building image, pushing to ECR and deploying as Fargate service
cd FlaskApp
# That's some hell of bash pipelining, but I'm too lazy to copy/paste ECR uri.
REPO=$(aws ecr describe-repositories --profile YOUR_PROFILE \
--region YOUR_REGION \
--repository-names YOUR_REPO_NAME | \
jq .repositories[].repositoryUri | \
sed -e 's/^"//' -e 's/"$//')
docker build -t ${REPO}:v1 .
$(aws ecr get-login --no-include-email --region YOUR_REGION --profile YOUR_PROFILE)
docker push ${REPO}:v1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment