Skip to content

Commit

Permalink
NODE-2532 Dockerfile improvements (#3805)
Browse files Browse the repository at this point in the history
  • Loading branch information
xrtm000 authored Jan 30, 2023
1 parent 61b387e commit b67c4d3
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 2 deletions.
4 changes: 3 additions & 1 deletion docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM openjdk:11-jre-slim
FROM eclipse-temurin:11-jre

ENV WAVES_LOG_LEVEL=INFO
ENV WAVES_HEAP_SIZE=2g
Expand Down Expand Up @@ -47,5 +47,7 @@ VOLUME $WVLOG
VOLUME $WAVES_INSTALL_PATH/lib/plugins
WORKDIR $WVDATA

HEALTHCHECK CMD curl -f http://localhost:6869/node/status || exit 1

STOPSIGNAL SIGINT
ENTRYPOINT ["/usr/share/waves/bin/entrypoint.sh"]
5 changes: 5 additions & 0 deletions docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ docker run -v /docker/waves/waves-data:/var/lib/waves -v /docker/waves/waves-con

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.

4. You can override the default executable by using the following syntax:
```
docker run -it wavesplatform/wavesnode [command] [args]
```

### Environment variables

**You can run container with predefined environment variables:**
Expand Down
9 changes: 8 additions & 1 deletion docker/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,11 @@ JAVA_OPTS="-Dlogback.stdout.level=${WAVES_LOG_LEVEL}
-Dconfig.override_with_env_vars=true
${JAVA_OPTS}"

java $JAVA_OPTS -cp "${WAVES_INSTALL_PATH}/lib/plugins/*:$WAVES_INSTALL_PATH/lib/*" com.wavesplatform.Application "$WAVES_CONFIG"
if [ $# -eq 0 ]
then
ARGS="$WAVES_CONFIG"
else
ARGS=$@
fi

java $JAVA_OPTS -cp "${WAVES_INSTALL_PATH}/lib/plugins/*:$WAVES_INSTALL_PATH/lib/*" com.wavesplatform.Application $ARGS

0 comments on commit b67c4d3

Please sign in to comment.