add watchtower support and fix CMD in Dockerfile

This commit is contained in:
Marcel 2020-03-22 14:56:14 +00:00
parent f80ea7bd39
commit 48b5977551
2 changed files with 10 additions and 3 deletions

View File

@ -7,4 +7,4 @@ COPY ./assets/common /opt/assets/common
COPY ./assets/world /opt/assets/world
WORKDIR /opt
CMD ["RUST_LOG=info,common=debug,common::net=info RUST_BACKTRACE=1 /opt/veloren-server-cli"]
CMD [ "sh", "-c", "RUST_LOG=info,common=debug,common::net=info RUST_BACKTRACE=1 /opt/veloren-server-cli" ]

View File

@ -1,4 +1,4 @@
version: "3.7"
version: "3.5"
services:
game-server:
@ -11,7 +11,14 @@ services:
update_config:
parallelism: 2
delay: 10s
order: stop-first
order: stop-first
failure_action: rollback
restart_policy:
condition: on-failure
watchtower:
image: containrrr/watchtower
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /root/.docker/config.json:/config.json
command: --interval 30 --cleanup