From 6414b2098ebb7bf8a545513d234d576061ee52ed Mon Sep 17 00:00:00 2001 From: Jerry Ding Date: Thu, 26 May 2022 17:49:50 -0700 Subject: [PATCH] Place Jupyterhub configuration in a fixed known location Previously we relied on the config file being in the same working directory as the Jupyterhub command was invoked from, which is brittle. This places the config in a known location and explicitly passes the path when starting Jupyterhub. --- docker/Dockerfile | 2 +- docker/jupyterhub.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index b36fc9a..23c1026 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -67,7 +67,7 @@ RUN pip install /tmp/dataprocspawner/ COPY static/templates/ /etc/jupyterhub/templates/ COPY static/mdc/ /usr/local/share/jupyterhub/static/mdc/ -COPY docker/jupyterhub_config.py . +COPY docker/jupyterhub_config.py /etc/jupyterhub/jupyterhub_config.py EXPOSE 8080 diff --git a/docker/jupyterhub.sh b/docker/jupyterhub.sh index c2df45d..b179cbd 100644 --- a/docker/jupyterhub.sh +++ b/docker/jupyterhub.sh @@ -271,4 +271,4 @@ function set-default-name-pattern() { append-to-jupyterhub-config # Starts JupyterHub. -jupyterhub +jupyterhub -f /etc/jupyterhub/jupyterhub_config.py