| opends/resource/upgrade | ●●●●● patch | view | raw | blame | history | |
| opends/resource/upgrade.bat | ●●●●● patch | view | raw | blame | history |
opends/resource/upgrade
@@ -130,23 +130,35 @@ rm -fr "${INSTANCE_ROOT}/tmp/upgrade" fi # Launch the build extractor. # Configure the appropriate CLASSPATH. # BuildExtractor uses the existing install's # jars CLASSPATH=${INSTANCE_ROOT}/classes for JAR in ${INSTANCE_ROOT}/lib/*.jar do CLASSPATH=${CLASSPATH}:${JAR} done export CLASSPATH "${JAVA_BIN}" org.opends.quicksetup.upgrader.BuildExtractor "${@}" if test ${?} -eq 0 # Test for presence of command line arguments if test -z "$1" then # If no arguments launch web start version JAVAWS_VM_ARGS="-Dorg.opends.quicksetup.upgrader.Root=$INSTANCE_ROOT" export JAVAWS_VM_ARGS if test -z "${OPENDS_UPGRADE_JNLP}" then OPENDS_UPGRADE_JNLP=http://builds.opends.org/install/QuickUpgrade.jnlp fi "${JAVAWS_BIN}" "${OPENDS_UPGRADE_JNLP}" else # Launch the build extractor. # Configure the appropriate CLASSPATH. # BuildExtractor uses the existing install's # jars CLASSPATH=${INSTANCE_ROOT}/classes for JAR in ${INSTANCE_ROOT}/lib/*.jar do CLASSPATH=${CLASSPATH}:${JAR} done export CLASSPATH "${JAVA_BIN}" org.opends.quicksetup.upgrader.BuildExtractor "${@}" if [ -r "${INSTANCE_ROOT}/tmp/upgrade" ] then # Configure the appropriate CLASSPATH. # Unlike BuildExtractor, the Upgrader uses # the newly extracted build's jars. @@ -164,12 +176,8 @@ rm -fr "${INSTANCE_ROOT}/tmp/upgrade" fi else JAVAWS_VM_ARGS="-Dorg.opends.quicksetup.upgrader.Root=$INSTANCE_ROOT" export JAVAWS_VM_ARGS if test -z "${OPENDS_UPGRADE_JNLP}" then OPENDS_UPGRADE_JNLP=http://builds.opends.org/install/QuickUpgrade.jnlp fi "${JAVAWS_BIN}" "${OPENDS_UPGRADE_JNLP}" # Build extractor didn't work. Invoke the upgrader # to report errors and usage. "${JAVA_BIN}" org.opends.quicksetup.upgrader.UpgradeLauncher "${@}" fi fi opends/resource/upgrade.bat
@@ -39,7 +39,7 @@ if "%JAVA_HOME%" == "" goto noJavaHome if not exist "%JAVA_HOME%\bin\java.exe" goto noJavaHome set JAVA_BIN=%JAVA_HOME%\bin\java.exe set jAVAWS_BIN=%JAVA_HOME%\bin\javaws.exe set JAVAWS_BIN=%JAVA_HOME%\bin\javaws.exe if "%*" == "" goto callWebStartUpgrade goto callExtractor @@ -47,7 +47,7 @@ if not exist "%INSTANCE_ROOT%\lib\set-java-home.bat" goto noSetJavaHome call "%INSTANCE_ROOT%\lib\set-java-home.bat" set JAVA_BIN=%JAVA_HOME%\bin\java.exe set jAVAWS_BIN=%JAVA_HOME%\bin\javaws.exe set JAVAWS_BIN=%JAVA_HOME%\bin\javaws.exe if "%*" == "" goto callWebStartUpgrade goto callExtractor @@ -75,8 +75,7 @@ set CLASSPATH="" FOR %%x in ("%INSTANCE_ROOT%\lib\*.jar") DO call "%INSTANCE_ROOT%\lib\setcp.bat" %%x "%JAVA_BIN%" org.opends.quicksetup.upgrader.BuildExtractor %* if %ERRORLEVEL%==0 goto callUpgrader goto end goto prepUpgrader :callWebStartUpgrade rem set JAVAWS_VM_ARGS=-Dorg.opends.quicksetup.upgrader.Root="%INSTANCE_ROOT%" @@ -84,9 +83,16 @@ "%JAVAWS_BIN%" "%OPENDS_UPGRADE_JNLP%" goto end :callUpgrader :prepUpgrader if EXIST %INSTANCE_ROOT%\tmp\upgrade goto setClassPathToStageDir goto callUpgrader :setClassPathToStageDir set CLASSPATH="" FOR %%x in ("%INSTANCE_ROOT%\tmp\upgrade\lib\*.jar") DO call "%INSTANCE_ROOT%\lib\setcp.bat" %%x goto callUpgrader :callUpgrader "%JAVA_BIN%" org.opends.quicksetup.upgrader.UpgradeLauncher %* if EXIST %INSTANCE_ROOT%\tmp\upgrade rd %INSTANCE_ROOT%\tmp\upgrade /s /q goto end