From 170e3cddddfeed21f91a2eb9a71048d8afdcc4f8 Mon Sep 17 00:00:00 2001 From: Tommy Date: Wed, 7 Sep 2022 19:36:18 -0400 Subject: [PATCH] Add Healthcheck Signed-off-by: Tommy --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index 04339ab..b11bb66 100644 --- a/Dockerfile +++ b/Dockerfile @@ -63,6 +63,7 @@ RUN apk -U upgrade \ zlib \ tzdata \ xmlsec \ + curl \ && adduser -g ${GID} -u ${UID} --disabled-password --gecos "" synapse \ && rm -rf /var/cache/apk/* @@ -80,3 +81,6 @@ VOLUME /data EXPOSE 8008/tcp 8009/tcp 8448/tcp ENTRYPOINT ["python3", "start.py"] + +HEALTHCHECK --start-period=5s --interval=15s --timeout=5s \ + CMD curl -fSs http://localhost:8008/health || exit 1