Skip to content

Instantly share code, notes, and snippets.

@padeoe
Last active May 22, 2019 03:03
Show Gist options
  • Save padeoe/06caa0dd5f2a7892e0941c1daed8f208 to your computer and use it in GitHub Desktop.
Save padeoe/06caa0dd5f2a7892e0941c1daed8f208 to your computer and use it in GitHub Desktop.
docker tensorflow-gpu-py3使用阿里云软件源
FROM tensorflow/tensorflow:latest-gpu-py3
# 修改apt源
RUN sed -i 's/archive.ubuntu.com/mirrors.aliyun.com/g;s/security.ubuntu.com/mirrors.aliyun.com/g' /etc/apt/sources.list
RUN apt-get update
# 修改pip源
RUN mkdir ~/.pip \
&& printf '%s\n%s\n%s\n' '[global]' 'trusted-host = mirrors.aliyun.com' \
'index-url = https://mirrors.aliyun.com/pypi/simple'>> ~/.pip/pip.conf
ENTRYPOINT ["bash"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment