Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Extended from github.com/jupyter/docker-stacks
# See also http://blog.dscpl.com.au/2016/01/roundup-of-docker-issues-when-hosting.html

FROM python:3.9-slim-bullseye
FROM python:3.13-slim-bullseye

LABEL maintainer="Nick Greenfield <nick@onecodex.com>"

Expand Down Expand Up @@ -92,7 +92,7 @@ RUN wget https://ftp.samba.org/pub/cwrap/nss_wrapper-1.1.2.tar.gz && \
rm -rf nss_wrapper

# Copy `onecodex` installed fonts to local directory
RUN cp /usr/local/lib/python3.9/site-packages/onecodex/assets/fonts/*.otf /usr/local/share/fonts && fc-cache
RUN cp /usr/local/lib/python3.13/site-packages/onecodex/assets/fonts/*.otf /usr/local/share/fonts && fc-cache

# Configure container startup
EXPOSE 8888
Expand All @@ -103,8 +103,8 @@ CMD ["jupyter", "notebook"]

# Add assets
RUN mkdir /opt/onecodex/
COPY notebook/notebook.html /usr/local/lib/python3.9/site-packages/notebook/templates
COPY notebook/override.css /usr/local/lib/python3.9/site-packages/notebook/static/notebook/css
COPY notebook/notebook.html /usr/local/lib/python3.13/site-packages/notebook/templates
COPY notebook/override.css /usr/local/lib/python3.13/site-packages/notebook/static/notebook/css
COPY notebook/onecodex.js /home/$NB_USER/.jupyter/custom/
COPY notebook/one-codex-spinner.svg /home/$NB_USER/.jupyter/custom/
COPY notebook/override.css /home/$NB_USER/.jupyter/custom/custom.css
Expand All @@ -118,19 +118,19 @@ RUN jupyter nbextension install /usr/local/share/jupyter/customextensions/ \
RUN chmod +x /usr/local/bin/token_notebook.py

# Add patch to jupyter notebook for export to One Codex document portal
COPY notebook/notebook.patch /usr/local/lib/python3.9/site-packages/notebook
RUN cd /usr/local/lib/python3.9/site-packages/notebook \
COPY notebook/notebook.patch /usr/local/lib/python3.13/site-packages/notebook
RUN cd /usr/local/lib/python3.13/site-packages/notebook \
&& patch -p0 < notebook.patch

# Finally fix permissions on everything
# See https://github.com/jupyter/docker-stacks/issues/188
# RUN chown -R $NB_USER:root /home/$NB_USER && chmod -R u+rw,g+rw /home/$NB_USER
RUN chown -R $NB_USER:root /home/$NB_USER && find /home/$NB_USER -type d -exec chmod 775 {} \;

ENV PYTHONPATH "/home/jovyan/.local/lib/python3.9"
ENV PYTHONPATH "/home/jovyan/.local/lib/python3.13"

# Provide full access to the Python directory to allow for pip installs
RUN chown -R $NB_USER:root /usr/local/lib/python3.9
RUN chown -R $NB_USER:root /usr/local/lib/python3.13

# Switch to unprivileged user, jovyan
USER $NB_USER
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ openpyxl
xlrd
statsmodels
onecodex[all,reports]==0.19.1
taxonomy==0.10.0
taxonomy
widgetsnbextension