How to Install Docker-CE on RHEL 8

Background

If you’ve searched google to figure out how to install Docker-CE on RHEL 8, you may have been led to this very popular article: LinuxConfig.org: How to Install Docker on RHEL 8. If you’d read closely, you might have read a false statement which says, “What version to install? Well, Red Hat seems to have somehow blocked the installation of containerd.io > 1.2.0-3.el7, which is a dependency of docker-ce.” This statement is completely wrong. What’s going on here is two fold:

  1. This article shows the user how to install the wrong version of Docker-CE. It demonstrates how to install the version for CentOS 7, not CentOS 8 (which does work).
  2. This article does not verify that the container-tools module is uninstalled

To be fair, the upstream Docker CE docs also demonstrate how to install the version made for CentOS 7, so it’s kind of understandable that they are wrong on LinuxConfig.org. Let’s dig into how to install the right version, which works on RHEL 8.

Install Docker CE

First, verify that the container-tools module is uninstalled:

 

Now, add the Docker CE repository:

Now, modify the yum repo file to us the CentOS 8/RHEL 8 packages:

Finally, install Docker CE:

Conclusion

That’s it. That’s all it takes. Docker CE will install and run just fine on RHEL 8. Red Hat did not, in fact, figure out some way to block the installation of Docker on RHEL 8. That said, Red Hat does recommend Podman on RHEL 8. For more information, check out this blog: RHEL 8 enables containers with the tools of software craftsmanship. As always, leave any questions or comments you have below, and feel free to follow me on Twitter: @fatherlinux

3 comments on “How to Install Docker-CE on RHEL 8

Leave a Reply

Your email address will not be published.