# 关闭docker sudo systemctl stop docker # 卸载旧版本: sudo apt-get purge docker-ce # 安装新版本 sudo apt update sudo apt-get -y install apt-transport-https ca-certificates curl software-properties-common curl -fsSL http://mirrors.aliyun.com/docker-ce/linux/ubuntu/gpg | sudo apt-key add - sudo add-apt-repository "deb [arch=amd64] http://mirrors.aliyun.com/docker-ce/linux/ubuntu $(lsb_release -cs) stable apt-cache madison docker-ce sudo apt install docker-ce=5:19.03.1~3-0~ubuntu-xenial systemctl start docker sudo systemctl start docker sudo systemctl enable docker sudo docker info # 安装nvidia-docker 看业务 sudo apt update sudo apt install nvidia-docker2