forked from openhab/openhab-addons
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Format start scripts and add check for not found equinox launcher
If the equinox launcher jar is not present, there was no error message. Signed-off-by: Sebastian Janzen <[email protected]>
- Loading branch information
Showing
4 changed files
with
118 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,37 @@ | ||
@echo off | ||
|
||
:: set path to eclipse folder. If local folder, use '.'; otherwise, use c:\path\to\eclipse | ||
set ECLIPSEHOME="runtime\server" | ||
|
||
:: set ports for HTTP(S) server | ||
set HTTP_PORT=8080 | ||
set HTTPS_PORT=8443 | ||
|
||
:: get path to equinox jar inside ECLIPSEHOME folder | ||
for /f "delims= tokens=1" %%c in ('dir /B /S /OD %ECLIPSEHOME%\plugins\org.eclipse.equinox.launcher_*.jar') do set EQUINOXJAR=%%c | ||
|
||
:: program params | ||
set PROG_ARGS=-Dlogback.configurationFile=./runtime/etc/logback.xml -DmdnsName=openhab -Dopenhab.logdir=./userdata/logs -Dsmarthome.servicecfg=./runtime/etc/services.cfg -Dsmarthome.userdata=./userdata -Dsmarthome.servicepid=org.openhab -Dorg.quartz.properties=./runtime/etc/quartz.properties -Djetty.etc.config.urls=etc/jetty.xml,etc/jetty-ssl.xml,etc/jetty-deployer.xml,etc/jetty-https.xml,etc/jetty-selector.xml | ||
|
||
:: start Eclipse w/ java | ||
echo Launching the openHAB runtime... | ||
java %PROG_ARGS% -Dosgi.clean=true -Declipse.ignoreApp=true -Dosgi.noShutdown=true -Djetty.home.bundle=org.openhab.io.jetty -Dorg.osgi.service.http.port=%HTTP_PORT% -Dorg.osgi.service.http.port.secure=%HTTPS_PORT% -Dfelix.fileinstall.dir=addons -Djava.library.path=lib -Dequinox.ds.block_timeout=240000 -Dequinox.scr.waitTimeOnBlock=60000 -Dfelix.fileinstall.active.level=4 -Djava.awt.headless=true -jar %EQUINOXJAR% %* -console | ||
@echo off | ||
|
||
:: set path to eclipse folder. If local folder, use '.'; otherwise, use c:\path\to\eclipse | ||
set ECLIPSEHOME=server | ||
|
||
:: set ports for HTTP(S) server | ||
set HTTP_PORT=8080 | ||
set HTTPS_PORT=8443 | ||
|
||
:: get path to equinox jar inside ECLIPSEHOME folder | ||
for /f "delims= tokens=1" %%c in ('dir /B /S /OD %ECLIPSEHOME%\plugins\org.eclipse.equinox.launcher_*.jar') do set EQUINOXJAR=%%c | ||
|
||
IF NOT [%EQUINOXJAR%] == [] GOTO :Launch | ||
echo No equinox launcher in path '%ECLIPSEHOME%' found! | ||
goto :eof | ||
|
||
:Launch | ||
:: start Eclipse w/ java | ||
echo Launching the openHAB runtime... | ||
java ^ | ||
-Dosgi.clean=true ^ | ||
-Declipse.ignoreApp=true ^ | ||
-Dosgi.noShutdown=true ^ | ||
-Djetty.port=%HTTP_PORT% ^ | ||
-Djetty.port.ssl=%HTTPS_PORT% ^ | ||
-Djetty.home=. ^ | ||
-Dlogback.configurationFile=configurations/logback.xml ^ | ||
-Dfelix.fileinstall.dir=addons ^ | ||
-Djava.library.path=lib ^ | ||
-Djava.security.auth.login.config=./etc/login.conf ^ | ||
-Dorg.quartz.properties=./etc/quartz.properties ^ | ||
-Dequinox.ds.block_timeout=240000 ^ | ||
-Dequinox.scr.waitTimeOnBlock=60000 ^ | ||
-Djava.awt.headless=true ^ | ||
-Dfelix.fileinstall.active.level=4 ^ | ||
-jar %EQUINOXJAR% %* ^ | ||
-console |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,41 @@ | ||
@echo off | ||
|
||
:: set path to eclipse folder. If local folder, use '.'; otherwise, use c:\path\to\eclipse | ||
set ECLIPSEHOME="runtime\server" | ||
|
||
:: set ports for HTTP(S) server | ||
set HTTP_PORT=8080 | ||
set HTTPS_PORT=8443 | ||
|
||
:: get path to equinox jar inside ECLIPSEHOME folder | ||
for /f "delims= tokens=1" %%c in ('dir /B /S /OD %ECLIPSEHOME%\plugins\org.eclipse.equinox.launcher_*.jar') do set EQUINOXJAR=%%c | ||
|
||
:: debug options | ||
set DEBUG_OPTS=-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,address=8001,server=y,suspend=n | ||
|
||
:: program params | ||
set PROG_ARGS=-Dlogback.configurationFile=./runtime/etc/logback_debug.xml -DmdnsName=openhab -Dopenhab.logdir=./userdata/logs -Dsmarthome.servicecfg=./runtime/etc/services.cfg -Dsmarthome.servicepid=org.openhab -Dorg.quartz.properties=./runtime/etc/quartz.properties -Djetty.etc.config.urls=etc/jetty.xml,etc/jetty-ssl.xml,etc/jetty-deployer.xml,etc/jetty-https.xml,etc/jetty-selector.xml | ||
|
||
:: start Eclipse w/ java | ||
echo Launching the openHAB runtime... | ||
java %DEBUG_OPTS% %PROG_ARGS% -Dosgi.clean=true -Declipse.ignoreApp=true -Dosgi.noShutdown=true -Djetty.home.bundle=org.openhab.io.jetty -Dorg.osgi.service.http.port=%HTTP_PORT% -Dorg.osgi.service.http.port.secure=%HTTPS_PORT% -Dfelix.fileinstall.dir=addons -Djava.library.path=lib -Dequinox.ds.block_timeout=240000 -Dequinox.scr.waitTimeOnBlock=60000 -Dfelix.fileinstall.active.level=4 -Djava.awt.headless=true -jar %EQUINOXJAR% %* -console | ||
@echo off | ||
|
||
:: set path to eclipse folder. If local folder, use '.'; otherwise, use c:\path\to\eclipse | ||
set ECLIPSEHOME=server | ||
|
||
:: set ports for HTTP(S) server | ||
set HTTP_PORT=8080 | ||
set HTTPS_PORT=8443 | ||
|
||
:: get path to equinox jar inside ECLIPSEHOME folder | ||
for /f "delims= tokens=1" %%c in ('dir /B /S /OD %ECLIPSEHOME%\plugins\org.eclipse.equinox.launcher_*.jar') do set EQUINOXJAR=%%c | ||
|
||
IF NOT [%EQUINOXJAR%] == [] GOTO :Launch | ||
echo No equinox launcher in path '%ECLIPSEHOME%' found! | ||
goto :eof | ||
|
||
:Launch | ||
:: debug options | ||
set DEBUG_OPTS=-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,address=8001,server=y,suspend=n | ||
|
||
:: start Eclipse w/ java | ||
echo Launching the openHAB runtime... | ||
java ^ | ||
%DEBUG_OPTS% ^ | ||
-Dosgi.clean=true ^ | ||
-Declipse.ignoreApp=true ^ | ||
-Dosgi.noShutdown=true ^ | ||
-Djetty.port=%HTTP_PORT% ^ | ||
-Djetty.port.ssl=%HTTPS_PORT% ^ | ||
-Djetty.home=. ^ | ||
-Dlogback.configurationFile=configurations/logback_debug.xml ^ | ||
-Dfelix.fileinstall.dir=addons ^ | ||
-Djava.library.path=lib ^ | ||
-Dorg.quartz.properties=./etc/quartz.properties ^ | ||
-Djava.security.auth.login.config=./etc/login.conf ^ | ||
-Dequinox.ds.block_timeout=240000 ^ | ||
-Dequinox.scr.waitTimeOnBlock=60000 ^ | ||
-Dfelix.fileinstall.active.level=4 ^ | ||
-Djava.awt.headless=true ^ | ||
-jar %EQUINOXJAR% %* ^ | ||
-console |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters