Skip to content

Commit 5254a62

Browse files
authored
Merge pull request #11 from UBC-STAT/dockerfile-updates-2024W1
Update dockerfiles
2 parents 2d1578b + 67ed12b commit 5254a62

File tree

6 files changed

+417
-455
lines changed

6 files changed

+417
-455
lines changed

.github/workflows/publish_docker_images.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ on:
33
push:
44
paths:
55
- 'dockerfiles/r-stat-201/Dockerfile'
6+
- 'dockerfiles/r-stat-201/conda-linux-64.lock'
67
- 'dockerfiles/r-stat-201-grading/Dockerfile'
78
jobs:
89
build:

dockerfiles/r-stat-201-grading/Dockerfile

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,11 @@
11
# Copyright (c) UBC-STAT Development Team.
22
# Distributed under the terms of the Modified BSD License.
3-
# TODO: For testing purposes only, change to ubcstat/r-stat-201:latest
4-
FROM ubcstatit/r-stat-201-student:latest
3+
FROM ubcstat/r-stat-201:latest
54

65
LABEL maintainer="Brian Kim <[email protected]>"
76

87
# install rise slides extension, nbgrader, clean cache
9-
RUN mamba install --quiet --yes \
10-
'nbgrader=0.8.2' && \
11-
mamba clean --all -f -y
12-
13-
# re-upgrade jupyter-server (mamba downgrades it)
14-
RUN pip install --upgrade jupyter-server
8+
RUN pip install --no-cache nbgrader
159

1610
# Allow all shortcuts
1711
RUN rm -f /home/${NB_USER}/.jupyter/lab/user-settings/\@jupyterlab/shortcuts-extension/shortcuts.jupyterlab-settings

dockerfiles/r-stat-201/Dockerfile

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,15 @@ ENV PYDEVD_DISABLE_FILE_VALIDATION=1
3232
COPY conda-linux-64.lock /tmp/conda-linux-64.lock
3333

3434
# Install R packages from lock file.
35-
RUN mamba update --quiet --file /tmp/conda-linux-64.lock && \
36-
mamba clean --all -y -f && \
37-
fix-permissions "${CONDA_DIR}" && \
38-
fix-permissions "/home/${NB_USER}" && \
39-
Rscript -e "devtools::install_github('UBC-MDS/[email protected]')" && \
40-
Rscript -e "devtools::install_github('UBC-MDS/[email protected]')"
35+
RUN mamba update --quiet --file /tmp/conda-linux-64.lock \
36+
&& mamba clean --all -y -f \
37+
&& fix-permissions "${CONDA_DIR}" \
38+
&& fix-permissions "/home/${NB_USER}" \
39+
&& Rscript -e "devtools::install_github('UBC-MDS/[email protected]')" \
40+
&& Rscript -e "devtools::install_github('UBC-MDS/[email protected]')"
4141

4242
# Install pexpect from main branch to fix asyncio issue with jupyterlab_git
43-
RUN pip install --ignore-installed git+https://github.com/pexpect/pexpect.git@master
43+
RUN pip install --no-cache pexpect==4.9.0
4444

4545
# Disable the cell toolbar (which ignores metadata and students often accidentally click + delete grading cells)
4646
RUN jupyter labextension disable @jupyterlab/cell-toolbar-extension
@@ -57,6 +57,10 @@ COPY config/jupyter_server_config.py /home/${NB_USER}/.jupyter
5757
# Copy gitconfig that sets global default pull strategy to rebase
5858
COPY config/.gitconfig /home/${NB_USER}/
5959

60+
# install rise from fork wheel with fixed CSS
61+
COPY jupyterlab_rise-0.42.0-py3-none-any.whl ./
62+
RUN pip install wheel && pip install jupyterlab_rise-0.42.0-py3-none-any.whl && rm -f jupyterlab_rise-0.42.0-py3-none-any.whl
63+
6064
# Make sure everything in the home folder is owned by NB_USER for running docker image locally.
6165
USER root
6266
RUN chown -R ${NB_USER} /home/${NB_USER}

0 commit comments

Comments
 (0)