Elastic Beanstalk

0

Hello, I have uploaded java application on Elastic Beanstalk, i have given the port 5000 and enabled Database as well, and its showing status healthy. But when i copy paste the URL to browse the application it is giving error 502 bad Gateway nginix . Can somebody suggest what am i missing here? if i run sample application it is running fine but if i upload any application it does not work. Can somebody please share any running java source code, so that i can check, may be i am uploading wrong application.

Thank you!!

Monica
已提問 3 個月前檢視次數 154 次
2 個答案
0

Hello.

Can I connect to EC2 and check Nginx error logs?
I think that logs are probably output that can be used for troubleshooting.

/var/log/nginx/error.log

Also, check whether the listening port in the Nginx configuration file is correct.
https://shreyakupadhyay.medium.com/deployment-next-react-js-and-spring-boot-on-aws-ec2-with-nginx-d39bd57ca9

profile picture
專家
已回答 3 個月前
0

I do have a similar issue with a nestjs app (nodejs setup) deployed on beanstalk. When i did the sample application from AWS it worked but when i deployed a local laptop working nestjs app it gives me 502 bad Gateway nginix. I have no errors on the instance setup ( shows green health) in beanstalk and have the port setup accordingly in the config file with process.env.PORT ... any ideas where to look for any further troubleshooting ? TIA

sudhir
已回答 3 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南