-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathDockerfile-v0p1
More file actions
34 lines (24 loc) · 1.09 KB
/
Copy pathDockerfile-v0p1
File metadata and controls
34 lines (24 loc) · 1.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
ARG BASE_CONTAINER=quay.io/jupyter/scipy-notebook:latest
FROM ${BASE_CONTAINER}
LABEL maintainer="arwhyte@umich.edu"
# Copy requirements.txt into the image
COPY ./requirements.txt /tmp/requirements.txt
# Install Python dependencies
RUN pip install --no-cache-dir -r /tmp/requirements.txt
# RUN python3 -m pip install --no-cache-dir -r /tmp/requirements.txt
# Install nbgrader here to make sure it's available before enabling
RUN pip install --no-cache-dir nbgrader
# Enable nbgrader and its extensions
RUN jupyter nbextension install --sys-prefix --py nbgrader \
&& jupyter nbextension enable --sys-prefix --py nbgrader \
&& jupyter serverextension enable --sys-prefix --py nbgrader
# Optional: Enable labextension support for nbgrader
RUN jupyter labextension install @jupyterlab/server-proxy --no-build
# Set working directory
WORKDIR /home/jovyan
# (Optional) Pre-create course directory
RUN mkdir -p /home/jovyan/nbgrader
# Copy optional custom config (if you use it)
COPY config/jupyter_notebook_config.py /etc/jupyter/
# Ensure correct permissions
RUN chown -R jovyan:users /etc/jupyter /home/jovyan