Hosting on AWS, React.js + Node.js app

0

I developed a web app, its frontend is made with react js and the backend is made with node js. Some data provided by clients are delivered to the backend and then they are processed and delivered again to an AWS Lambda function in order to start some additional executions. Locally everything works fine. My doubt is about the choice of the right way to host my web app: what are the instruments able to make my project hosted by aws? I read about amplify, lightsail, ec2 and so on... Can you give me some advice?

2개 답변
0
수락된 답변

You can use Lightsail Node.js blueprint to deploy your frontend/backend: https://lightsail.aws.amazon.com/ls/docs/en_us/articles/amazon-lightsail-quick-start-guide-nodejs

You can setup VPC peering to allow backend to communicate with Lambda function on your AWS account. Below page can help you with this. https://lightsail.aws.amazon.com/ls/docs/en_us/articles/lightsail-how-to-set-up-vpc-peering-with-aws-resources

In terms of whether you should choose Lightsail or EC2 for VPS hosting, it would depend on your full use-case/scale.

AWS
답변함 일 년 전
  • My backend communicate with SQS, and SQS is connected with Lambda. Can I use aws sdk as I do locally in my backend in order to send messages to SQS from my React + Node app deployed on lighsail?

0

My recommendation is use S3 + cloudfront for the frontend in react and API Gateway + Lambda for the backend. You can use amplify to simplify the deployment process and create a CI/CD pipeline, but not is mandatory. Don't use lightsail, and avoid EC2 unless some backend dependency force to use it instead of lambda.

답변함 일 년 전
  • Can you give me some more information about why do not use laighsail? Because it seems to me that is the right choice in order to have fixed deployment costs. And then I would like to preserve lamba concurrency to the clients requests processing. The backend in my app is only about some get and post requests and some message delivery to SQS in order to make lambdas execute. The ost of the work is made by lambda and sqs, backend is only about delivery to them.

  • Cloudfront + S3 + AWS Lambda is more cost effective than lightsail. Also if you are already using AWS Lambda in other parts of the application, use the same technology for the backend made more sense.

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠