diff --git a/opensync-gateway-cloud-docker/src/main/docker/app/run.sh b/opensync-gateway-cloud-docker/src/main/docker/app/run.sh index fd560c8..ea389a4 100755 --- a/opensync-gateway-cloud-docker/src/main/docker/app/run.sh +++ b/opensync-gateway-cloud-docker/src/main/docker/app/run.sh @@ -113,10 +113,15 @@ FILE_STORE_PROPS=" " FILE_STORE_PROPS+=" -Dtip.wlan.fileStoreDirectory=$FILE_STORE_DIRECTORY" FILE_STORE_PROPS+=" -Dtip.wlan.externalFileStoreURL=$FILE_STORE_EXTERNAL_URL" -REMOTE_DEBUG_PORT=5005 -REMOTE_DEBUG=" -agentlib:jdwp=transport=dt_socket,server=y,address=*:$REMOTE_DEBUG_PORT,suspend=n" +REMOTE_DEBUG_PORT=${REMOTE_DEBUG_PORT:-'5005'} +if [ "x$REMOTE_DEBUG_ENABLE" == "xtrue" ] +then + REMOTE_DEBUG=" -agentlib:jdwp=transport=dt_socket,server=y,address=*:$REMOTE_DEBUG_PORT,suspend=n" +else + REMOTE_DEBUG=" " +fi -JVM_EXTRA_PROPS=" ${JVM_MEM_OPTIONS:' '} " +JVM_EXTRA_PROPS=" ${JVM_MEM_OPTIONS:-' '} " export ALL_PROPS="$JVM_EXTRA_PROPS $PROFILES $SSL_PROPS $CLIENT_MQTT_SSL_PROPS $OVSDB_PROPS $MQTT_PROPS $LOGGING_PROPS $RESTAPI_PROPS $SPRING_EXTRA_PROPS $HOST_PROPS $PROV_PROPS $FILE_STORE_PROPS $REMOTE_DEBUG" diff --git a/opensync-gateway-static-docker/src/main/docker-opensync-gateway-and-mqtt/app/run.sh b/opensync-gateway-static-docker/src/main/docker-opensync-gateway-and-mqtt/app/run.sh index 6d1fbe2..a151f0f 100755 --- a/opensync-gateway-static-docker/src/main/docker-opensync-gateway-and-mqtt/app/run.sh +++ b/opensync-gateway-static-docker/src/main/docker-opensync-gateway-and-mqtt/app/run.sh @@ -174,7 +174,7 @@ RESTAPI_PROPS="$RESTAPI_PROPS -Dserver.port=4043" SPRING_EXTRA_PROPS=" --add-opens java.base/java.lang=ALL-UNNAMED" -JVM_EXTRA_PROPS=" ${JVM_MEM_OPTIONS:' '} " +JVM_EXTRA_PROPS=" ${JVM_MEM_OPTIONS:-' '} " export ALL_PROPS="$JVM_EXTRA_PROPS $PROFILES $SSL_PROPS $CLIENT_MQTT_SSL_PROPS $OVSDB_PROPS $MQTT_PROPS $LOGGING_PROPS $RESTAPI_PROPS $SPRING_EXTRA_PROPS " diff --git a/opensync-gateway-static-docker/src/main/docker/app/run.sh b/opensync-gateway-static-docker/src/main/docker/app/run.sh index e40e39c..b6cf8de 100755 --- a/opensync-gateway-static-docker/src/main/docker/app/run.sh +++ b/opensync-gateway-static-docker/src/main/docker/app/run.sh @@ -56,7 +56,7 @@ RESTAPI_PROPS+=" -Dserver.port=443" SPRING_EXTRA_PROPS=" --add-opens java.base/java.lang=ALL-UNNAMED" -JVM_EXTRA_PROPS=" ${JVM_MEM_OPTIONS:' '} " +JVM_EXTRA_PROPS=" ${JVM_MEM_OPTIONS:-' '} " export ALL_PROPS="$JVM_EXTRA_PROPS $PROFILES $SSL_PROPS $CLIENT_MQTT_SSL_PROPS $OVSDB_PROPS $MQTT_PROPS $LOGGING_PROPS $RESTAPI_PROPS $SPRING_EXTRA_PROPS"