-
Notifications
You must be signed in to change notification settings - Fork 1
/
entrypoint.sh
executable file
·45 lines (36 loc) · 1.22 KB
/
entrypoint.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/bash
echo Preparing content for user home...
# create symlink to pharmbio template dir
if [ ! -e /home/jovyan/pharmbio ]; then
ln -s /pharmbio /home/jovyan/
fi
# create symlink to /scratch-shared
if [ ! -e /home/jovyan/scratch-shared ]; then
ln -s /scratch-shared /home/jovyan/
fi
# create symlink to /mnt
if [ ! -e /home/jovyan/mnt ]; then
ln -s /mnt /home/jovyan/
fi
# create symlink to /media
if [ ! -e /home/jovyan/media ]; then
ln -s /media /home/jovyan/
fi
# create symlink to /course-share
if [ ! -e /home/jovyan/course-share-pvc ]; then
ln -s /mnt/course-share-pvc /home/jovyan/
fi
# create symlink to tensorflow notebook tutorials dir
if [ ! -e /home/jovyan/tensorflow-tutorials ]; then
ln -s /tf/tensorflow-tutorials /home/jovyan/tensorflow-tutorials
fi
echo Copied tutorials and templates, starting notebook...
# Start jupyter service
jupyter notebook --notebook-dir=/home/jovyan \
--ip 0.0.0.0 \
--no-browser \
--allow-root \
--NotebookApp.password="$NOTEBOOK_PASSW_SHA1" \
--NotebookApp.token="$NOTEBOOK_TOKEN" \
--NotebookApp.allow_password_change=True \
--NotebookApp.default_url="/lab"