1.Установка Docker Для установки Docker требуется 64-х разрядная операционная система и ядро версии 3.10 и выше.
1 |
# uname -r |
1 |
3.10.0-327.36.2.el7.x86_64 |
1 |
# cat /etc/redhat-release |
1 |
CentOS Linux release 7.2.1511 (Core) |
Обновим пакеты
1 |
# yum update |
Добавляем репозитарий Docker
1 |
# tee /etc/yum.repos.d/docker.repo <<-'EOF' |
1 2 3 4 5 6 7 |
[dockerrepo] name=Docker Repository baseurl=https://yum.dockerproject.org/repo/main/centos/7/ enabled=1 gpgcheck=1 gpgkey=https://yum.dockerproject.org/gpg EOF |
Непосредственно установим Docker
1 |
# yum install docker-engine |
Добавление Docker в автозагрузку
1 |
# systemctl enable docker |
Запуск Docker
1 |
# systemctl start docker |
Проверка состояния Docker
1 |
# systemctl status docker |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
● docker.service - Docker Application Container Engine Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled) Active: active (running) since Thu 2016-10-20 23:10:36 EEST; 6s ago Docs: https://docs.docker.com Main PID: 1366 (dockerd) Memory: 18.5M CGroup: /system.slice/docker.service ├─1366 /usr/bin/dockerd └─1370 docker-containerd -l unix:///var/run/docker/libcontainerd/docker-containerd.sock --shim docker-containerd-shim --metrics-interval=0 --st... Oct 20 23:10:35 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:35.240268299+03:00" level=warning msg="mountpoint for pids not found" Oct 20 23:10:35 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:35.240569857+03:00" level=info msg="Loading containers: start." Oct 20 23:10:35 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:35.530700626+03:00" level=warning msg="Running modprobe bridge br_netfilter f... Oct 20 23:10:35 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:35.718801030+03:00" level=info msg="Firewalld running: false" Oct 20 23:10:36 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:36.303073111+03:00" level=info msg="Default bridge (docker0) is assig...address" Oct 20 23:10:36 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:36.430876877+03:00" level=info msg="Loading containers: done." Oct 20 23:10:36 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:36.431063740+03:00" level=info msg="Daemon has completed initialization" Oct 20 23:10:36 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:36.431087154+03:00" level=info msg="Docker daemon" commit=bb80604 gra...n=1.12.2 Oct 20 23:10:36 centos71.kamaok.org.ua dockerd[1366]: time="2016-10-20T23:10:36.457437494+03:00" level=info msg="API listen on /var/run/docker.sock" Oct 20 23:10:36 centos71.kamaok.org.ua systemd[1]: Started Docker Application Container Engine. Hint: Some lines were ellipsized, use -l to show in full. |
Просмотр Docker компонентов и их версий
1 |
# docker version |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
Client: Version: 1.12.2 API version: 1.24 Go version: go1.6.3 Git commit: bb80604 Built: OS/Arch: linux/amd64 Server: Version: 1.12.2 API version: 1.24 Go version: go1.6.3 Git commit: bb80604 Built: OS/Arch: linux/amd64 |
Просмотр размещения […]