diff --git a/images/base-notebook/Dockerfile b/images/base-notebook/Dockerfile index fd7a265f4c..03c6eed9d9 100644 --- a/images/base-notebook/Dockerfile +++ b/images/base-notebook/Dockerfile @@ -55,17 +55,13 @@ EXPOSE $JUPYTER_PORT CMD ["start-notebook.py"] # Copy local files as late as possible to avoid cache busting -COPY start-notebook.py start-singleuser.py /usr/local/bin/ +COPY start-notebook.py start-notebook.sh start-singleuser.py start-singleuser.sh /usr/local/bin/ COPY jupyter_server_config.py docker_healthcheck.py /etc/jupyter/ # Fix permissions on /etc/jupyter as root USER root RUN fix-permissions /etc/jupyter/ -# Symlink scripts to their older .sh variants for backwards compatibility -RUN ln -s /usr/local/bin/start-notebook.py /usr/local/bin/start-notebook.sh && \ - ln -s /usr/local/bin/start-singleuser.py /usr/local/bin/start-singleuser.sh - # HEALTHCHECK documentation: https://docs.docker.com/engine/reference/builder/#healthcheck # This healtcheck works well for `lab`, `notebook`, `nbclassic`, `server` and `retro` jupyter commands # https://github.com/jupyter/docker-stacks/issues/915#issuecomment-1068528799 diff --git a/images/base-notebook/start-notebook.sh b/images/base-notebook/start-notebook.sh new file mode 100755 index 0000000000..c47ebba334 --- /dev/null +++ b/images/base-notebook/start-notebook.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# Shim to emit warning and call start-notebook.py +echo "WARNING: Use start-notebook.py instead" + +exec /usr/local/bin/start-notebook.py "$@" diff --git a/images/base-notebook/start-singleuser.sh b/images/base-notebook/start-singleuser.sh new file mode 100755 index 0000000000..ecf0e068ae --- /dev/null +++ b/images/base-notebook/start-singleuser.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# Shim to emit warning and call start-singleuser.py +echo "WARNING: Use start-singleuser.py instead" + +exec /usr/local/bin/start-singleuser.py "$@"