Commit 30932a3b authored by Carl Osterwisch's avatar Carl Osterwisch Committed by Peter Parente

Revert to using supervisord to launch notebook

Used to relaunch notebook and collect logging data.
parent f2b7f38d
......@@ -20,6 +20,7 @@ RUN apt-get update && apt-get install -yq --no-install-recommends \
texlive-latex-extra \
texlive-fonts-extra \
texlive-fonts-recommended \
supervisor \
sudo \
&& apt-get clean
......@@ -53,4 +54,5 @@ CMD [ "start-notebook.sh" ]
# Add local files as late as possible to avoid cache busting
COPY start-notebook.sh /usr/local/bin/
COPY notebook.conf /etc/supervisor/conf.d/
COPY jupyter_notebook_config.py /etc/skel/.jupyter/
[program:notebook]
user=jovyan
umask=0002
directory=%(ENV_WORK)s
command=ipython notebook
autostart=true
autorestart=true
stdout_logfile=/var/log/supervisor/%(program_name)s.log
redirect_stderr=true
environment=HOME="/home/%(ENV_NB_USER)s",USER="%(ENV_NB_USER)s"
......@@ -12,8 +12,5 @@ if [ ! -z "$GRANT_SUDO" ]; then
echo "$NB_USER ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/notebook
fi
# Run Notebook server as $NB_USER
su -l $NB_USER << EOF
cd $WORK
jupyter notebook
EOF
# Start supervisord in foreground, PID1
exec supervisord -n -c /etc/supervisor/supervisord.conf
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment