From f8815656758dc9f55e1a439c42b1888974dd57ef Mon Sep 17 00:00:00 2001 From: yacchin1205 <968739+yacchin1205@users.noreply.github.com> Date: Fri, 22 Apr 2022 02:10:24 +0000 Subject: [PATCH] Fix healthcheck for JupyterHub --- base-notebook/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base-notebook/Dockerfile b/base-notebook/Dockerfile index 72d58605..944a7db6 100644 --- a/base-notebook/Dockerfile +++ b/base-notebook/Dockerfile @@ -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}