diff --git a/jupyter/README.md b/jupyter/README.md index 52559ab..2aa8a0c 100644 --- a/jupyter/README.md +++ b/jupyter/README.md @@ -11,15 +11,44 @@ notebook: ports: - "8888:8888" volumes: - - ./work:/home/jovyan/work + - ./data:/home/jovyan restart: unless-stopped ``` ## up and running +```bash +$ cd ~/fig/jupyter/ +$ mkdir -p data/.jupyter +$ chown -R 1000:100 data +$ docker-compose up -d +$ curl http://127.0.0.1:8888 ``` -cd ~/fig/jupyter/ -mkdir work -chown 1000:1000 work -docker-compose up -d + +## reset password + +```bash +$ docker-compose exec notebook bash +>>> jupyter notebook password +Enter password: ****** +Verify password: ****** +[NotebookPasswordApp] Wrote hashed password to /home/jovyan/.jupyter/jupyter_notebook_config.json +$ docker-compose restart ``` + +## without password + +File: ./data/.jupyter/jupyter_notebook_config.json + +```json +{ + "NotebookApp": { + "token": "", + "password": "" + } +} +``` + +## nginx config + +- diff --git a/jupyter/docker-compose.yml b/jupyter/docker-compose.yml index ca6ecce..420ab93 100644 --- a/jupyter/docker-compose.yml +++ b/jupyter/docker-compose.yml @@ -3,9 +3,5 @@ notebook: ports: - "8888:8888" volumes: - - ./work:/home/jovyan/work -# - ./notebook.pem:/home/jovyan/.local/share/jupyter/notebook.pem -# environment: -# - PASSWORD=YOURPASS -# - USE_HTTPS=yes + - ./data:/home/jovyan restart: unless-stopped