安裝步驟docker
sudo apt-get install apt-transport-httpsubuntu
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 36A1D7869245C8950F966E92D8576A8BA88D21E9spa
sudo
sh -c
"echo deb https://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list"
rest
sudo apt-get updatecode
由於get.docker.io被牆so須要配置新的鏡像:sudo sh -c "echo deb http://mirror.yandex.ru/mirrors/docker/ docker main\ > /etc/apt/sources.list.d/docker.list" sudo apt-get update sudo apt-get install lxc-docker server
sudo apt-get -u -y dist-upgrade lxc-docker 執行docker更新ip
sudo usermod -aG docker username
ci
tips:cd /etc/apt vi sources.list 增長163的源 :get
deb http://mirrors.163.com/ubuntu/ precise main universe restricted multiverseit
deb-src http://mirrors.163.com/ubuntu/ precise main universe restricted multiverse
deb http://mirrors.163.com/ubuntu/ precise-security universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ precise-security universe main multiverse restricted
deb http://mirrors.163.com/ubuntu/ precise-updates universe main multiverse restricted
deb http://mirrors.163.com/ubuntu/ precise-proposed universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ precise-proposed universe main multiverse restricted
deb http://mirrors.163.com/ubuntu/ precise-backports universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ precise-backports universe main multiverse restricted
deb-src http://mirrors.163.com/ubuntu/ precise-updates universe main multiverse restricted