Learn how to install NGINX on cPanel Server following tutorial.
Installing NGINX is very easy and quick on cPanel/WHM Server. We will use Engintron to install NGINX on your cPanel/WHM Server. There are a few basic requirements to follow this guide which are discussed below.
Requirements:-
cPanel/WHM installed Server, Guide Link Below
Guide to Install cPanel/WHM
Root Access to Server via SSH
Installation:-
- Login to root user via SSH
- Run following commands to install Engintron which will install NGINX
$ cd /; rm -f engintron.sh; wget –no-check-certificate https://raw.githubusercontent.com/engintron/engintron/master/engintron.sh; bash engintron.sh install
- Above installation will take a couple of minutes depending on the machine specifications
- Login to WHM and Goto Plugins, you will find “Engintron for cPanel/WHM”, which means your Engintron is successful along with NGINX.
This is how Engintron’s Front Page looks like after opening.
Configuration for Cloudflare Users
- Open Engintron as explained in the last step of the installation
- Under NGINX Menu in Left Sidebar look for “Edit your custom_rules for Nginx (view default)” and tap it
- Uncomment the following line by removing # character
set $PROXY_DOMAIN_OR_IP “XXX.XXX.XXX.XXX”;
XXX.XXX.XXX.XXX – It is your cPanel’s shared IP address, replace it and tap on update rules. - Engintron will restart and everything will be working out of the box.
So we have completed NGINX Installation with the help of Engintron.