Today guide we will show you on how to install Nginx web server on Red Hat Enterprise Linux 8.5 (RHEL). We will deploy Nginx using mainline branch, instead of stable package. What should you do is prepare virtual or physical server, either it run under vps, cloud server, bare metal or even dedicated server. That’s…
Well, before we can install Mainline package of Nginx web server we should add the Nginx mainline package repository into your machine. After that you can run the Nginx installer on your system.
REQUIRENMENT: * VPS / VM / Cloud / Bare Metal * OS Distro with RedHat EL 8.5 * Superuser Privileges (Root) * gNome Terminal for Linux Dekstop * PuTTy SSH Client for Windows * Use can use "yum" or "dnf" commands.
1.) On Step-One Let’s Install Package Dependency.
$ yum install yum-utils
2.) Add Nginx Mainline Repository into Your Machine
The official Nginx team by default only enable stable Nginx branch on their repository file. So, if you want to move on Nginx mainline branch you should enable mainline package, instead of stable branch.
--------------------------------------------------------------------------- [nginx-mainline] name=nginx mainline repo baseurl=http://nginx.org/packages/mainline/centos/$releasever/$basearch/ gpgcheck=1 enabled=0 gpgkey=https://nginx.org/keys/nginx_signing.key module_hotfixes=true ---------------------------------------------------------------------------
3.) Enable Nginx Mainline Package using the following command.
$ yum-config-manager --enable nginx-mainline
Then update your RHEL 8+ system.
$ yum update
4.) Let’s Install Nginx Mainline Package on Your Machine
This will install Nginx mainline version 1.21+, eg “nginx-1.21.6”.
$ yum install nginx
5.) Don’t Forget To Enable and Start Nginx Web Server on Your Machine
$ systemctl enable nginx.service $ systemctl start nginx.service
Finished… with the above tutorials you have done install and configure Nginx mainline package on Red Hat Enterprise Linux 8.5 (RHEL).