The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Customizing cPanel internal PHP for 11.36+

Discussion in 'EasyApache' started by bytebeam, Nov 22, 2013.

  1. bytebeam

    bytebeam Registered

    Joined:
    Sep 23, 2013
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Website Owner
    From v 11.36 +, makecpphp is no longer supported, and cPanel advises to customize the related RPM (for v 11.40, its cpanel-php53.5.3.17-5.cp1136).

    Our setup requires the bcmath extension. For the moment, we use a postupcp hook which executes the following:

    - Backup of the /usr/local/cpanel/3rdparty/php/53/etc/php.ini
    - Overwriting of /usr/local/cpanel/3rdparty/php/53/etc/php.ini with our custom php.ini
    - Copy bcmath.so to /usr/local/cpanel/3rdparty/php/53/lib64/extensions/bcmath.so
    - /usr/local/cpanel/bin/install_php_inis
    - service cpanel restart

    This method is rather inelegant and won't cope with changes to internal PHP versions, therefore we would also have to freeze the current PHP rpm.

    I would be grateful if someone could suggest another way to automate internal PHP customizations where additional modules would always be included no matter the version.

    As side note, is there any reason why the internal PHP version differs from the PHP version available with EasyApache ? I do understand that both PHP instances serve a different context and require each their own set of specific settings, but why maintain concurrently different versions of PHP instead of the same version running with a different config ?
     
  2. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    I'll file a request to add bcmath to the internal PHP.
     
  3. bytebeam

    bytebeam Registered

    Joined:
    Sep 23, 2013
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Website Owner
    Thank you !
     
Loading...

Share This Page