Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/drujensen/docker-jupyter
Docker image for fast.ai course
https://github.com/drujensen/docker-jupyter
Last synced: 10 days ago
JSON representation
Docker image for fast.ai course
- Host: GitHub
- URL: https://github.com/drujensen/docker-jupyter
- Owner: drujensen
- Created: 2017-10-15T14:52:26.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2020-05-16T21:21:44.000Z (over 4 years ago)
- Last Synced: 2024-10-25T01:35:56.424Z (about 2 months ago)
- Language: Shell
- Size: 9.17 MB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Jupyter using Docker
## Start Server
```bash
dc up -d
```## Find Jupyter URL
```bash
dc logs
```Look for URL and open in browser
# Jupyter using Docker with GPU
## Setup
Install docker for your environment:
https://www.docker.com/community-edition#/downloadInstall AWS CLI and configure credentials:
[Install Link](http://docs.aws.amazon.com/cli/latest/userguide/installing.html)
[Configure Link](http://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html)## Alias docker commands in your .bashrc
```bash
alias dm="docker-machine"
alias dc="docker-compose"
```## Docker Machine commands
### Create
```bash
dm create --driver=amazonec2 --amazonec2-region us-west-2 --amazonec2-instance-type p2.xlarge jupyter
```Or follow these instructions to install docker on your own instance:
https://docs.docker.com/engine/install/ubuntu/
### List
```bash
dm ls
```### Start
```bash
dm start jupyter
```### Stop
```bash
dm stop jupyter
```### Remove
```bash
dm rm jupyter
```### SSH
```bash
dm ssh jupyter
```### SCP
```bash
dm scp [machine:][path] machine:][path]
```## NVidia Driver
### Install CUDA on host server
SSH into the host
```bash
dm ssh jupyter
```On the host server:
```bash
distribution=$(. /etc/os-release;echo $ID$VERSION_ID)
curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | sudo apt-key add -
curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | sudo tee /etc/apt/sources.list.d/nvidia-docker.listsudo apt-get update && sudo apt-get install -y nvidia-container-toolkit
sudo systemctl restart docker
```Verify Cuda is properly setup and GPU is working
```bash
sudo docker run --gpus all nvidia/cuda:10.0-base nvidia-smi
```Run Jupyter using docker:
```
sudo docker run --rm -d --gpus all --name jupyter -p 8888:8888 -v /home/ubuntu/notebooks:/home/jovyan/work drujensen/jupyter:latest
```Watch logs and grab URL to open
```
sudo docker logs jupyter
```