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.

Environment Variables from mod_rewrite

Discussion in 'General Discussion' started by Atrix, Jun 3, 2015.

  1. Atrix

    Atrix Member

    Sep 7, 2012
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    I "fixed" this by switching to using php as a dso however now I have to set "nobody" as the owner for files I want wriet
    for files/directories which need write permissions and I'm pretty sure it's far less secure.

    Example .htacces line:
    RewriteRule .* - [E=boostpath:normal]

    This doesn't get put to php if it is in cgi mode in either $_SERVER or $_ENVIRONMENT variables.

    I can't go suphp b/c it limits the scalability of the server too much, it's slow and intensive. Does mod_ruid2 run as the user from the account? What mode should I run it under?

    Not for the first time I really wish fcgid or php-fpm was a cpanel default option it really makes life hard soemtimes.

    Here's what I need:

    Eaccellerator has to work
    mod_rewrite variables have to work
    setting file/directory owner as the cpanel user and only giving owner write permissions has to work
    It can't be overly slow or cpu intensive vs other options

    What php configuration setup best serves this through cpanel?
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Apr 11, 2011
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator

    Yes, I suggest using Mod_Ruid2 with DSO. It's documented here:

    cPanel - Mod_Ruid2

    Note there are some applications it's incompatible with, so ensure you review the document before enabling it.

    Thank you.

Share This Page