Skip to content
Switch branches/tags
Go to file
Cannot retrieve contributors at this time
# Copyright (c) Jupyter Development Team.
# Distributed under the terms of the Modified BSD License.
# note!
# this dockerfile is not used in the build process---but it does provide
# an example of how to add users to the jupyterhub container so it's possible
# to use PAM authentication. Just be sure to change the password!
FROM jupyterhub/jupyterhub-onbuild:$JUPYTERHUB_VERSION
# Install dockerspawner, oauth, postgres
RUN /opt/conda/bin/conda install -yq psycopg2=2.7 && \
/opt/conda/bin/conda clean -tipsy && \
/opt/conda/bin/pip install --no-cache-dir \
oauthenticator==0.8.* \
# Copy TLS certificate and key
ENV SSL_CERT /srv/jupyterhub/secrets/jupyterhub.crt
ENV SSL_KEY /srv/jupyterhub/secrets/jupyterhub.key
COPY ./ssl/jupyterhub.crt $SSL_CERT
COPY ./ssl/jupyterhub.key $SSL_KEY
RUN chmod 700 /srv/jupyterhub/secrets && \
chmod 600 /srv/jupyterhub/secrets/*
COPY ./userlist /srv/jupyterhub/userlist
## I have added users in the following but there is a better way?!
RUN useradd -m administrator &&\
echo 'administrator:password' | chpasswd &&\
chown administrator /home/administrator &&\
### and so on