23 lines
487 B
Bash
Executable File
23 lines
487 B
Bash
Executable File
#!/bin/sh
|
|
|
|
name=$([[ $1 ]] && echo $1 || echo "jupyter")
|
|
mount=$([[ $2 ]] && echo $2 || echo "$HOME/projects/")
|
|
|
|
read -p "Port to use for the jupyter notebook (replace 8888 with that) (default = 8888) " port
|
|
|
|
if [[ $port == "" ]]; then
|
|
port=8888
|
|
fi
|
|
|
|
echo "
|
|
=> Mounting folder to /home/jovyan/work (in container)
|
|
=> Starting container
|
|
"
|
|
|
|
docker run \
|
|
-v $mount:/home/jovyan/work \
|
|
--name $name \
|
|
-p $port:8888 \
|
|
-e DOCKER_STACKS_JUPYTER_CMD=notebook \
|
|
quay.io/jupyter/base-notebook
|