Deploy a core style application (Plain old main) and a web application (light container) in the simplest way.
- Do not require any dependency on target env exept Java.
- When possible build a Plain old Main application and deploy using a Jar with all dependencies.
- When a container is require:
- prefer lightweight technology (servlet, ...), avoid dependency of a J2EE application server.
- use Jetty Runner, easier than embedded style, and no lock in.
- Deliver only one file (easier for production team).
- Deployement should be reproducible.
- Target environment should be easely reproducable and testable.
mvn package
cd distrib
vagrant up
That's all! Both applications should be deployed on the VM.
You should have a "Hello World" when connecting to http://localhost:8080/ .
Core and webapp application are dummy maven archetype applications.
Distrib module will:
- use appassembler-maven-plugin to build two deamon applications (using Java Service Wrapper).
- on the fly download of Jetty Runner, used to run the webapp application.
- build a tar.gz with full application installation (use maven-assembly-plugin).
- use Vagrant to build easely target VM.
- see Vagrantfile for reproducible VM setup.
- see bootstrap.sh for dependencies installation on VM (java).
- see install.sh for a custom reproducable installation of applications.
- Use Puppet (or Chef) for a better depedency management.
- Package script and distibution together (debian package, rpm, ...).
- To build a Jar with all depedencies use either: