Install Drush

How to install Drush in cPanel with CloudLinux and CageFS

RedyHost customers who run Drupal websites in a cPanel hosting, ask us about getting Drush available in cPanel. Of course, RedyHost cPanel hosting comes with Drush preinstalled and available inside the GageFS.

This page describes how to install Drush in a cPanel/WHM server with CloudLinux.

This page should be used by system admins who want to make Drush available to their customers in cPanel with CloudLinux/CageFS installed.

First, SSH to the cPanel/WHM server as the root user.

Next, run these commands to install drush:

chmod +x drush.phar 
mv drush.phar /usr/local/bin/drush

Now, as you have installed drush, let’s add it to the CageFS so that users could access it

vim /etc/cagefs/conf.d/drush.cfg

And add this content:


comment=Allow drush to work on the server 

Next, update CageFS

cagefsctl --force-update

Test to see if it works, become a CageFS user.


su cagefsuser 
vi ~/.drush/drush.ini


[Add this content: `disable_functions=` and save the file]


drush init

To benefit from (benchmarked) real fast cPanel hosting, including free as-is cPanel account migration,

Sign up to our cPanel hosting now!

Posted in How to and tagged , , .