Skip to content

Commit ab5d706

Browse files
committed
Add template for project setup: a Dockerfile template launching a Jupyter notebook server and a Makefile for building
1 parent fc57fa6 commit ab5d706

File tree

4 files changed

+32
-0
lines changed

4 files changed

+32
-0
lines changed

Dockerfile

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
WORKDIR /main
2+
3+
# install requirements
4+
COPY requirements-docker.txt .

Makefile

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
## variables
2+
image_name = docker_notebook_template
3+
container_workdir = /main
4+
tag = latest
5+
port = 1112
6+
7+
## build the container
8+
build:
9+
docker build -t $(image_name):$(tag) .
10+
11+
## run container on port
12+
run:
13+
docker run --rm -ti -v $(shell pwd):$(container_workdir) -p $(port):8888 $(image_name):$(tag)
14+
15+
# build and run
16+
all: build run

requirements-docker.txt

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
prompt-toolkit==2.0.1
2+
jupyter
3+
jupyter-client==5.2.3
4+
jupyter-console==5.2.0
5+
jupyter-contrib-core==0.3.3
6+
jupyter-contrib-nbextensions==0.5.0
7+
jupyter-core==4.4.0
8+
jupyter-highlight-selected-word==0.1.1
9+
jupyter-latex-envs==1.4.4
10+
jupyter-nbextensions-configurator==0.4.0
11+
jupyterlab

requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
pandas==0.22.0

0 commit comments

Comments
 (0)