How to Install REMI Repository on CentOS 8

Install REMI Repository on CentOS 8

In this article, we will have explained the necessary steps to install and configure the REMI repository on CentOS 8. Before continuing with this tutorial, make sure you are logged in as a user with sudo privileges. All the commands in this tutorial should be run as a non-root user.

REMI is a free-to-use repository created and maintained by a Remi Collect. The REMI repository’s main goal is to provide the latest versions of the PHP stack, full-featured, and some other software packages to the Fedora and Enterprise Linux (RHEL, CentOS, Oracle, Scientific Linux) operating systems.

Install REMI Repository on CentOS

Step 1. The first command will update the package lists to ensure you get the latest version and dependencies.

sudo dnf -y update

Step 2. Install REMI Repository.

Before we can actually install Remi, we need to enable the EPEL repository first:

sudo dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm

Now, run the following commands to install the REMI repository:

sudo dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm

Check enabled repositories:

$ sudo yum repolist
Last metadata expiration check: 0:00:04 ago on Tue 28 Oct 2019 08:20:18 PM EAT.
repo id                                        repo name                                                                                     status
AppStream                                      CentOS-8 - AppStream                                                                          4,890
BaseOS                                         CentOS-8 - Base                                                                               2,713
*epel                                          Extra Packages for Enterprise Linux 8 - x86_64                                                1,478
extras                                         CentOS-8 - Extras                                                                                 3
remi-modular                                   Remi's Modular repository for Enterprise Linux 8 - x86_64                                         0
remi-safe                                      Safe Remi's RPM repository for Enterprise Linux 8 - x86_64                                    1,923

Then, you can install yum-config-manager which will help you enable and disable a repository quickly:

sudo dnf install dnf-utils

Now, you can enable repository at runtime:

sudo dnf --enablerepo=remi install php-fpm

That’s all you need to do to install the REMI repository on CentOS 8. I hope you find this quick tip helpful. For further reading on the REMI repository, please refer to their official knowledge base. If you have questions or suggestions, feel free to leave a comment below.