Unable to install docker-ce-17.06.0.ce-1.el7.centos – container-selinux issue
Recently i was trying to install Docker Community edition RPM package as per the procedure outlined below.
URL - https://docs.docker.com/engine/installation/linux/docker-ce/centos/
As per the steps we need to install below two RPM packages in the order provided below.
docker-ce-selinux-17.03.2.ce-1.el7.centos.noarch.rpm
docker-ce-17.03.2.ce-1.el7.centos.x86_64.rpm
Error:
But the installation failed when i tried to install docker-ce RPM with below error.
Error: Package: docker-ce-17.06.0.ce-1.el7.centos.x86_64 (/docker-ce-17.06.0.ce-1.el7.centos.x86_64)
Requires: container-selinux >= 2.9
As per the error it seems it was unable to find the container-selinux package that was required to be installed. After looking into the enabled repository for the centos machine i was unable to see the ‘extras’ which should have been enabled.
To resolve the dependency i have added the below repository into the yum repos directory.
File: /etc/yum/repos/extras.repo
Output:
#CentOS extras repository
[extras]
name=CentOS 7 extras Repository
baseurl=http://mirror.centos.org/centos/7.3.1611/extras/x86_64/
gpgcheck=0
enabled=1
After adding and enabling the above repository i was able to resolve the dependency issue and docker CE was installed successfully.
NOTE: The container-selinux package provides SELinux policies for container runtimes.
It seems the package ‘container-selinux’ was recently included into the Extras repository. Previously it was a subpackage of docker.
RHEA-2017:0416 – Product Enhancement Advisory
Previously docker relied on docker-ce-selinux for SELinux policies but now it has been moved to container-selinux.
Docker for Centos – Install Instructions Causing Conflicts
With this move i believe there is no need to separately install the docker-ce-selinux-17.03.2.ce-1.el7.centos package which i need to try and test. This is just of information.
Hope you enjoyed reading this article. Thank you..
1 COMMENT