Skip to main content

Customizing php.conf

Comments

3 comments

  • vanessa
    Yes, but due to that fact that it is indeed not a template, the process is slightly less pretty. 1) Edit /usr/local/apache/conf/includes/pre_main_2.conf, add a custom include, like: Include "/usr/local/apache/conf/myphp.conf"
    The custom include would be your version of php.conf 2. Remove the php.conf include from httpd.conf, then run the distiller: /usr/local/cpanel/bin/apache_conf_distiller --update
    3. Restart Apache I'd also perhaps advise that you add a script hook (/scripts/posteasyapache) to make sure php.conf is removed every time you rebuild. It'll get added back as long as EA is configured to compile PHP. (create the file and make sure to chmod 750, etc) #!/bin/bash # If the conf file is included in httpd.conf remove it grep "php.conf" /usr/local/apache/conf/httpd.conf >/dev/null 2>&1 if [[ $? -eq 0 ]]; then sed '/php.conf/d' -i /usr/local/apache/conf/httpd.conf /usr/local/cpanel/bin/apache_conf_distiller --update killall -USR1 httpd fi
    0
  • hmcp
    Thanks. Looking at what you wrote it seems the posteasyapache hook is all I need.
    0
  • cPanelMichael
    I am happy to see the advice you received was helpful. I am marking this thread as [Resolved]. Thank you.
    0

Please sign in to leave a comment.