October 6, 2022


News and Update

Tips on how to set up that newest model of Docker on AlmaLinux

Picture: REDPIXEL / Adobe Inventory

AlmaLinux is a Linux clone of Crimson Hat Enterprise, which suggests it doesn’t include Docker pre-installed. In reality, most RHEL-based distros at the moment default to Podman. Whereas Podman is an utility that intently resembles Docker, I nonetheless have a tendency to like the unique, so I’d fairly use that expertise than exchange it.

The issue is that the Docker set up on the RHEL based mostly distro is inaccurate. It’s not troublesome, however with out figuring out the correct steps or flags to make use of, you’ll discover it nearly unimaginable to put in Docker.

UNDERSTAND: Recruitment Toolkit: Again-end Developer (TechRepublic Premium)

Fortunately, I took one for the workforce and discovered the way it could possibly be executed with out an excessive amount of stress. Let’s make it occur.

What you’ll need to put in Docker on AlmaLinux

The one issues you could make this work are a working occasion of AlmaLinux 9 and a consumer with sudo privileges.

Tips on how to set up Docker CE on AlmaLinux

Log in to your AlmaLinux occasion and ensure it’s updated with the command:

sudo dnf replace

A phrase of warning – the replace will take a while. Relying on how lengthy it’s been because the final replace (and the pace of your community connection), give this course of 10 to 60 minutes. For me, it took about half-hour to finish.

As soon as the replace is over, you’ll want to put in the event instruments, in a useful workforce means. This set up could be executed with the command:

See also  The most recent updates on the battle towards dental amalgamation

sudo dnf groupinstall "Improvement Instruments"

Once more, this set up will take a while. It’s sooner than the replace, however not less than see the output from the command in 5 minutes or so.

As soon as that’s executed, you need to most likely restart the server if the replace features a kernel. When the reboot is completed, log again in and add the required Docker repository with the command:

sudo dnf config-manager --add-repo=https://obtain.docker.com/linux/centos/docker-ce.repo

With the repository added, we will now set up Docker CE. Nevertheless, that is the place the trick comes into play. If you happen to simply use the command:

sudo dnf set up docker-ce -y

The command will fail. Why? As a result of many Docker dependencies battle with Podman and its dependencies. To resolve that downside, you should set up Docker CE and take away Podman and its associated packages. That is executed with the command:

sudo dnf set up docker-ce --allowerasing

After the above command completes, begin and allow the Docker service with:

sudo systemctl allow --now docker

Lastly, add your consumer to the docker group with the command:

sudo usermod -aG docker $USER

Sign off and log again in.

You possibly can check the brand new set up by flattening the hello-world picture with the command:

docker pull hello-world

Congratulations, you simply changed Podman with Docker on AlmaLinux. Whether or not you need to do that or not relies on whether or not you see Podman as a worthy successor to Docker. If not, that is your greatest guess aside from switching to an Ubuntu-based server distro.

See also  Psychological affect of genuine crime consumption

Subscribe to TechRepublic’s Tips on how to make expertise work on YouTube for all the most recent tech recommendation for enterprise professionals from Jack Wallen.