How to Set Custom php.ini Values in Cagefs for PHP Selector
CloudLinux's Cagefs allows each user to have their own custom php.ini settings with the php selector. However the options presented inside have pre-defined limits that may not work for all users.
It is possible to modify custom settings by hand through the command line.
Start by going into the command line. After you're in, run the following command to get into the specific user's caged environment:
cagefsctl -e <username>
This will take you to a new prompt. Once there, you can use a text editor to modify the php settings directly:
Once there, you will see a section like this:
;>=== Start of PHP Selector Custom Options === ;<=== End of PHP Selector Custom Options =====
Inside of this section, you can put in your custom PHP Variables such as memory_limit, post_max_size or any other thing you may need to change. You should put them just as if you were modifying any php.ini file, but keep them in that section to make it easy to find later if you need to change it again.