我可以在Ubuntu中使用curl -sSL https://get.docker.com/ | sh
安装docker。我阅读了该脚本,并查明docker
是否未安装上一个apt-get install docker-engine
,应该会遇到麻烦。
要改进脚本,如果docker
未安装apt-get
,我想终止它。
如何知道docker
安装的apt-get
是否正确?
Warning: the "docker" command appears to already exist on this system.
If you already have Docker installed, this script can cause trouble, which is
why we're displaying this warning and provide the opportunity to cancel the
installation.
If you installed the current Docker package using this script and are using it
again to update Docker, you can safely ignore this message.
You may press Ctrl+C now to abort this script.
答案 0 :(得分:3)
apt-get
主要用于安装和更新
列出您使用sudo dpkg -l | grep docker
我希望这就是你的意思。