Merge pull request #1687 from yacchin1205/fix/healthcheck-for-jupyterhub

Fix HEALTHCHECK command for JupyterHub
This commit is contained in:
Ayaz Salikhov
2022-04-23 13:44:28 +01:00
committed by GitHub

View File

@@ -175,7 +175,7 @@ RUN sed -re "s/c.ServerApp/c.NotebookApp/g" \
# This healtcheck works well for `lab`, `notebook`, `nbclassic`, `server` and `retro` jupyter commands
# https://github.com/jupyter/docker-stacks/issues/915#issuecomment-1068528799
HEALTHCHECK --interval=15s --timeout=3s --start-period=5s --retries=3 \
CMD wget -O- --no-verbose --tries=1 http://localhost:8888/api || exit 1
CMD wget -O- --no-verbose --tries=1 http://localhost:8888${JUPYTERHUB_SERVICE_PREFIX:-/}api || exit 1
# Switch back to jovyan to avoid accidental container runs as root
USER ${NB_UID}