From d1409f975cea64ebadd9da9077b9bc2245958cd2 Mon Sep 17 00:00:00 2001 From: Charles Costanzo Date: Tue, 3 May 2022 17:01:44 -0400 Subject: [PATCH 1/4] jupyter: adding netlify to dockerfile --- Dockerfile | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 01197e4..eb42416 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,16 @@ +FROM python:3.7-buster + +LABEL org.opencontainers.image.source https://github.com/cal-itp/data-infra + +RUN apt-get update \ + && apt-get install -y nodejs + FROM jupyter/datascience-notebook USER root RUN apt update \ - && apt install keychain + && apt install keychain \ + && curl -sL https://deb.nodesource.com/setup_14.x | bash - USER $NB_UID RUN curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-361.0.0-linux-x86_64.tar.gz \ @@ -13,6 +21,8 @@ ADD _jupyterhub/requirements.txt /app/requirements.txt RUN pip install -r /app/requirements.txt +RUN npm install -g --unsafe-perm=true --allow-root netlify-cli + RUN mkdir /opt/conda/share/jupyter/lab/settings/ COPY _jupyterhub/overrides.json /opt/conda/share/jupyter/lab/settings/overrides.json From 66cad37ffd5b425edab0ef39f1c5e382e0ff18d7 Mon Sep 17 00:00:00 2001 From: Charles Costanzo Date: Tue, 3 May 2022 17:19:33 -0400 Subject: [PATCH 2/4] jupyter: adding netlify to dockerfile, revised formatting --- Dockerfile | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index eb42416..33d28fe 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,16 +1,15 @@ FROM python:3.7-buster -LABEL org.opencontainers.image.source https://github.com/cal-itp/data-infra - -RUN apt-get update \ - && apt-get install -y nodejs +LABEL org.opencontainers.image.source https://github.com/cal-itp/calitp-py FROM jupyter/datascience-notebook USER root +RUN curl -sL https://deb.nodesource.com/setup_14.x | bash - RUN apt update \ && apt install keychain \ - && curl -sL https://deb.nodesource.com/setup_14.x | bash - + && apt-get update \ + && apt-get install -y nodejs USER $NB_UID RUN curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-361.0.0-linux-x86_64.tar.gz \ @@ -19,10 +18,10 @@ RUN curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cl ADD _jupyterhub/requirements.txt /app/requirements.txt -RUN pip install -r /app/requirements.txt - RUN npm install -g --unsafe-perm=true --allow-root netlify-cli +RUN pip install -r /app/requirements.txt + RUN mkdir /opt/conda/share/jupyter/lab/settings/ COPY _jupyterhub/overrides.json /opt/conda/share/jupyter/lab/settings/overrides.json From 4e8e3d8872202c08ba159eee78c692d1ffe97af2 Mon Sep 17 00:00:00 2001 From: Charles Costanzo Date: Wed, 4 May 2022 10:18:14 -0400 Subject: [PATCH 3/4] dockerfile: reformatted and reorganized based on feedback from Andrew --- Dockerfile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 33d28fe..492a94c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,7 @@ -FROM python:3.7-buster +FROM jupyter/datascience-notebook LABEL org.opencontainers.image.source https://github.com/cal-itp/calitp-py -FROM jupyter/datascience-notebook - USER root RUN curl -sL https://deb.nodesource.com/setup_14.x | bash - RUN apt update \ From 08295add943c05ffe7417d99e9592dcf4242b0a3 Mon Sep 17 00:00:00 2001 From: Charles Costanzo Date: Wed, 4 May 2022 11:31:48 -0400 Subject: [PATCH 4/4] dockerfile: removed extra apt update and removed get from nodejs install --- Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 492a94c..af13d4c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,8 +6,7 @@ USER root RUN curl -sL https://deb.nodesource.com/setup_14.x | bash - RUN apt update \ && apt install keychain \ - && apt-get update \ - && apt-get install -y nodejs + && apt install -y nodejs USER $NB_UID RUN curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-361.0.0-linux-x86_64.tar.gz \