AWS Java Web Project
Welcome to your new AWS Java Web Project! This project template gives you basic a starting point for creating a web application on AWS.
Contents of this Project
This page is rendered from WebContent/index.html - a simple static HTML page. Any static content in the WebContent folder will be accessible from the equivalent path in your web application (for example, https://your-app-93s2kypa5y.elasticbeanstalk.com/index.html).
Any JSP files in the WebContent folder will be processed dynamically to generate HTML pages. For example, the index.jsp file renders a simple page that displays a list of any Amazon S3 Buckets, Amazon DynamoDB Tables, and Amazon EC2 Instances currently associated with your AWS account.
Deploying this Project Locally
If you have a local installation of Apache Tomcat, you can deploy this project to it for local testing using the standard Eclipse Web Tools Platform integration with Tomcat.
- Right/control click on this project in the Project Explorer
- Choose Run As, then Run on Server
- Select the option to manually define a new server
- Expand the Apache folder, then select an appropriate version of Tomcat
- Point Eclipse at your local Tomcat installation and click Finish
This page will open up, now served by your local Tomcat installation.
Deploying the Project to AWS Elastic Beanstalk
AWS Elastic Beanstalk is the quickest and easiest way to deploy an AWS Java Web Project to the cloud. To deploy this project to AWS Elastic Beanstalk:
- Right/control click on this project in the Project Explorer
- Choose run As, then Run on Server
- Select the option to manually define a new server
- Expand the Amazon Web Services folder, then select an appropriate version of Tomcat
- Select the AWS region where your application will be hosted
- Provide a name for your application and environment and click Finish
Your project will be uploaded to AWS Elastic Beanstalk, which will provision infrastructure to host your application and deploy your code to it. When it's finished, you will again see this page open up, now hosted in the cloud!
For more information about working with AWS Elastic Beanstalk, refer to the AWS Elastic Beanstalk Developer Guide.