Browse Source

Added configuration files.

Mike Birdgeneau 8 years ago
commit
72366daae8
4 changed files with 39 additions and 0 deletions
  1. 1 0
      .gitignore
  2. 8 0
      docker-compose.yml
  3. 23 0
      jupyterlab/Dockerfile
  4. 7 0
      jupyterlab/requirements.txt

+ 1 - 0
.gitignore

@@ -0,0 +1 @@
+data/*

+ 8 - 0
docker-compose.yml

@@ -0,0 +1,8 @@
+
+jupyterlab:
+  build: ./jupyterlab
+  ports:
+    - "8888:8888"
+  volumes:
+    - ./data:/opt/app/data
+  entrypoint: sh -c 'jupyter lab --ip=* --port=8888 --no-browser --notebook-dir=/opt/app/data'

+ 23 - 0
jupyterlab/Dockerfile

@@ -0,0 +1,23 @@
+FROM python:alpine
+
+# Install required packages
+RUN apk add --update alpine-sdk
+RUN apk add --update git
+RUN apk add --update nodejs
+
+# Install Jupyter
+RUN pip install jupyter
+RUN pip install ipywidgets
+RUN jupyter nbextension enable --py widgetsnbextension
+
+# Install JupyterLab
+RUN pip install jupyterlab && jupyter serverextension enable --py jupyterlab
+
+# Install Python Packages & Requirements (Done near end to avoid invalidating cache)
+ADD requirements.txt requirements.txt
+RUN apk add --update freetype-dev && apk add --update libpng musl-dev gcc pkgconfig zeromq-dev libc-dev libx11-dev
+RUN pip install -r requirements.txt
+
+# Expose Jupyter port & cmd
+EXPOSE 8888
+CMD ["jupyter lab"]

+ 7 - 0
jupyterlab/requirements.txt

@@ -0,0 +1,7 @@
+numpy
+matplotlib
+netCDF4
+jupyter
+pika
+folium
+pandas