Skip to content

Michle99/amazon-ecs-nodejs-microservices

Repository files navigation

Node.js Microservices Deployed on EC2 Container Service

This is a reference architecture that shows the evolution of a Node.js application from a monolithic application that is deployed directly onto instances with no containerization or orchestration, to a containerized microservices architecture orchestrated using Amazon EC2 Container Service.

Common Errors

Encountered the below errors when building the Node.js microservices.

common session error

Solution to error:

aws configure set aws_session_token "<<your session token>>"

Verify Deployment Results

  1. Get Post by userId
[{"thread":1,"text":"Has anyone checked on the lich recently?","user":4}]
  1. Get User by UserId
{"id":2,"username":"finn","name":"Finn 'the Human' Mertens","bio":"Adventurer and hero, last human, defender of good"}

  1. Get threads by threadId
{"id":2,"title":"Party at the candy kingdom tomorrow","createdBy":3}
  1. Get posts by threadId
[{"thread":2,"text":"Come party with the candy people tomorrow!","user":3},{"thread":2,"text":"Mathematical!","user":2},{"thread":2,"text":"I'll bring my guitar","user":1}]

Clean Up Resources

copilot app delete --name api .

Resources

Break a Monolithic Application into Microservices with AWS Copilot, Amazon ECS, Docker, and AWS Fargate TUTORIAL

Releases

No releases published

Packages

No packages published