Installing Docker Packages and Starting Docker Service
Step 1: Add the Docker Repository
Run the following command to add the repository. This will enable dnf
to find the Docker packages.
sudo dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
Step 2: Install Docker Packages
After adding the repository, run the dnf install
command. dnf
will be able to locate and install the Docker packages.
sudo dnf install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
Step 3: Start the Docker Service
Once the installation is complete, you'll need to start and enable the Docker service to ensure it runs automatically on startup.
sudo systemctl start docker
sudo systemctl enable docker
By following these steps, you'll successfully install and set up Docker.
Top comments (0)