-
Notifications
You must be signed in to change notification settings - Fork 54
Building from source
Clone the Git repo from GitHub:
git clone https://github.com/ManyDesigns/Portofino.git portofino
Build it:
cd portofino
mvn install
The result of the build is:
- All Portofino modules in their own directories
- The Maven archetypes to create new projects
- The demo-tt war
If you want to recreate the one-click package (Tomcat + empty Portofino webapp) - the one you can download from SourceForge - there is a Python script (Unix only) to do so in the "oneclick" directory.
Prerequisite: create a local.py file in this format:
#! /usr/bin/env python
portofino_version = "5.0.0"
tomcat_dir = "apache-tomcat-9.x.y"
portofino_path = "~/projects/portofino"
tomcat_url = "http://apache.fastbull.org/tomcat/tomcat-9/v9.x.y/bin/apache-tomcat-9.x.y.zip"
drivers = [["org/postgresql/postgresql/9.2-1003-jdbc4/", "postgresql-9.2-1003-jdbc4.jar"],
["mysql/mysql-connector-java/5.1.25/", "mysql-connector-java-5.1.25.jar"],
["net/sourceforge/jtds/jtds/1.2.8/", "jtds-1.2.8.jar"]]
It should be self-explanatory. Portofino is built in portofino_path, a new project is created from the archetype, Tomcat is downloaded from tomcat_url and expanded in tomcat_dir, and the specified JDBC drivers are downloaded from Maven Central and bundled in Tomcat's libs.
oneclick.py contains a commented out example for the above local.py where you can copy versions and URLs from (Tomcat URLs tend to become invalid when newer versions are released, so we cannot hardcode them).
When you have a properly configured local.py, you can just launch
./oneclick.py
If everything goes well, you'll find the result in build/portofino-$version.zip
.
Please note that the above process only works if you're rebuilding a released version of Portofino. Additional steps are required for snapshot builds.