Skip to content

Commit

Permalink
Add healthcheck
Browse files Browse the repository at this point in the history
This checks if status.php returns succesfully to determine if the
Nextcloud instance is health.

Signed-off-by: Sylvia van Os <[email protected]>
  • Loading branch information
TheLastProject committed Apr 13, 2022
1 parent 58273cd commit 7c89c0e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions Dockerfile-alpine.template
Original file line number Diff line number Diff line change
Expand Up @@ -129,5 +129,6 @@ RUN set -ex; \
COPY *.sh upgrade.exclude /
COPY config/* /usr/src/nextcloud/config/

HEALTHCHECK ["CMD --start-period=30s", "CMD", "curl", "--fail", "http://localhost/status.php"]
ENTRYPOINT ["/entrypoint.sh"]
CMD ["%%CMD%%"]
1 change: 1 addition & 0 deletions Dockerfile-debian.template
Original file line number Diff line number Diff line change
Expand Up @@ -147,5 +147,6 @@ RUN set -ex; \
COPY *.sh upgrade.exclude /
COPY config/* /usr/src/nextcloud/config/

HEALTHCHECK ["CMD --start-period=30s", "CMD", "curl", "--fail", "http://localhost/status.php"]
ENTRYPOINT ["/entrypoint.sh"]
CMD ["%%CMD%%"]

0 comments on commit 7c89c0e

Please sign in to comment.