Nethence Newdoc Olddoc Lab Your IP BBDock  

Installing Docker on various systems


Setup docker using the official docker repo, not EPEL.

Check that docker is not installed already,

ls -al /etc/yum.repos.d/
rpm -qa | grep -i docker

Install Docker Engine Community Edition on CentOS,

yum install -y yum-utils device-mapper-persistent-data lvm2
yum-config-manager \
    --add-repo \
yum makecache fast
yum install -y docker-ce
systemctl list-unit-files | grep docker
systemctl status docker
systemctl start docker
systemctl enable docker
usermod -a -G docker ceph


apt update
apt install
systemctl list-unit-files | grep docker
systemctl enable docker.socket
systemctl enable docker.service
usermod -a -G docker ceph

Re-locate the docker files

    systemctl stop docker.service
    systemctl stop docker.socket

mv /var/lib/docker/ /data/docker/
ln -s ../../data/docker /var/lib/docker

    systemctl start docker.socket
    systemctl start docker.service

Ready to go

Check that everything works, as user,

docker ps

Home | GitHub | Donate | Contact