How to add additional commands to CageFS users in CloudLinux

Adding these will allow them to be used by all users after CageFS has been updated.

Adding paths to commands and files

Use SSH to log into your server as root.

Using your favorite text editor, open the file /etc/cagefs/conf.d/custom.cfg. If the file doesn't already exist, this will create it.

nano /etc/cagefs/conf.d/binutils.cfg

You will want to add a list of paths separated by commas on the line that starts with paths
comment=custom paths

Append the full path of the command you want to add; one at a time, separated by commas to the end of the line. Once you have added what you want, save the file.

To apply the change, run the following command cagefsctl –force-update

cagefsctl --force-update

Adding packages to CageFS users

If your program was installed via Yum, you can add the entire package through a different method.

Use SSH to log into your server as root.

Run the following command with the name of the package that you want to add to add:

cagefsctl --addrpm <packagename>

Once you've added the package, run cagefsctl –force-update to update the cageFS user configuration.

cagefsctl --force-update

The changes will not be applied until you update it