• 安装docker:
    • curl -sSL http://acs-public-mirror.oss-cn-hangzhou.aliyuncs.com/docker-engine/internet | sh –
  • 配置镜像
    • 新建/etc/docker/daemon.json 文件,填入以下内容:

{
“registry-mirrors”: [“https://pdx8q6rz.mirror.aliyuncs.com”]
}

说明,镜像地址可以从阿里开发者查看https://dev.aliyun.com/search.html

nvidia-docker:

# Install nvidia-docker and nvidia-docker-plugin
wget -P /tmp https://github.com/NVIDIA/nvidia-docker/releases/download/v1.0.1/nvidia-docker_1.0.1-1_amd64.deb
sudo dpkg -i /tmp/nvidia-docker*.deb && rm /tmp/nvidia-docker*.deb

# Test nvidia-smi
nvidia-docker run --rm nvidia/cuda nvidia-smi

 

  • 重启

sudo systemctl daemon-reload

sudo systemctl restart docker

  • 测试: docker pull wordpress

ref: http://www.jianshu.com/p/525211f31830