@@ -28,8 +28,10 @@ RUN apt-get update && apt-get install -y \
28
28
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
29
29
30
30
# Setup CONDA (https://hub.docker.com/r/continuumio/miniconda3/~/dockerfile/)
31
- ENV MINICONDA_VERSION latest
32
- RUN curl -k -o /miniconda.sh https://repo.continuum.io/miniconda/Miniconda3-$MINICONDA_VERSION-Linux-x86_64.sh && \
31
+ ENV MINICONDA_VERSION py38_4.8.2
32
+ ENV MINICONDA_SHA256 5bbb193fd201ebe25f4aeb3c58ba83feced6a25982ef4afa86d5506c3656c142
33
+ RUN curl -k -o /miniconda.sh https://repo.anaconda.com/miniconda/Miniconda3-$MINICONDA_VERSION-Linux-x86_64.sh && \
34
+ echo $MINICONDA_SHA256 /miniconda.sh | sha256sum --check && \
33
35
/bin/bash /miniconda.sh -b -p /opt/conda && \
34
36
rm /miniconda.sh && \
35
37
/opt/conda/bin/conda clean -afy && \
@@ -38,23 +40,17 @@ RUN curl -k -o /miniconda.sh https://repo.continuum.io/miniconda/Miniconda3-$MIN
38
40
echo "conda activate base" >> /etc/profile && \
39
41
find /opt/conda/ -follow -type f -name '*.a' -delete && \
40
42
find /opt/conda/ -follow -type f -name '*.js.map' -delete && \
41
- /opt/conda/bin/conda update - n base conda && \
43
+ /opt/conda/bin/conda install -y -c conda-forge - n base mamba && \
42
44
/opt/conda/bin/conda clean -afy
43
45
44
- # Copy over environment definition
46
+ ENV PATH /opt/conda/bin:$PATH
47
+
45
48
COPY environment.yml /tmp/environment.yml
46
- RUN /opt/conda/bin/conda config \
47
- --set always_yes yes \
48
- --set changeps1 no \
49
- --set show_channel_urls True \
49
+ RUN mamba env update \
50
+ -n base \
51
+ -f /tmp/environment.yml \
50
52
&& \
51
- /opt/conda/bin/conda config \
52
- --add create_default_packages pip \
53
- --add channels axiom-data-science \
54
- --add channels conda-forge \
55
- && \
56
- /opt/conda/bin/conda env update -n base --file /tmp/environment.yml && \
57
- /opt/conda/bin/conda clean -afy
53
+ mamba clean -afy
58
54
59
55
ENV PATH /opt/conda/bin:$PATH
60
56
0 commit comments