converted to osgi based deployment. remove application server config that's no longer used.

This commit is contained in:
Heng Sin Low 2010-07-13 16:07:13 +08:00
parent 5b8efcd223
commit 7ddc6c4d1f
10 changed files with 161 additions and 1142 deletions

View File

@ -2,16 +2,6 @@
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/tools"/>
<classpathentry kind="src" path="/base"/>
<classpathentry kind="src" path="/client"/>
<classpathentry kind="src" path="/serverApps"/>
<classpathentry kind="src" path="/serverRoot"/>
<classpathentry kind="lib" path="/tools/lib/ant.jar"/>
<classpathentry kind="lib" path="/tools/lib/ant-commons-net.jar"/>
<classpathentry kind="lib" path="/tools/lib/ant-launcher.jar"/>
<classpathentry kind="lib" path="/tools/lib/commons-net-1.4.0.jar"/>
<classpathentry kind="lib" path="/tools/lib/ojdbc6.jar"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="output" path="build"/>
</classpath>

View File

@ -18,24 +18,11 @@ fi
echo ===================================
echo Setup Dialog
echo ===================================
CP=lib/CInstall.jar:lib/Adempiere.jar:lib/CCTools.jar:lib/oracle.jar:lib/jboss.jar:lib/postgresql.jar:
# Trace Level Parameter, e.g. ARGS=ALL
ARGS=CONFIG
# To test the OCI driver, add -DTestOCI=Y to the command - example:
# $JAVA -classpath $CP -DADEMPIERE_HOME=$ADEMPIERE_HOME -DTestOCI=Y org.compiere.install.Setup $ARGS
# $JAVA -classpath $CP -DADEMPIERE_HOME=$ADEMPIERE_HOME org.compiere.install.Setup $ARGS
# OSGi:
$JAVA -jar osgi/org.eclipse.osgi_3.5.0.v20090520.jar -clean -console -application org.adempiere.Install
$JAVA -jar osgi/org.eclipse.osgi_3.6.0.v20100517.jar -clean -console -install osgi -configuration osgi/client -application org.adempiere.Install
#echo ===================================
#echo Setup Adempiere Server Environment
#echo ===================================
#$JAVA -classpath $CP -DADEMPIERE_HOME=$ADEMPIERE_HOME -Dant.home="." org.apache.tools.ant.launch.Launcher setup
echo ===================================
echo Make .sh executable & set Env
echo ===================================
@ -43,15 +30,10 @@ chmod -R a+x *.sh
find . -name '*.sh' -exec chmod a+x '{}' \;
# Sign database build
cd utils
# cd utils
#. ./RUN_SignDatabaseBuild.sh
. ./RUN_UnixEnv.sh
#echo ================================
#echo Test local Connection
#echo ================================
#%JAVA% -classpath lib/Adempiere.jar:lib/AdempiereCLib.jar org.compiere.install.ConnectTest localhost
echo .
echo For problems, check log file in base directory

View File

@ -33,8 +33,6 @@
<!-- create the time stamp and environment -->
<tstamp />
<available file="${envFile}" property="envFileExists" />
<available file="lib/AdempiereOriginal.jar" type="file" property="adempiereOriginal.exists"/>
<available file="lib/webuiOriginal.war" type="file" property="webuiOriginal.exists"/>
<fail message="**** RUN_setup was not successful - please re-run ****" unless="envFileExists" />
<property file="${envFile}"/>
<filter filtersfile="${envFile}" />
@ -42,20 +40,12 @@
<echo message="Environment = ${envFile}" />
<echo message="Java VM = ${ADEMPIERE_JAVA_TYPE}" />
<echo message="Database = ${ADEMPIERE_DB_TYPE}" />
<echo message="Apps Server = ${ADEMPIERE_APPS_TYPE}" />
<echo message="AppsDeployment= ${ADEMPIERE_APPS_DEPLOY}" />
<!-- Environment variables -->
<condition property="isWindows">
<os family="windows" />
</condition>
<condition property="isAppsJBoss">
<equals arg1="jboss" arg2="${ADEMPIERE_APPS_TYPE}" />
</condition>
<condition property="isAppsGlassfish">
<equals arg1="glassfish" arg2="${ADEMPIERE_APPS_TYPE}" />
</condition>
<echo message="Windows=${isWindows} JBoss=${isAppsJBoss} Glassfish=${isAppsGlassfish}" />
</target>
@ -120,449 +110,13 @@
</target>
<target name="backupAdempiereOriginal" unless="adempiereOriginal.exists">
<copy file="lib/Adempiere.jar" tofile="lib/AdempiereOriginal.jar" overwrite="yes" />
</target>
<target name="backupWebuiOriginal" unless="webuiOriginal.exists">
<copy file="lib/webui.war" tofile="lib/webuiOriginal.war" overwrite="yes" />
</target>
<!-- rebuild Adempiere.jar and webui.war to include possible customization and patches -->
<target name="setupALib" depends="setupInit, backupAdempiereOriginal">
<delete file="lib/packages.jar" failonerror="false"/>
<jar jarfile="lib/packages.jar" duplicate="preserve">
<!-- 2pack packages -->
<zipgroupfileset dir="packages" includes="**/lib/*.jar" casesensitive="no">
<patternset refid="manifest.exclude"/>
</zipgroupfileset>
</jar>
<jar jarfile="lib/Adempiere1.jar" index="yes" duplicate="preserve">
<!-- pack patches.jar and customization.jar into Adempiere.jar -->
<zipfileset src="lib/customization.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<!-- 2pack packages -->
<zipfileset src="lib/packages.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/patches.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<!-- posterita packages -->
<zipfileset src="lib/posterita.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/AdempiereOriginal.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<indexjars>
<pathelement path="lib/AdempiereCLib.jar"/>
<pathelement path="lib/CompiereJasperReqs.jar"/>
</indexjars>
<manifest>
<attribute name="Specification-Title" value="Adempiere"/>
<attribute name="Specification-Version" value="${ADEMPIERE_VERSION}"/>
<attribute name="Specification-Vendor" value="ADempiere"/>
<attribute name="Implementation-Title" value="Adempiere ${ADEMPIERE_VERSION}"/>
<attribute name="Implementation-Version" value="${ADEMPIERE_VERSION} ${DSTAMP}-${TSTAMP}"/>
<attribute name="Implementation-Vendor" value="${ADEMPIERE_VENDOR}"/>
<attribute name="Implementation-URL" value="http://www.adempiere.com"/>
<attribute name="Main-Class" value="org.compiere.Adempiere"/>
<attribute name="Class-Path" value="AdempiereSLib.jar"/>
</manifest>
</jar>
<!-- Sign Adempiere Jar -->
<signjar jar="lib/Adempiere1.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
<copy file="lib/Adempiere1.jar" tofile="lib/Adempiere.jar" overwrite="yes" />
<!-- Sign patches Jar -->
<copy file="lib/patches.jar" tofile="lib/patches1.jar" overwrite="yes" />
<signjar jar="lib/patches1.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
<copy file="lib/patches1.jar" tofile="lib/patches.jar" overwrite="yes" />
<!-- Sign customization Jar -->
<copy file="lib/customization.jar" tofile="lib/customization1.jar" overwrite="yes" />
<signjar jar="lib/customization1.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
<copy file="lib/customization1.jar" tofile="lib/customization.jar" overwrite="yes" />
<!-- clean up -->
<delete file="lib/Adempiere1.jar"/>
<delete file="lib/patches1.jar"/>
<delete file="lib/customization1.jar"/>
</target>
<!-- rebuild Adempiere.jar and webui.war to include possible customization and patches -->
<target name="setupWLib" depends="setupInit, backupWebuiOriginal">
<delete file="lib/zkpackages.jar" failonerror="false"/>
<jar jarfile="lib/zkpackages.jar" duplicate="preserve">
<!-- 2pack zkpackages -->
<zipgroupfileset dir="zkpackages" includes="**/lib/*.jar" casesensitive="no">
<patternset refid="manifest.exclude"/>
</zipgroupfileset>
</jar>
<zip destfile="lib/webui1.war" duplicate="preserve">
<!-- pack zkpatches.jar and zkcustomization.jar into webui.war -->
<zipfileset src="lib/zkcustomization.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<!-- 2pack zkpackages -->
<zipfileset src="lib/zkpackages.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/zkpatches.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/webuiOriginal.war" >
<patternset refid="manifest.exclude"/>
</zipfileset>
</zip>
<copy file="lib/webui1.war" tofile="lib/webui.war" overwrite="yes" />
<!-- clean up -->
<delete file="lib/webui1.war"/>
</target>
<!-- ==================================================== -->
<!-- Adempiere Client Lib -->
<!-- ==================================================== -->
<target name="setupCLib" depends="setupInit"
description="Setup Adempiere Client Lib">
<!-- Delete Old -->
<delete file="lib/AdempiereCLib.jar" failonerror="no" />
<delete file="lib/CClient.jar" failonerror="no" />
<delete file="lib/CTools.jar" failonerror="no" />
<!-- Create AdempiereCLib.jar file -->
<jar jarfile="lib/AdempiereCLib.jar" index="yes" duplicate="preserve">
<zipfileset src="lib/${ADEMPIERE_APPS_TYPE}.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/CCTools.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/oracle.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/postgresql.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<manifest>
<attribute name="Specification-Title" value="Adempiere Client Library" />
<attribute name="Specification-Version" value="${ADEMPIERE_MAIN_VERSION}" />
<attribute name="Specification-Vendor" value="Adempiere" />
<attribute name="Implementation-Title" value="AdempiereCLib ${ADEMPIERE_MAIN_VERSION}" />
<attribute name="Implementation-Version" value="${ADEMPIERE_MAIN_VERSION} ${DSTAMP}-${TSTAMP}" />
<attribute name="Implementation-Vendor" value="Adempiere, Inc." />
<attribute name="Implementation-URL" value="http://www.adempiere.com" />
</manifest>
</jar>
<echo message="KeyStore=${ADEMPIERE_KEYSTORE} - Alias=${ADEMPIERE_KEYSTORECODEALIAS}" />
<!-- Sign AdempiereCLib Jar -->
<signjar jar="lib/AdempiereCLib.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
</target>
<!-- ==================================================== -->
<!-- Adempiere Server Lib -->
<!-- ==================================================== -->
<target name="setupSLib" depends="setupInit"
description="Setup Adempiere Server Lib">
<!-- Delete Old -->
<delete file="lib/AdempiereSLib.jar" failonerror="no" />
<delete file="lib/CServer.jar" failonerror="no" />
<!-- Create AdempiereSLib.jar file -->
<jar jarfile="lib/AdempiereSLib.jar" index="yes" duplicate="preserve">
<zipfileset src="lib/CSTools.jar">
<patternset refid="manifest.exclude"/>
<exclude name="**/*.bsh"/>
</zipfileset>
<zipfileset src="lib/oracle.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/postgresql.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="lib/CompiereJasperReqs.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<manifest>
<attribute name="Specification-Title" value="Adempiere Server Library" />
<attribute name="Specification-Version" value="${ADEMPIERE_MAIN_VERSION}" />
<attribute name="Specification-Vendor" value="Adempiere" />
<attribute name="Implementation-Title" value="AdempiereSLib ${ADEMPIERE_MAIN_VERSION}" />
<attribute name="Implementation-Version" value="${ADEMPIERE_MAIN_VERSION} ${DSTAMP}-${TSTAMP}" />
<attribute name="Implementation-Vendor" value="Adempiere, Inc." />
<attribute name="Implementation-URL" value="http://www.adempiere.com" />
</manifest>
</jar>
<!-- Sign AdempiereSLib Jar -->
<signjar jar="lib/AdempiereSLib.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
<delete dir="buildSLib" />
<!-- Sign CompiereJasperReqs.jar for Java Web Start -->
<signjar jar="lib/CompiereJasperReqs.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
</target>
<!-- Sign other application jars -->
<target name="signOtherJars" depends="setupInit" >
<!-- Sign AdempiereRoot Jar -->
<copy file="lib/adempiereRoot.jar" tofile="lib/adempiereRoot1.jar" overwrite="yes" />
<signjar jar="lib/adempiereRoot1.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
<copy file="lib/adempiereRoot1.jar" tofile="lib/adempiereRoot.jar" overwrite="yes" />
<delete file="lib/adempiereRoot1.jar"/>
<!-- Sign AdempiereApps Jar -->
<copy file="lib/adempiereApps.jar" tofile="lib/adempiereApps1.jar" overwrite="yes" />
<signjar jar="lib/adempiereApps1.jar" alias="${ADEMPIERE_KEYSTORECODEALIAS}"
storepass="${ADEMPIERE_KEYSTOREPASS}" keystore="${ADEMPIERE_KEYSTORE}" />
<copy file="lib/adempiereApps1.jar" tofile="lib/adempiereApps.jar" overwrite="yes" />
<delete file="lib/adempiereApps1.jar"/>
</target>
<!-- ==================================================== -->
<!-- Setup Lib -->
<!-- ==================================================== -->
<target name="setupLib" depends="setupInit, setupWin, setupNonWin"
description="Setup Adempiere Lib directory">
<!-- Filter files Overwrite -->
<copy file="${basedir}/utils/ftpPutExportTemplate.txt"
tofile="${basedir}/utils/ftpPutExport.txt" filtering="yes" overwrite="yes" />
<copy file="${basedir}/utils/ftpGetAdempiereTemplate.txt"
tofile="${basedir}/utils/ftpGetAdempiere.txt" filtering="yes" overwrite="yes" />
<copy file="${basedir}/utils/adempiereDirectTemplate.jnlp"
tofile="${basedir}/lib/adempiereDirect.jnlp" filtering="yes" overwrite="yes" />
<!-- Create Client Zip
<zip zipfile="${basedir}/lib/AdempiereClient.zip">
<zipfileset dir="." prefix="Adempiere"
includes="*.html" />
<zipfileset dir="." prefix="Adempiere"
includes="RUN_Adempiere.*" />
<zipfileset dir="utils" prefix="Adempiere"
includes="WinEnv.js" />
<zipfileset dir="lib" prefix="Adempiere/lib"
includes="Adempiere.exe,*.ico,customization.jar,patches.jar,CompiereJasperReqs.jar,Adempiere.jar,AdempiereCLib.jar,adempiereDirect.jnlp,index.html,*.0" />
</zip>
-->
<!-- Save properties -->
<copy file="AdempiereEnv.properties"
tofile="AdempiereEnv.properties.save" />
<copy file="Adempiere.properties"
tofile="Adempiere.properties.save" />
</target>
<!-- Update application library -->
<target name="updateLib" depends="setupInit, setupWin, setupNonWin, setupALib, setupWLib, signOtherJars">
<!-- Create Client Zip -->
<zip zipfile="${basedir}/lib/AdempiereClient.zip">
<zipfileset dir="." prefix="Adempiere"
includes="*.html" />
<zipfileset dir="." prefix="Adempiere"
includes="RUN_Adempiere.*" />
<zipfileset dir="utils" prefix="Adempiere"
includes="WinEnv.js" />
<zipfileset dir="lib" prefix="Adempiere/lib"
includes="Adempiere.exe,*.ico,customization.jar,patches.jar,CompiereJasperReqs.jar,Adempiere.jar,AdempiereCLib.jar,adempiereDirect.jnlp,index.html,*.0" />
</zip>
</target>
<target name="createEAR">
<!-- Create adempiereRoot war -->
<zip destfile="${basedir}/lib/adempiereRoot.war">
<!-- copy Base -->
<zipfileset src="${basedir}/lib/adempiereRootBase.war" />
<!-- copy to adempiereHome -->
<zipfileset dir="${basedir}/lib"
includes="AdempiereClient.zip,Adempiere.jar,AdempiereCLib.jar,*.jnlp,*.0,*.html,CompiereJasperReqs.jar,CompiereJasper.jar"
prefix="adempiereHome" />
</zip>
<!-- Create adempiereWebCM war -->
<zip destfile="${basedir}/lib/adempiereWebCM.war">
<!-- copy Base -->
<zipfileset src="${basedir}/lib/adempiereWebCMbase.war" />
</zip>
<antcall target="jbossEAR" inheritall="true"/>
<antcall target="glassfishEAR" inheritall="true"/>
</target>
<target name="jbossEAR" if="isAppsJBoss">
<!-- bundle everything in one ear file for simpler deployment -->
<ear destfile="${basedir}/lib/adempiere.ear" appxml="${basedir}/lib/adempiereAll.xml" >
<fileset dir="${basedir}/lib"
includes="Adempiere.jar,AdempiereSLib.jar,adempiereRoot.jar,adempiereApps.jar,adempiereApps.war,adempiereRoot.war,adempiereWebStore.war,adempiereWebCM.war,posterita.war,posterita.jar,webui.war" />
</ear>
</target>
<target name="glassfishEAR" if="isAppsGlassfish">
<unzip src="${basedir}/lib/webui.war" dest="${basedir}/lib/webui"/>
<copy file="${basedir}/lib/webui/WEB-INF/web-2.5.xml" tofile="${basedir}/lib/webui/WEB-INF/web.xml" overwrite="true" />
<delete file="${basedir}/lib/webui.war"/>
<zip destfile="${basedir}/lib/webui.war" basedir="${basedir}/lib/webui" />
<delete dir="${basedir}/lib/webui"/>
<!-- bundle everything in one ear file for simpler deployment -->
<ear destfile="${basedir}/lib/adempiere.ear" appxml="${basedir}/lib/adempiereAll.xml" >
<fileset dir="${basedir}/lib"
includes="adempiereRoot.jar,adempiereApps.jar,adempiereApps.war,adempiereRoot.war,adempiereWebStore.war,adempiereWebCM.war,posterita.war,posterita.jar,webui.war" />
<metainf dir="${basedir}/glassfish" includes="sun-application.xml"/>
</ear>
</target>
<!-- ==================================================== -->
<!-- Setup EAR Libraries -->
<!-- ==================================================== -->
<target name="setupEAR" depends="setupLib"
description="Setup Adempiere EAR Libraries">
<antcall target="createEAR" inheritall="true"/>
</target>
<target name="updateEAR" depends="updateLib">
<antcall target="createEAR" inheritall="true"/>
</target>
<!-- Update JBoss Server -->
<target name="updateJBoss" depends="updateEAR" if="isAppsJBoss"
description="Update JBoss Application Server">
<!-- Copy -->
<echo message="AppsDeployment= ${ADEMPIERE_APPS_DEPLOY}" />
<!-- Deploy in exploded format for faster startup time -->
<unjar dest="${ADEMPIERE_APPS_DEPLOY}/adempiere.ear" src="${basedir}/lib/adempiere.ear" overwrite="true">
</unjar>
</target>
<!-- ==================================================== -->
<!-- Setup Glassfish (Sun Application Server) -->
<!-- ==================================================== -->
<target name="setupGlassfish" depends="setupLib, setupEAR" if="isAppsGlassfish"
description="Setup Glassfish Application Server">
<copy file="${basedir}/lib/adempiere.ear" tofile="${basedir}/glassfish/adempiere.ear"/>
<copy file="${basedir}/lib/Adempiere.jar" tofile="${basedir}/glassfish/Adempiere.jar"/>
<copy file="${basedir}/lib/AdempiereSLib.jar" tofile="${basedir}/glassfish/AdempiereSLib.jar"/>
</target>
<!-- ==================================================== -->
<!-- Setup JBoss Server -->
<!-- ==================================================== -->
<target name="setupJBoss" depends="setupEAR" if="isAppsJBoss"
description="Setup JBoss Application Server">
<!-- Filter JBoss Templates Conf -->
<copy file="${basedir}/jboss/server/adempiere/conf/jboss-serviceTemplate.xml" tofile="${basedir}/jboss/server/adempiere/conf/jboss-service.xml" filtering="yes" overwrite="yes" />
<copy file="${basedir}/jboss/server/adempiere/conf/login-configTemplate.xml" tofile="${basedir}/jboss/server/adempiere/conf/login-config.xml" filtering="yes" overwrite="yes" />
<!-- Filter Tomcat 6.0 -->
<copy file="${basedir}/jboss/server/adempiere/deploy/jboss-web.deployer/serverTemplate.xml" tofile="${basedir}/jboss/server/adempiere/deploy/jboss-web.deployer/server.xml" filtering="yes" overwrite="yes" />
<!-- Delete Old -->
<delete file="${basedir}/jboss/server/adempiere/lib/CClient.jar" failonerror="no" />
<delete file="${basedir}/jboss/server/adempiere/lib/CSTools.jar" failonerror="no" />
<delete file="${basedir}/jboss/server/adempiere/lib/CServer.jar" failonerror="no" />
<delete file="${basedir}/jboss/server/adempiere/lib/oracle.jar" failonerror="no" />
<!-- Copy -->
<echo message="AppsDeployment= ${ADEMPIERE_APPS_DEPLOY}" />
<!-- Deploy in exploded format for faster startup time -->
<unjar dest="${ADEMPIERE_APPS_DEPLOY}/adempiere.ear" src="${basedir}/lib/adempiere.ear" overwrite="true">
</unjar>
</target>
<!-- ==================================================== -->
<!-- Update J2EE Server -->
<!-- ==================================================== -->
<target name="updateDeploy" depends="updateJBoss"
description="Update Adempiere Application Server">
<echo message="AppsDeployment= ${ADEMPIERE_APPS_DEPLOY}" />
</target>
<!-- ==================================================== -->
<!-- Deploy J2EE Server -->
<!-- ==================================================== -->
<target name="setupDeploy" depends="setupJBoss, setupGlassfish"
description="Deploy Adempiere Application Server">
<echo message="AppsDeployment= ${ADEMPIERE_APPS_DEPLOY}" />
</target>
<!-- ==================================================== -->
<!-- Update (Main) -->
<!-- ==================================================== -->
<target name="update" depends="updateDeploy"
description="Update Adempiere Deployment">
</target>
<!-- ==================================================== -->
<!-- Setup (Main) -->
<!-- ==================================================== -->
<target name="setup" depends="setupInit, setupWin, setupNonWin, setupWar"
<target name="setup" depends="setupInit, setupWin, setupNonWin"
description="Setup Adempiere">
</target>
<!-- ==================================================== -->
<!-- Setup (War) -->
<!-- ==================================================== -->
<target name="setupWar"
description="Setup Adempiere ZK Webui">
<unzip src="webapp/bridge.war" dest="webapp/bridge" />
<copy todir="webapp/bridge/WEB-INF/eclipse/plugins">
<fileset dir="osgi/plugins">
<include name="**/*"/>
</fileset>
</copy>
</target>
<!-- ==================================================== -->
<!-- Test - Copy -->
<!-- ==================================================== -->
<target name="testsystemCopy"
description="Copy Adempiere to Test System">
<delete dir="lib" />
<delete dir="jboss" />
<delete dir="log" />
<unzip src="\\\\Dev1\\Adempiere\\Install\\Adempiere_253d.zip"
overwrite="true" />
</target>
<!-- ==================================================== -->
<!-- Test - Import DB -->
<!-- ==================================================== -->
<target name="testsystemImport" depends="setup"
description="Import Adempiere DB">
<exec command="${basedir}/lib/RUN_AdempiereImport" />
</target>
<!-- ==================================================== -->
<!-- Test - Setup -->
<!-- ==================================================== -->
<target name="testsystemSetup" depends="testsystemCopy, testsystemImport"
description="Set up Test System">
</target>
<!-- ==================================================== -->
<!-- Shutting down server, setting up adempiere and importing database -->
<!-- ==================================================== -->

View File

@ -3,18 +3,10 @@ Bundle-ManifestVersion: 2
Bundle-Name: install
Bundle-SymbolicName: org.adempiere.install;singleton:=true
Bundle-Version: 0.0.0.1
Bundle-ClassPath: install.jar,
lib/ant.jar,
lib/ant-commons-net.jar,
lib/ant-launcher.jar,
lib/commons-net-1.4.0.jar,
lib/ocrs12.jar,
lib/ojdbc14.jar
Export-Package: images,
org.compiere.install
Bundle-ClassPath: install.jar
Export-Package: org.compiere.install
Require-Bundle: org.eclipse.core.runtime;bundle-version="3.5.0",
org.adempiere.base;bundle-version="0.0.0",
org.adempiere.client;bundle-version="0.0.0",
org.adempiere.tools;bundle-version="0.0.0"
Bundle-Activator: org.compiere.install.Activator
Bundle-RequiredExecutionEnvironment: JavaSE-1.6

View File

@ -1,4 +1,5 @@
source.install.jar = src/
output.install.jar = build/
bin.includes = META-INF/,\
install.jar,\
plugin.xml

View File

@ -21,7 +21,6 @@
<property name="launch.dir" value="../launch"/>
<property name="keystore.dir" value="../keystore"/>
<property name="data.dir" value="../data"/>
<property name="jboss.dir" value="../jboss"/>
<property name="src" value="src"/>
<property name="compile.dir" value="lib"/>
@ -54,71 +53,12 @@
<!-- create the time stamp -->
<tstamp/>
<mkdir dir="${build.dir}"/>
<mkdir dir="${compile.dir}"/>
</target>
<!-- ======================================================= -->
<!-- Compile & Jar -->
<!-- ======================================================= -->
<target name="installCompile" depends="installInit">
<!-- compile the java code from ${src} into ${build.dir} -->
<javac target="1.6" srcdir="${src}" destdir="${compile.dir}" deprecation="on" debug="on">
<classpath refid="project.class.path"/>
</javac>
<!-- copy all image & sound files from src to the build directory -->
<copy todir="${compile.dir}">
<fileset dir="${src}">
<include name="**/images/*"/>
<include name="**/*.gif"/>
<include name="**/*.jpg"/>
<include name="**/*.wav"/>
<include name="**/*.htm"/>
<include name="**/*.html"/>
<include name="**/*.properties"/>
<exclude name="**/package.html"/>
</fileset>
</copy>
<!-- put everything into the $CInstall.jar file -->
<jar
jarfile="CInstall.jar"
index="yes"
duplicate="preserve">
<fileset dir="${compile.dir}"/>
<!-- Ant (with ftp) files -->
<zipfileset src="../tools/lib/ant.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="../tools/lib/ant-launcher.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="../tools/lib/ant-commons-net.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<zipfileset src="../tools/lib/commons-net-1.4.0.jar" >
<patternset refid="manifest.exclude"/>
</zipfileset>
<manifest>
<attribute name="Specification-Title" value="CInstall"/>
<attribute name="Specification-Version" value="${env.ADEMPIERE_VERSION}"/>
<attribute name="Specification-Vendor" value="Adempiere.org"/>
<attribute name="Implementation-Title" value="CInstall ${env.ADEMPIERE_VERSION}"/>
<attribute name="Implementation-Version" value="${env.ADEMPIERE_VERSION} ${DSTAMP}-${TSTAMP}"/>
<attribute name="Implementation-Vendor" value="${env.ADEMPIERE_VENDOR}"/>
<attribute name="Implementation-URL" value="http://www.adempiere.org"/>
<attribute name="Main-Class" value="org.compiere.install.Setup"/>
<attribute name="Class-Path" value="CTools.jar CClient.jar oracle.jar"/>
</manifest>
</jar>
</target>
<!-- ======================================================= -->
<!-- Update from Web Site + Clean .sh -->
<!-- ======================================================= -->
<target name="installUpdate" depends=""
<target name="installUpdate" depends="plugin"
description="Update install directory with copies of web site">
<fixcrlf srcdir="${src.dir}"
@ -143,20 +83,6 @@
<mkdir dir="${build.dir}"/>
<mkdir dir="${build.dir}/Adempiere"/>
<mkdir dir="${build.dir}/Adempiere/images"/>
<mkdir dir="${build.dir}/Adempiere/packages"/>
<mkdir dir="${build.dir}/Adempiere/zkpackages"/>
<mkdir dir="${build.dir}/Adempiere/packages/liberoMFG"/>
<mkdir dir="${build.dir}/Adempiere/packages/liberoMFG/lib"/>
<copy file="../packages/liberoMFG.jar" tofile="${build.dir}/Adempiere/packages/liberoMFG/lib/liberoMFG.jar"/>
<mkdir dir="${build.dir}/Adempiere/zkpackages/liberoMFG"/>
<mkdir dir="${build.dir}/Adempiere/zkpackages/liberoMFG/lib"/>
<copy file="../zkpackages/liberozkMFG.jar" tofile="${build.dir}/Adempiere/zkpackages/liberoMFG/lib/liberozkMFG.jar"/>
<mkdir dir="${build.dir}/Adempiere/packages/liberoHR"/>
<mkdir dir="${build.dir}/Adempiere/packages/liberoHR/lib"/>
<copy file="../packages/liberoHR.jar" tofile="${build.dir}/Adempiere/packages/liberoHR/lib/liberoHR.jar"/>
<copy file="../lib/CheckConflicts.sh" tofile="${build.dir}/Adempiere/lib/CheckConflicts.sh"/>
@ -182,32 +108,33 @@
<include name="**/*0"/>
</fileset>
</copy>
<copy file="${launch.dir}/Release/Adempiere.exe" todir="${build.dir}/Adempiere/lib"/>
<!-- <copy file="CInstall.jar" todir="${build.dir}/Adempiere/lib"/>
<copy file="../sqlj/sqlj.jar" todir="${build.dir}/Adempiere/lib"/>
<copy file="../JasperReports/CompiereJasperReqs.jar" todir="${build.dir}/Adempiere/lib"/> -->
<concat destfile="${build.dir}/Adempiere/lib/index.html">AdempiereHome</concat>
<!-- OSGi Container -->
<mkdir dir="${build.dir}/Adempiere/osgi"/>
<copy overwrite="true" todir="${build.dir}/Adempiere/osgi" >
<fileset dir="../equinox-target">
<include name="configuration/**/*"/>
<include name="plugins/**/*"/>
<include name="org.eclipse.*.jar"/>
</fileset>
<fileset dir="../equinox-target/spring">
<include name="plugins/**/*"/>
</fileset>
<fileset dir="../lib">
<include name="plugins/**/*"/>
</fileset>
</copy>
<!-- Bridge webapp -->
<mkdir dir="${build.dir}/Adempiere/webapp"/>
<copy overwrite="true" todir="${build.dir}/Adempiere/webapp" >
<fileset dir="../lib">
<include name="bridge.war"/>
<copy overwrite="true" todir="${build.dir}/Adempiere/osgi/client" >
<fileset dir="../equinox-target/configuration">
<include name="*.ini"/>
</fileset>
</copy>
<copy overwrite="true" todir="${build.dir}/Adempiere/osgi/server" >
<fileset dir="../equinox-target/webapp/configuration">
<include name="*.ini"/>
</fileset>
</copy>
<delete dir="${build.dir}/Adempiere/lib/plugins"/>
<!-- Utils Directory -->
<mkdir dir="${build.dir}/Adempiere/utils"/>
@ -244,30 +171,6 @@
</fileset>
</copy>
<!-- JBoss Directory -->
<mkdir dir="${build.dir}/Adempiere/jboss"/>
<mkdir dir="${build.dir}/Adempiere/jboss/bin"/>
<copy todir="${build.dir}/Adempiere/jboss/bin">
<fileset dir="${jboss.dir}/bin" excludes="**/CVS/**"/>
</copy>
<mkdir dir="${build.dir}/Adempiere/jboss/lib"/>
<copy todir="${build.dir}/Adempiere/jboss/lib">
<fileset dir="${jboss.dir}/lib" excludes="**/CVS/**"/>
</copy>
<mkdir dir="${build.dir}/Adempiere/jboss/server"/>
<copy todir="${build.dir}/Adempiere/jboss/server">
<fileset dir="${jboss.dir}/server"
excludes="**/CVS/**"/>
</copy>
<!-- GlassFish -->
<mkdir dir="${build.dir}/Adempiere/glassfish"/>
<copy todir="${build.dir}/Adempiere/glassfish">
<fileset dir="../glassfishfacet/config"/>
</copy>
<!-- Create Install ZIP -->
<zip zipfile="${build.dir}/Adempiere_${env.ADEMPIERE_VERSION_FILE}.zip"
basedir="${build.dir}"
@ -289,17 +192,20 @@
</target>
<target name="plugin">
<buildPlugin workspaceDirectory=".."
<target name="plugin" depends="installInit">
<buildPlugin workspaceDirectory="${workspace}"
projectName="install"
targetPlatformId="target.platform"
destination="${dist.dir}"
destination="../lib"
buildSourceJar="false" />
</target>
<target name="clean" description="deletes build">
<delete dir="${build.dir}"/>
<delete dir="${compile.dir}"/>
<delete>
<fileset dir="../lib/plugins">
<include name="org.adempiere.install*.jar"/>
</fileset>
</delete>
</target>
</project>

View File

@ -16,24 +16,23 @@
*****************************************************************************/
package org.compiere.install;
import java.io.File;
import java.net.InetAddress;
/**
* JBoss 4.0.2 Apps Server Configuration
* Apps Server Configuration
*
* @author Jorg Janke
* @author hengsin
* @version $Id: ConfigJBoss.java,v 1.3 2006/07/30 00:57:42 jjanke Exp $
*/
public class ConfigJBoss extends Config
public class ConfigAppServer extends Config
{
/**
* ConfigJBoss
* @param data configuration
*/
public ConfigJBoss (ConfigurationData data)
public ConfigAppServer(ConfigurationData data)
{
super (data);
} // ConfigJBoss
@ -43,30 +42,12 @@ public class ConfigJBoss extends Config
*/
public void init()
{
p_data.setAppsServerDeployDir(getDeployDir());
p_data.setAppsServerDeployDir(false);
//
p_data.setAppsServerJNPPort("1099");
p_data.setAppsServerJNPPort(true);
p_data.setAppsServerWebPort("80");
p_data.setAppsServerWebPort(true);
p_data.setAppsServerSSLPort("443");
p_data.setAppsServerSSLPort(true);
} // init
/**
* Get Deployment Dir
* @return deployment dir
*/
private String getDeployDir()
{
return p_data.getAdempiereHome()
+ File.separator + "jboss"
+ File.separator + "server"
+ File.separator + "adempiere"
+ File.separator + "deploy";
} // getDeployDir
/**
* Test
* @return error message or null if OK
@ -97,33 +78,6 @@ public class ConfigJBoss extends Config
return error;
log.info("OK: AppsServer = " + appsServer);
setProperty(ConfigurationData.ADEMPIERE_APPS_SERVER, appsServer.getHostName());
setProperty(ConfigurationData.ADEMPIERE_APPS_TYPE, p_data.getAppsServerType());
// Deployment Dir
p_data.setAppsServerDeployDir(getDeployDir());
File deploy = new File (p_data.getAppsServerDeployDir());
pass = deploy.exists();
error = "Not found: " + deploy;
if (getPanel() != null)
signalOK(getPanel().okDeployDir, "ErrorDeployDir",
pass, true, error);
if (!pass)
return error;
setProperty(ConfigurationData.ADEMPIERE_APPS_DEPLOY, p_data.getAppsServerDeployDir());
log.info("OK: Deploy Directory = " + deploy);
// JNP Port
int JNPPort = p_data.getAppsServerJNPPort();
pass = !p_data.testPort (appsServer, JNPPort, false)
&& p_data.testServerPort(JNPPort);
error = "Not correct: JNP Port = " + JNPPort;
if (getPanel() != null)
signalOK(getPanel().okJNPPort, "ErrorJNPPort",
pass, true, error);
if (!pass)
return error;
log.info("OK: JNPPort = " + JNPPort);
setProperty(ConfigurationData.ADEMPIERE_JNP_PORT, String.valueOf(JNPPort));
// Web Port
int WebPort = p_data.getAppsServerWebPort();

View File

@ -1,153 +0,0 @@
/**********************************************************************
* This file is part of Adempiere ERP Bazaar *
* http://www.adempiere.org *
* *
* Copyright (C) Praneet Tiwari. *
* Copyright (C) Contributors *
* *
* This program is free software; you can redistribute it and/or *
* modify it under the terms of the GNU General Public License *
* as published by the Free Software Foundation; either version 2 *
* of the License, or (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, *
* MA 02110-1301, USA. *
* *
* Contributors: *
* - Trifon Trifonov (trifonnt@users.sourceforge.net) *
* *
* Sponsors: *
* - D3 Soft (http://www.d3-soft.com) *
***********************************************************************/
package org.compiere.install;
import java.io.File;
import java.net.InetAddress;
/**
* GlassFish v2UR1 Apps Server Configuration
*
* @author Praneet Tiwari
* @author Trifon Trifonov
* @version $Id: $
*/
public class ConfigGlassfish extends Config {
/**
* ConfigGlassfish
* @param data configuration
*/
public ConfigGlassfish (ConfigurationData data)
{
super (data);
} // ConfigGlassfish
/**
* Initialize
*/
public void init()
{
p_data.setAppsServerDeployDir(getDeployDir());
p_data.setAppsServerDeployDir(false);
//
p_data.setAppsServerJNPPort("3700");
p_data.setAppsServerJNPPort(true);
p_data.setAppsServerWebPort("8080");
p_data.setAppsServerWebPort(true);
p_data.setAppsServerSSLPort("443");
p_data.setAppsServerSSLPort(true);
} // init
/**
* Get Deployment Dir
* @return deployment dir
*/
private String getDeployDir()
{
// TODO - check deployment directory
return p_data.getAdempiereHome() + File.separator + "glassfish";
/*Commented for now
+ File.separator + "glassfish"
+ File.separator + "domains"
+ File.separator + "domain1" ;
* */
} // getDeployDir
/**
* Test
* @return error message or null if OK
*/
public String test()
{
// AppsServer
String server = p_data.getAppsServer();
boolean pass = server != null && server.length() > 0
&& server.toLowerCase().indexOf("localhost") == -1
&& !server.equals("127.0.0.1");
InetAddress appsServer = null;
String error = "Not correct: AppsServer = " + server;
try
{
if (pass)
appsServer = InetAddress.getByName(server);
}
catch (Exception e)
{
error += " - " + e.getMessage();
pass = false;
}
if (getPanel() != null)
signalOK(getPanel().okAppsServer, "ErrorAppsServer",
pass, true, error);
if (!pass)
return error;
log.info("OK: AppsServer = " + appsServer);
setProperty(ConfigurationData.ADEMPIERE_APPS_SERVER, appsServer.getHostName());
setProperty(ConfigurationData.ADEMPIERE_APPS_TYPE, p_data.getAppsServerType());
setProperty(ConfigurationData.ADEMPIERE_APPS_DEPLOY, p_data.getAppsServerDeployDir());
// JNP Port
int JNPPort = p_data.getAppsServerJNPPort();
setProperty(ConfigurationData.ADEMPIERE_JNP_PORT, String.valueOf(JNPPort));
// Web Port
int WebPort = p_data.getAppsServerWebPort();
pass = !p_data.testPort ("http", appsServer.getHostName(), WebPort, "/")
&& p_data.testServerPort(WebPort);
error = "Not correct: Web Port = " + WebPort;
if (getPanel() != null)
signalOK(getPanel().okWebPort, "ErrorWebPort",
pass, true, error);
if (!pass)
return error;
log.info("OK: Web Port = " + WebPort);
setProperty(ConfigurationData.ADEMPIERE_WEB_PORT, String.valueOf(WebPort));
// SSL Port
int sslPort = p_data.getAppsServerSSLPort();
pass = !p_data.testPort ("https", appsServer.getHostName(), sslPort, "/")
&& p_data.testServerPort(sslPort);
error = "Not correct: SSL Port = " + sslPort;
if (getPanel() != null)
signalOK(getPanel().okSSLPort, "ErrorWebPort",
pass, true, error);
if (!pass)
return error;
log.info("OK: SSL Port = " + sslPort);
setProperty(ConfigurationData.ADEMPIERE_SSL_PORT, String.valueOf(sslPort));
//
return null;
} // test
} // ConfigGlassfish

View File

@ -231,14 +231,8 @@ public class ConfigurationData
}
setKeyStore(s);
//
int appServerIndex = setAppsServerType((String)p_properties.get(ADEMPIERE_APPS_TYPE));
initAppsServer(appServerIndex);
if (loaded.containsKey(ADEMPIERE_APPS_SERVER))
setAppsServer((String)loaded.get(ADEMPIERE_APPS_SERVER));
if (loaded.containsKey(ADEMPIERE_APPS_DEPLOY))
setAppsServerDeployDir((String)loaded.get(ADEMPIERE_APPS_DEPLOY));
if (loaded.containsKey(ADEMPIERE_JNP_PORT))
setAppsServerJNPPort((String)loaded.get(ADEMPIERE_JNP_PORT));
if (loaded.containsKey(ADEMPIERE_WEB_PORT))
setAppsServerWebPort((String)loaded.get(ADEMPIERE_WEB_PORT));
if (loaded.containsKey(ADEMPIERE_SSL_PORT))
@ -854,7 +848,6 @@ public class ConfigurationData
getDatabaseServer(), getDatabasePort(), getDatabaseName(),
getDatabaseUser(), getDatabasePassword());
cc.setAppsHost(getAppsServer());
cc.setAppsPort(getAppsServerJNPPort());
cc.setConnectionProfile(CConnection.PROFILE_LAN);
}
catch(Exception e)
@ -949,6 +942,7 @@ public class ConfigurationData
/** Virtual machine Configurations */
private Config[] m_javaConfig = new Config[]
{new ConfigVMSun(this), new ConfigVMOpenJDK(this), new ConfigVMMac(this), null};
private ConfigAppServer m_appsConfig = new ConfigAppServer(this);
/**
* Init Database
@ -1049,103 +1043,23 @@ public class ConfigurationData
updateProperty(JAVA_HOME, javaHome);
}
/**************************************************************************
* Apps Server Settings
*************************************************************************/
/** JBoss (default) */
protected static String APPSTYPE_JBOSS = "jboss";
/** GlassFish */
protected static String APPSTYPE_GLASSFISH = "glassfish";
/** Application Server Type */
static String[] APPSTYPE = new String[]
{ APPSTYPE_JBOSS
, APPSTYPE_GLASSFISH
};
/** Database Configs */
private Config[] m_appsConfig = new Config[]
{ new ConfigJBoss(this)
, new ConfigGlassfish( this )
};
/**
* Init Apps Server
*/
public void initAppsServer()
{
int index = (p_panel != null ? p_panel.fAppsType.getSelectedIndex() : 0);
initAppsServer(index);
m_appsConfig.init();
} // initAppsServer
private void initAppsServer(int index)
{
if (index < 0 || index >= APPSTYPE.length)
log.warning("AppsServerType Index invalid: " + index);
else if (m_appsConfig[index] == null)
{
log.warning("AppsServerType Config missing: " + APPSTYPE[index]);
p_panel.fAppsType.setSelectedIndex(0);
}
else
m_appsConfig[index].init();
}
/**
* Test Apps Server
* @return error message or null of OK
*/
public String testAppsServer()
{
int index = p_panel != null
? p_panel.fAppsType.getSelectedIndex()
: setAppsServerType((String)p_properties.get(ADEMPIERE_APPS_TYPE));
if (index < 0 || index >= APPSTYPE.length)
return "AppsServerType Index invalid: " + index;
else if (m_appsConfig[index] == null)
return "AppsServerType Config class missing: " + index;
return m_appsConfig[index].test();
return m_appsConfig.test();
} // testAppsServer
/**
* Set Apps Server Type
* @param appsType The appsType to set.
*/
public int setAppsServerType (String appsType)
{
int index = -1;
for (int i = 0; i < APPSTYPE.length; i++)
{
if (APPSTYPE[i].equals(appsType))
{
index = i;
break;
}
}
if (index == -1)
{
index = 0;
log.warning("Invalid AppsType=" + appsType);
}
if (p_panel != null)
p_panel.fAppsType.setSelectedIndex(index);
else
updateProperty(ADEMPIERE_APPS_TYPE, appsType);
return index;
} // setAppsServerType
/**
* Get Apps Server Type
* @return Apps Server Type
*/
public String getAppsServerType ()
{
return p_panel != null
? (String)p_panel.fAppsType.getSelectedItem()
: (String)p_properties.get(ADEMPIERE_APPS_TYPE);
} // setDatabaseType
/**
* @return Returns the appsServer.
*/
@ -1166,73 +1080,6 @@ public class ConfigurationData
updateProperty(ADEMPIERE_APPS_SERVER, appsServer);
}
/**
* @return Returns the appsServerDeployDir.
*/
public String getAppsServerDeployDir ()
{
return p_panel != null
? p_panel.fDeployDir.getText()
: (String)p_properties.get(ADEMPIERE_APPS_DEPLOY);
}
/**
* @param appsServerDeployDir The appsServerDeployDir to set.
*/
public void setAppsServerDeployDir (String appsServerDeployDir)
{
if (p_panel != null)
p_panel.fDeployDir.setText(appsServerDeployDir);
else
updateProperty(ADEMPIERE_APPS_DEPLOY, appsServerDeployDir);
}
/**
* @param enable if true enable entry
*/
public void setAppsServerDeployDir (boolean enable)
{
if (p_panel != null)
{
p_panel.fDeployDir.setEnabled(enable);
p_panel.bDeployDir.setEnabled(enable);
}
}
/**
* @return Returns the appsServerJNPPort.
*/
public int getAppsServerJNPPort ()
{
String port = p_panel != null
? p_panel.fJNPPort.getText()
: (String)p_properties.get(ADEMPIERE_JNP_PORT);
try
{
return Integer.parseInt(port);
}
catch (Exception e)
{
setAppsServerJNPPort("0");
}
return 0;
}
/**
* @param appsServerJNPPort The appsServerJNPPort to set.
*/
public void setAppsServerJNPPort (String appsServerJNPPort)
{
if (p_panel != null)
p_panel.fJNPPort.setText(appsServerJNPPort);
else
updateProperty(ADEMPIERE_JNP_PORT, appsServerJNPPort);
}
/**
* @param enable if enable JNP entry
*/
public void setAppsServerJNPPort (boolean enable)
{
if (p_panel != null)
p_panel.fJNPPort.setEnabled(enable);
}
/**
* @return Returns the appsServerSSLPort.
*/

View File

@ -38,7 +38,6 @@ import javax.swing.border.TitledBorder;
import org.adempiere.base.Core;
import org.apache.tools.ant.Main;
import org.compiere.Adempiere;
import org.compiere.swing.CButton;
import org.compiere.swing.CCheckBox;
import org.compiere.swing.CComboBox;
@ -48,9 +47,6 @@ import org.compiere.swing.CPassword;
import org.compiere.swing.CTextField;
import org.compiere.util.CLogger;
import com.sfcommerce.jpaymentcomponent.ssl.Client;
/**
* Configuration Panel
*
@ -93,8 +89,6 @@ public class ConfigurationPanel extends CPanel implements ActionListener
/** Translation */
static ResourceBundle res = ResourceBundle.getBundle("org.compiere.install.SetupRes");
/** Setup Frame */
private Setup m_setup = null;
/** Status Bar */
private JLabel m_statusBar;
/** Configuration Data */
@ -127,16 +121,6 @@ public class ConfigurationPanel extends CPanel implements ActionListener
CLabel lAppsServer = new CLabel();
CTextField fAppsServer = new CTextField(FIELDLENGTH);
CCheckBox okAppsServer = new CCheckBox();
private CLabel lAppsType = new CLabel();
CComboBox fAppsType = new CComboBox(ConfigurationData.APPSTYPE);
// Deployment Directory - JNP
private CLabel lDeployDir = new CLabel();
CTextField fDeployDir = new CTextField(FIELDLENGTH);
CCheckBox okDeployDir = new CCheckBox();
CButton bDeployDir = new CButton(iOpen);
private CLabel lJNPPort = new CLabel();
CTextField fJNPPort = new CTextField(FIELDLENGTH);
CCheckBox okJNPPort = new CCheckBox();
// Web Ports
private CLabel lWebPort = new CLabel();
CTextField fWebPort = new CTextField(FIELDLENGTH);
@ -263,9 +247,6 @@ public class ConfigurationPanel extends CPanel implements ActionListener
lAppsServer.setFont(lAppsServer.getFont().deriveFont(Font.BOLD));
fAppsServer.setText(".");
okAppsServer.setEnabled(false);
lAppsType.setToolTipText(res.getString("AppsTypeInfo"));
lAppsType.setText(res.getString("AppsType"));
fAppsType.setPreferredSize(fAppsServer.getPreferredSize());
sectionLabel = new JLabel(res.getString("AppsServer"));
sectionLabel.setForeground(titledBorder.getTitleColor());
separator = new JSeparator();
@ -279,35 +260,6 @@ public class ConfigurationPanel extends CPanel implements ActionListener
,GridBagConstraints.WEST, GridBagConstraints.BOTH, new Insets(5, 5, 2, 0), 0, 0));
this.add(okAppsServer, new GridBagConstraints(2, 8, 1, 1, 0.0, 0.0
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(5, 0, 2, 5), 0, 0));
this.add(lAppsType, new GridBagConstraints(4, 8, 1, 1, 0.0, 0.0
,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 2, 5), 0, 0));
this.add(fAppsType, new GridBagConstraints(5, 8, 1, 1, 0.0, 0.0
,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 5, 2, 0), 0, 0));
// Deployment - JNP
lDeployDir.setToolTipText(res.getString("DeployDirInfo"));
lDeployDir.setText(res.getString("DeployDir"));
fDeployDir.setText(".");
okDeployDir.setEnabled(false);
bDeployDir.setMargin(bInsets);
bDeployDir.setToolTipText(res.getString("DeployDirInfo"));
lJNPPort.setToolTipText(res.getString("JNPPortInfo"));
lJNPPort.setText(res.getString("JNPPort"));
fJNPPort.setText(".");
okJNPPort.setEnabled(false);
this.add(lDeployDir, new GridBagConstraints(0, 9, 1, 1, 0.0, 0.0
,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(2, 5, 2, 5), 0, 0));
this.add(fDeployDir, new GridBagConstraints(1, 9, 1, 1, 0.5, 0.0
,GridBagConstraints.WEST, GridBagConstraints.BOTH, new Insets(2, 5, 2, 0), 0, 0));
this.add(okDeployDir, new GridBagConstraints(2, 9, 1, 1, 0.0, 0.0
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(2, 0, 2, 5), 0, 0));
this.add(bDeployDir, new GridBagConstraints(3, 9, 1, 1, 0.0, 0.0
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
this.add(lJNPPort, new GridBagConstraints(4, 9, 1, 1, 0.0, 0.0
,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(2, 5, 2, 5), 0, 0));
this.add(fJNPPort, new GridBagConstraints(5, 9, 1, 1, 0.5, 0.0
,GridBagConstraints.WEST, GridBagConstraints.BOTH, new Insets(2, 5, 2, 0), 0, 0));
this.add(okJNPPort, new GridBagConstraints(6, 9, 1, 1, 0.0, 0.0
,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(2, 0, 2, 5), 0, 0));
// Web Ports
lWebPort.setToolTipText(res.getString("WebPortInfo"));
lWebPort.setText(res.getString("WebPort"));
@ -480,9 +432,7 @@ public class ConfigurationPanel extends CPanel implements ActionListener
//
bAdempiereHome.addActionListener(this);
bJavaHome.addActionListener(this);
bDeployDir.addActionListener(this);
fJavaType.addActionListener(this);
fAppsType.addActionListener(this);
fDatabaseType.addActionListener(this);
fDatabaseDiscovered.addActionListener(this);
bHelp.addActionListener(this);
@ -528,8 +478,6 @@ public class ConfigurationPanel extends CPanel implements ActionListener
//
else if (e.getSource() == fJavaType)
m_data.initJava();
else if (e.getSource() == fAppsType)
m_data.initAppsServer();
else if (e.getSource() == fDatabaseType)
m_data.initDatabase("");
//
@ -537,8 +485,6 @@ public class ConfigurationPanel extends CPanel implements ActionListener
setPath (fJavaHome);
else if (e.getSource() == bAdempiereHome)
setPath (fAdempiereHome);
else if (e.getSource() == bDeployDir)
setPath (fDeployDir);
else if (e.getSource() == bHelp)
new Setup_Help((Frame)SwingUtilities.getWindowAncestor(this));
else if (e.getSource() == bTest)