changes to default config.
This commit is contained in:
parent
5e48f8e431
commit
3c78070359
1
.env
1
.env
@ -41,3 +41,4 @@ DOCKER_SPAWN_CMD=start-singleuser.sh
|
||||
# you can print the password for this hub-admin user with 'bash show_login.sh'
|
||||
USERNAME=hub-admin
|
||||
PASSWORD_LENGTH=6
|
||||
HUB_LOC=/home/pilosovm/hub
|
||||
|
@ -8,6 +8,12 @@ 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.*
|
||||
RUN apt-get update && \
|
||||
apt-get install -y --no-install-recommends \
|
||||
vim
|
||||
|
||||
RUN apt-get clean && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN pip install jupyterhub-hashauthenticator git+https://github.com/jupyterhub/dockerspawner.git@master
|
||||
|
||||
|
@ -44,7 +44,9 @@ class MyDockerSpawner(DockerSpawner):
|
||||
'mode': 'rw', # or ro for read-only
|
||||
}
|
||||
if self.user.name == 'hub-admin': # if admin, allow userlist access
|
||||
self.volumes[os.path.join(pwd,'userlist')] = { 'bind': '/home/jovyan/userlist',
|
||||
self.volumes['%s/userlist'%(os.environ['HUB_LOC'])] = { 'bind': '/home/jovyan/userlist',
|
||||
'mode': 'rw' }
|
||||
self.volumes['%s/jupyterhub_config.py'%(os.environ['HUB_LOC'])] = { 'bind': '/home/jovyan/jupyterhub_config.py',
|
||||
'mode': 'rw' }
|
||||
return super().start()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user