mirror of
https://github.com/Steffo99/sophon.git
synced 2024-12-22 06:44:21 +00:00
🧹 Move the jupyter Dockerfile here
This commit is contained in:
parent
f4e0fdccb8
commit
d99a4eb501
2 changed files with 39 additions and 0 deletions
12
.github/workflows/build-docker-images.yml
vendored
12
.github/workflows/build-docker-images.yml
vendored
|
@ -39,3 +39,15 @@ jobs:
|
|||
run: docker build ./proxy --tag ghcr.io/steffo99/sophon-proxy:latest
|
||||
- name: "Upload the container to GitHub Containers"
|
||||
run: docker push ghcr.io/steffo99/sophon-proxy:latest
|
||||
build-jupyter:
|
||||
name: "Build jupyter image"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: "Checkout repository"
|
||||
uses: actions/checkout@v2
|
||||
- name: "Login to GitHub Containers"
|
||||
run: echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u Steffo99 --password-stdin
|
||||
- name: "Build the docker container `ghcr.io/steffo99/sophon-jupyter:latest`"
|
||||
run: docker build ./jupyter --tag ghcr.io/steffo99/sophon-jupyter:latest
|
||||
- name: "Upload the container to GitHub Containers"
|
||||
run: docker push ghcr.io/steffo99/sophon-jupyter:latest
|
||||
|
|
27
jupyter/Dockerfile
Normal file
27
jupyter/Dockerfile
Normal file
|
@ -0,0 +1,27 @@
|
|||
# Modified jupyter/scipy-notebook for better integration with Sophon
|
||||
|
||||
# Override the default "jovyan" user
|
||||
ARG NB_USER="sophon"
|
||||
|
||||
# Set the base image of the notebook
|
||||
FROM jupyter/scipy-notebook
|
||||
|
||||
# Image labels
|
||||
LABEL maintainer="Stefano Pigozzi <me@steffo.eu>"
|
||||
|
||||
# As the default user...
|
||||
USER ${NB_UID}
|
||||
WORKDIR "${HOME}"
|
||||
|
||||
# Install the JupyterLab Sophon theme
|
||||
RUN jupyter labextension install "jupyterlab_theme_sophon"
|
||||
# Enable the JupyterLab Sophon theme
|
||||
RUN jupyter labextension enable "jupyter_theme_sophon"
|
||||
# Set the JupyterLab Sophon theme as default
|
||||
RUN mkdir -p '.jupyter/lab/user-settings/@jupyterlab/apputils-extension/'
|
||||
RUN echo '{"theme": "JupyterLab Sophon"}' > ".jupyter/lab/user-settings/@jupyterlab/apputils-extension/themes.jupyterlab-settings"
|
||||
|
||||
# Set useful envvars for Sophon notebooks
|
||||
ENV JUPYTER_ENABLE_LAB=yes
|
||||
ENV RESTARTABLE=yes
|
||||
ENV GRANT_SUDO=yes
|
Loading…
Reference in a new issue