Skip to content

Commit

Permalink
fix(jupyterhub): Updates image version so node gets updated
Browse files Browse the repository at this point in the history
  • Loading branch information
V committed Feb 26, 2025
1 parent 23ba03c commit cdc1604
Show file tree
Hide file tree
Showing 3 changed files with 359 additions and 16 deletions.
16 changes: 6 additions & 10 deletions images/jupyter-singleuser/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
FROM jupyter/datascience-notebook:python-3.11.6

FROM quay.io/jupyter/datascience-notebook:python-3.11.10
LABEL org.opencontainers.image.source=https://github.com/cal-itp/data-infra

USER root
RUN apt-get update
RUN apt-get install -y ca-certificates curl gnupg
RUN mkdir -p /etc/apt/keyrings
RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_22.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
RUN apt update \
&& apt-get install -y keychain nodejs git-lfs libspatialindex-dev graphviz libgraphviz-dev
# GitHub CLI https://github.com/cli/cli/blob/trunk/docs/install_linux.md

RUN curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg
RUN echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | tee /etc/apt/sources.list.d/github-cli.list > /dev/null
RUN apt update \
&& apt install -y gh
RUN apt-get install -y gdal-bin libgdal-dev # for rasterio
# create these ahead of time, then chown to to the notebook user
# create these ahead of time, then chown to the notebook user
ENV GCLOUD_HOME=/gcloud
ENV POETRY_HOME="/poetry"
RUN mkdir $POETRY_HOME \
Expand All @@ -29,13 +28,11 @@ USER $NB_UID
RUN curl -sSL https://install.python-poetry.org | python3 -
ENV PATH="$POETRY_HOME/bin:$PATH"
RUN npm install -g --unsafe-perm=true --allow-root netlify-cli
# RUN npm install -g --unsafe-perm=true --allow-root vega-cli # Can't get these to work
# RUN npm install -g --unsafe-perm=true --allow-root vega-lite
RUN npm install -g --unsafe-perm=true --allow-root sql-language-server
# gcloud CLI https://cloud.google.com/sdk/docs/install#deb
RUN cd $GCLOUD_HOME \
&& curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-cli-506.0.0-linux-x86_64.tar.gz \
&& tar -zxvf google-cloud-cli-506.0.0-linux-x86_64.tar.gz \
&& curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-cli-512.0.0-linux-x86_64.tar.gz \
&& tar -zxvf google-cloud-cli-512.0.0-linux-x86_64.tar.gz \
&& ./google-cloud-sdk/install.sh
ENV PATH="$GCLOUD_HOME/google-cloud-sdk/bin:$PATH"

Expand All @@ -46,7 +43,6 @@ RUN poetry config virtualenvs.create false
RUN cd /reqs && poetry install --with=shared_utils --with=portfolio
RUN cd /reqs && poetry show # print out the package versions for documentation
RUN poetry config virtualenvs.create true

ENV DBT_PROFILES_DIR=/home/jovyan/.dbt/
COPY ./overrides.json /opt/conda/share/jupyter/lab/settings/overrides.json
COPY ./dask_config.yml /opt/conda/etc/dask/dask_config.yml
Expand Down
Loading

0 comments on commit cdc1604

Please sign in to comment.