How to deploy a Java EE application in the Amazon cloud?
Asked Answered
K

3

22

Here's the thing: I need to take a certain Java EE web app and deploy it to Amazon EC2 (which I will need to setup first) starting next month (using the http://aws.amazon.com/free/faqs/ AWS Free Tier Usage - hope it supports Tomcat + MySQL/PostgreSQL).


The problem: I have never ever deployed a Java EE app (not even a normal one on a dedicated hosting) nor have I setup an Amazon EC2 enviorment.


Are there any, idiot proof preferably, tutorials/how-to's/whatever on doing it from the very beginning (signing up to Amazon) till the very end (when your app is all up and running)?

I did find some tutorials on how to setup an Amazon EC2 instance, how to normally deploy a Java EE app but what I'm looking for is a single tutorial putting it all together.

Kloster answered 28/10, 2010 at 11:36 Comment(0)
C
23

Start with an Ubuntu AMI. Then install tomcat. Now put the WAR file of your J2EE app where tomcat can see it. You can use the AWS console to start/stop your machines, configure firewall rules that allow you to access port 80, etc. There won't be a step by step guide telling you exactly what to do, welcome to being a programmer.

Configuration answered 28/10, 2010 at 16:36 Comment(1)
Thanks, hopefully there's always SO.Kloster
P
7

Once we have the instance (like Ubuntu) running http://youtu.be/hJRSti6DsJg then, installs Glassfish (Java EE server) and configure it to work with Java EE. It depends more of the instance itself (Ubuntu) than EC2 Amazon... here a nice video (how to install Glashfish in Ubuntu + Netbeans config) http://youtu.be/CKuoDm6bqRM

Note:

  • Keep in mind both videos are a little old (may some adjustments are necessary)
  • The videos are indirectly related. But my point is: there isn't much info about Amazon AWS and Java EE, but there are a lot info about Amazon AWS and Linux, and Linux and Java EE.

Update You can try Amazon Beanstalk (Deployment & Management) integrated with Netbeans (without Glashfish?) http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/GettingStarted.html

SSH to Elastic Beanstalk instance

http://aws.amazon.com/java/ (Amazon + Java)

enter image description here

Psychopathology answered 27/4, 2013 at 3:28 Comment(1)
Elastic Beanstalk is the way to go. Here's another SO thread with some info. #27903198Cocktail
G
2

Boxfuse now supports deploying Java EE applications using either Tomcat, TomEE Web Profile or TomEE Plus to AWS with a single command

boxfuse run mytomeeapp-1.0.war -env=prod

This will create an image, provision all necessary AWS infrastructure (AMIs, security groups, auto-scaling groups, launch configurations, ELBs, Elastic IPs, ...) and launch the instances. It supports blue/green zero downtime updates with Elastic IPs and ELBs.

You can find a tutorial here: https://boxfuse.com/blog/javaee-aws

Disclaimer: I am the founder and CEO of Boxfuse

Grindlay answered 29/9, 2015 at 7:54 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.