Skip to content

Commit a4e6f95

Browse files
authored
Fix TLS error when upgrading nvidia packages. (#1068)
* Fix TLS error when upgrading nvidia packages. We used to download the nvidia packages using apt over http. However this is not supported anymore causing a build failure. I found that `apt` was failing to connect over https to the NVIDIA download servers because of the `libgnutls.so` included in conda which was used in place of the default version when we updated the `LD_LIBRARY_PATH`. See the bug below for full context. http://b/197989446 * pin kornia and gensim
1 parent bc252a2 commit a4e6f95

File tree

2 files changed

+7
-12
lines changed

2 files changed

+7
-12
lines changed

Dockerfile

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,8 @@ ADD clean-layer.sh /tmp/clean-layer.sh
1111
ADD patches/nbconvert-extensions.tpl /opt/kaggle/nbconvert-extensions.tpl
1212
ADD patches/template_conf.json /opt/kaggle/conf.json
1313

14-
# This is necessary for apt to access HTTPS sources
15-
RUN apt-get update && \
16-
apt-get install apt-transport-https && \
17-
/tmp/clean-layer.sh
18-
19-
# Use a fixed apt-get repo to stop intermittent failures due to flaky httpredir connections,
20-
# as described by Lionel Chan at http://stackoverflow.com/a/37426929/5881346
14+
# Use a fixed apt-get repo to stop intermittent failures due to flaky httpredir connections,
15+
# as described by Lionel Chan at http://stackoverflow.com/a/37426929/5881346
2116
RUN sed -i "s/httpredir.debian.org/debian.uchicago.edu/" /etc/apt/sources.list && \
2217
apt-get update && \
2318
# Needed by vowpalwabbit & lightGBM (GPU build).
@@ -30,7 +25,7 @@ RUN sed -i "s/httpredir.debian.org/debian.uchicago.edu/" /etc/apt/sources.list &
3025
/tmp/clean-layer.sh
3126

3227
# Make sure the dynamic linker finds the right libstdc++
33-
ENV LD_LIBRARY_PATH=/opt/conda/lib
28+
ENV LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu:/opt/conda/lib
3429
# b/128333086: Set PROJ_LIB to points to the proj4 cartographic library.
3530
ENV PROJ_LIB=/opt/conda/share/proj
3631

@@ -67,7 +62,8 @@ RUN pip install tensorflow==${TENSORFLOW_VERSION} && \
6762

6863
RUN apt-get install -y libfreetype6-dev && \
6964
apt-get install -y libglib2.0-0 libxext6 libsm6 libxrender1 libfontconfig1 --fix-missing && \
70-
pip install gensim && \
65+
# b/198300835 kornia 4.1.0 is not compatible with our version of numpy.
66+
pip install gensim==4.0.1 && \
7167
pip install textblob && \
7268
pip install wordcloud && \
7369
pip install xgboost && \
@@ -304,7 +300,8 @@ RUN pip install bleach && \
304300
pip install notebook && \
305301
pip install papermill && \
306302
pip install olefile && \
307-
pip install kornia && \
303+
# b/198300835 kornia 0.5.10 is not compatible with our version of numpy.
304+
pip install kornia==0.5.8 && \
308305
pip install pandas_summary && \
309306
pip install pandocfilters && \
310307
pip install pexpect && \

gpu.Dockerfile

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ ADD clean-layer.sh /tmp/clean-layer.sh
99
COPY --from=nvidia /etc/apt/sources.list.d/cuda.list /etc/apt/sources.list.d/
1010
COPY --from=nvidia /etc/apt/sources.list.d/nvidia-ml.list /etc/apt/sources.list.d/
1111
COPY --from=nvidia /etc/apt/trusted.gpg /etc/apt/trusted.gpg.d/cuda.gpg
12-
# See b/142337634#comment28
13-
RUN sed -i 's/deb https:\/\/developer.download.nvidia.com/deb http:\/\/developer.download.nvidia.com/' /etc/apt/sources.list.d/*.list
1412

1513
ENV CUDA_MAJOR_VERSION=11
1614
ENV CUDA_MINOR_VERSION=0

0 commit comments

Comments
 (0)