Skip to content

Commit b67c4d3

Browse files
authored
NODE-2532 Dockerfile improvements (#3805)
1 parent 61b387e commit b67c4d3

File tree

3 files changed

+16
-2
lines changed

3 files changed

+16
-2
lines changed

docker/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM openjdk:11-jre-slim
1+
FROM eclipse-temurin:11-jre
22

33
ENV WAVES_LOG_LEVEL=INFO
44
ENV WAVES_HEAP_SIZE=2g
@@ -47,5 +47,7 @@ VOLUME $WVLOG
4747
VOLUME $WAVES_INSTALL_PATH/lib/plugins
4848
WORKDIR $WVDATA
4949

50+
HEALTHCHECK CMD curl -f http://localhost:6869/node/status || exit 1
51+
5052
STOPSIGNAL SIGINT
5153
ENTRYPOINT ["/usr/share/waves/bin/entrypoint.sh"]

docker/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,11 @@ docker run -v /docker/waves/waves-data:/var/lib/waves -v /docker/waves/waves-con
4040

4141
3. By default, `/etc/waves/waves.conf` config includes `/etc/waves/local.conf`. Custom `/etc/waves/local.conf` can be used to override default config entries. Custom `/etc/waves/waves.conf` can be used to override or the whole configuration. For additional information about Docker volumes mapping please refer to `Managing data` item.
4242

43+
4. You can override the default executable by using the following syntax:
44+
```
45+
docker run -it wavesplatform/wavesnode [command] [args]
46+
```
47+
4348
### Environment variables
4449

4550
**You can run container with predefined environment variables:**

docker/entrypoint.sh

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,11 @@ JAVA_OPTS="-Dlogback.stdout.level=${WAVES_LOG_LEVEL}
1919
-Dconfig.override_with_env_vars=true
2020
${JAVA_OPTS}"
2121

22-
java $JAVA_OPTS -cp "${WAVES_INSTALL_PATH}/lib/plugins/*:$WAVES_INSTALL_PATH/lib/*" com.wavesplatform.Application "$WAVES_CONFIG"
22+
if [ $# -eq 0 ]
23+
then
24+
ARGS="$WAVES_CONFIG"
25+
else
26+
ARGS=$@
27+
fi
28+
29+
java $JAVA_OPTS -cp "${WAVES_INSTALL_PATH}/lib/plugins/*:$WAVES_INSTALL_PATH/lib/*" com.wavesplatform.Application $ARGS

0 commit comments

Comments
 (0)