Creating pom to autobuild bundle. Refs #3280
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/distributions/smartgears-distribution-bundle@113551 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
ecff7c8050
commit
7c43292740
15
pom.xml
15
pom.xml
|
@ -16,6 +16,8 @@
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<distroDirectory>distro</distroDirectory>
|
<distroDirectory>distro</distroDirectory>
|
||||||
|
<tomcat.version>7.0.42</tomcat.version>
|
||||||
|
<smartgear.version>1.2.0-SNAPSHOT</smartgear.version>
|
||||||
<resourcesDirectory>src/resources</resourcesDirectory>
|
<resourcesDirectory>src/resources</resourcesDirectory>
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
</properties>
|
</properties>
|
||||||
|
@ -42,14 +44,14 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.distribution</groupId>
|
<groupId>org.gcube.distribution</groupId>
|
||||||
<artifactId>smartgears-distribution</artifactId>
|
<artifactId>smartgears-distribution</artifactId>
|
||||||
<version>LATEST</version>
|
<version>${smartgear.version}</version>
|
||||||
<type>tar.gz</type>
|
<type>tar.gz</type>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.apache.tomcat</groupId>
|
<groupId>org.apache.tomcat</groupId>
|
||||||
<artifactId>tomcat</artifactId>
|
<artifactId>tomcat</artifactId>
|
||||||
<version>7.0.42</version>
|
<version>${tomcat.version}</version>
|
||||||
<type>tar.gz</type>
|
<type>tar.gz</type>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
@ -72,8 +74,15 @@
|
||||||
<excludeTypes>war</excludeTypes>
|
<excludeTypes>war</excludeTypes>
|
||||||
</configuration>
|
</configuration>
|
||||||
</execution>
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-resources-plugin</artifactId>
|
||||||
|
<version>2.6</version>
|
||||||
|
<executions>
|
||||||
<execution>
|
<execution>
|
||||||
<id>copy-setup</id>
|
<id>copy-resources</id>
|
||||||
<goals>
|
<goals>
|
||||||
<goal>copy-resources</goal>
|
<goal>copy-resources</goal>
|
||||||
</goals>
|
</goals>
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
TOMCAT_DST_FOLDER="tomcat"
|
TOMCAT_DST_FOLDER="tomcat"
|
||||||
TOMCAT_VERSION="7.0.42"
|
TOMCAT_VERSION="${tomcat.version}"
|
||||||
TOMCAT_PID_FILENAME="pid.txt"
|
TOMCAT_PID_FILENAME="pid.txt"
|
||||||
SMARTGEAR_DISTRIBUTION_DIRECTORY="smartgears-distribution-1.2.0-SNAPSHOT"
|
SMARTGEAR_DISTRIBUTION_DIRECTORY="smartgears-distribution-${smartgear.version}"
|
||||||
SMARTGEAR_ROOT=${PWD}
|
SMARTGEAR_ROOT=${PWD}
|
||||||
|
|
||||||
GHN_HOME=${SMARTGEAR_ROOT}/${SMARTGEAR_DISTRIBUTION_DIRECTORY}
|
GHN_HOME=${SMARTGEAR_ROOT}/${SMARTGEAR_DISTRIBUTION_DIRECTORY}
|
||||||
|
@ -14,6 +14,33 @@ export GHN_HOME=${GHN_HOME}
|
||||||
export CATALINA_PID=${SMARTGEAR_ROOT}/${TOMCAT_PID_FILENAME}
|
export CATALINA_PID=${SMARTGEAR_ROOT}/${TOMCAT_PID_FILENAME}
|
||||||
export CATALINA_HOME=${SMARTGEAR_ROOT}/${TOMCAT_DST_FOLDER}"
|
export CATALINA_HOME=${SMARTGEAR_ROOT}/${TOMCAT_DST_FOLDER}"
|
||||||
|
|
||||||
|
|
||||||
|
function showhelp {
|
||||||
|
echo -e "\nUsage: setup.sh [-d <distro directory>] [-f |-h] \n"
|
||||||
|
echo " <distro directory> = the directory where installing SmartGear"
|
||||||
|
echo " By default, this is the directory of this script."
|
||||||
|
echo " f = Really run the setup. By default it will be a dry-run"
|
||||||
|
echo -e " h = shows this help.\n"
|
||||||
|
}
|
||||||
|
|
||||||
|
while getopts ":d:fh" opt; do
|
||||||
|
case $opt in
|
||||||
|
d) distro=$OPTARG;;
|
||||||
|
f) force="true";;
|
||||||
|
h) showhelp
|
||||||
|
exit 0 ;;
|
||||||
|
:) echo -e "\nERROR:option -$OPTARG requires an argument." >&2 ;
|
||||||
|
showhelp;
|
||||||
|
echo -e "\naborting.\n"
|
||||||
|
exit 1;;
|
||||||
|
\?) echo -e "\nERROR:invalid option: -$OPTARG";
|
||||||
|
showhelp;
|
||||||
|
echo -e "\naborting.\n"
|
||||||
|
exit 1 >&2 ;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
|
||||||
echo "Creating tomcat symlink..."
|
echo "Creating tomcat symlink..."
|
||||||
ln -s apache-tomcat-${TOMCAT_VERSION} ${TOMCAT_DST_FOLDER}
|
ln -s apache-tomcat-${TOMCAT_VERSION} ${TOMCAT_DST_FOLDER}
|
||||||
ls -l ${TOMCAT_DST_FOLDER}
|
ls -l ${TOMCAT_DST_FOLDER}
|
||||||
|
@ -43,6 +70,6 @@ echo "- Launch tomcat from ${SMATGEAR_ROOT} using the command ${CATALINA_STARTUP
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo "By default tomcat start on 8080 port.
|
echo "By default tomcat start on 8080 port.
|
||||||
If you want to change this port remeber to modify ${CONTAINER_XML} consistently"
|
If you want to change this port REMEMBER to modify ${CONTAINER_XML} consistently"
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue