-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade binder submodule, use fully pinned environment definition #4
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,13 +2,13 @@ FROM jupyter/base-notebook | |
|
||
USER root | ||
RUN apt-get update \ | ||
&& apt-get install -yq --no-install-recommends dnsutils libfuse-dev nano fuse vim git build-essential openssh-client \ | ||
&& apt-get install -yq --no-install-recommends dnsutils libfuse-dev nano fuse vim git build-essential openssh-client \ | ||
&& apt-get clean \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
USER $NB_USER | ||
RUN conda config --set ssl_verify no | ||
COPY binder/environment.yml /tmp/environment.yml | ||
COPY binder/environment-pinned-linux.yml /tmp/environment.yml | ||
|
||
ARG tag | ||
RUN echo "image tag is $tag" | ||
|
@@ -17,29 +17,22 @@ ENV IMAGETAG=$tag | |
RUN echo " ---------------------------------- " | ||
RUN echo "env variable IMAGETAG is ${IMAGETAG}" | ||
|
||
# create default scientific Python environment | ||
|
||
|
||
|
||
# create default scientific Python environment | ||
|
||
RUN conda config --add channels pyviz/label/dev | ||
RUN conda config --add channels bokeh/label/dev | ||
RUN conda config --add channels intake | ||
RUN conda config --add channels bioconda | ||
RUN conda config --add channels conda-forge | ||
#RUN conda update --yes conda | ||
RUN conda config --set channel_priority strict | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is also an important change, ensures packages are pulled from conda-forge instead of defaults wherever possible, which results in a more consistent environment. |
||
RUN conda update --yes conda | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I saw this had been commented out, but there have been some improvements in recent conda versions, so thought maybe best to run it? |
||
|
||
RUN conda env update --file /tmp/environment.yml --prune | ||
RUN conda env update --file /tmp/environment.yml | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We are installing this into the base environment, is that right? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I.e., I think the environment name from within the environment file will be ignored. |
||
RUN conda clean -afy | ||
# && find /opt/conda/ -follow -type f -name '*.a' -delete \ | ||
# && find /opt/conda/ -follow -type f -name '*.pyc' -delete \ | ||
# && find /opt/conda/ -follow -type f -name '*.js.map' -delete | ||
# | ||
|
||
|
||
RUN /opt/conda/bin/pip install nbserverproxy | ||
RUN conda install nb_conda | ||
|
||
RUN conda install nb_conda | ||
|
||
RUN jupyter labextension install @jupyter-widgets/jupyterlab-manager | ||
RUN jupyter labextension install @jupyterlab/hub-extension | ||
|
@@ -49,9 +42,6 @@ RUN jupyter labextension install dask-labextension | |
|
||
RUN jupyter serverextension enable --py nbserverproxy --sys-prefix | ||
|
||
|
||
|
||
|
||
USER root | ||
COPY prepare.sh /usr/bin/prepare.sh | ||
RUN chmod +x /usr/bin/prepare.sh | ||
|
@@ -76,4 +66,3 @@ ENV PATH /opt/conda/envs/$(head -1 /tmp/environment.yml | cut -d' ' -f2)/bin:$PA | |
|
||
ENTRYPOINT ["tini", "--", "/usr/bin/prepare.sh"] | ||
CMD ["start.sh jupyter lab"] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the main change, using the fully pinned environment file.