Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Deploying WAR on Amazons Elastic Beanstalk

I have created a simple "HelloWorld" servlet in an Eclipse project. I built it into a WAR, deployed it in my Tomcat 7.0 local server and a simple request localhost/HelloWorld/sayhello prints "HELLO" No rocket science there. So following AWS documentation on how to deploy a WAR I go to Beanstalk management console and see the message "You do not have any AWS Elastic Beanstalk applications launched" so I click on Tomcat 7 -> start, and upload my WAR. After the upload completes and AWS tells me it is now running I click on "view running version" and it opens the link default-environment-zhqv8mwsqw.elasticbeanstalk.com I then tried default-environment-zhqv8mwsqw.elasticbeanstalk.com/HelloWorld/sayhello but I get a 404. Have I missed something or is there anything I can check? How do I explicitly tell AWS to use a 32 Bit JVM?

like image 938
MayoMan Avatar asked Oct 04 '22 19:10

MayoMan


1 Answers

It should be default-environment-zhqv8mwsqw.elasticbeanstalk.com I then tried default-environment-zhqv8mwsqw.elasticbeanstalk.com/sayhello

On your local you use context path in url but in EBS it deployed at root. so need to put context.

like image 158
Mahendra Avatar answered Oct 07 '22 18:10

Mahendra