add healthcheck for whiteboard

Signed-off-by: Simon L. <szaimen@e.mail.de>
This commit is contained in:
Simon L. 2024-12-03 11:56:35 +01:00
parent 9360256f7d
commit c908defda6
3 changed files with 16 additions and 0 deletions

View file

@ -1,4 +1,5 @@
# syntax=docker/dockerfile:latest
# Probably from this file: https://github.com/nextcloud/whiteboard/blob/main/Dockerfile
FROM ghcr.io/nextcloud-releases/whiteboard:v1.0.4
USER root
@ -8,6 +9,9 @@ RUN set -ex; \
USER 65534
COPY --chmod=775 start.sh /start.sh
COPY --chmod=775 healthcheck.sh /healthcheck.sh
HEALTHCHECK CMD /healthcheck.sh
ENTRYPOINT ["/start.sh"]

View file

@ -0,0 +1,4 @@
#!/bin/bash
nc -z "$REDIS_HOST" 6379 || exit 0
nc -z 127.0.0.1 3002 || exit 1

View file

@ -874,6 +874,14 @@
"image": "nextcloud/aio-whiteboard",
"user": "65534",
"init": true,
"healthcheck": {
"start_period": "0s",
"test": "/healthcheck.sh",
"interval": "30s",
"timeout": "30s",
"start_interval": "5s",
"retries": 3
},
"expose": [
"3002"
],