Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Directory AllowOverride not working in Include FIle

Discussion in 'EasyApache' started by Quin Glover, Nov 8, 2017.

  1. Quin Glover

    Quin Glover Registered

    Joined:
    Nov 8, 2017
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    New York, New York
    cPanel Access Level:
    Root Administrator
    I have a laravel site that needs Directory AllowOverride=All. I created a Include .conf file and uncommented the line in the main httpd.conf file

    /etc/apache2/conf.d/userdata/std/2_4/*username/*domain/.conf

    I ran /scripts/ensure_vhost_includes --all-users to ensure the Include .conf is included but the httpd.conf is still not reading the Directive of AllowOverride in the include file.

    If I edit the .httpd.conf file directly it works fine but that is not recommended since that file will get overwritten is I make any CPanel changes.
     
  2. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,802
    Likes Received:
    1,895
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello,

    The "Optimize .htaccess (AllowOverride)" option is found in "WHM >> Apache Configuration >> Global Configuration". More information about this option is available on the following thread:

    .htaccess search optimization in cPanel & WHM version 66

    You can try changing it to the following option to see if that allows your custom Apache includes to work:

    Search "/" and below (No optimization, Search Full Path)

    Note that you should not directly alter the global httpd.conf file, as those edits are not preserved. There's no need to uncomment any lines in that file when setting up a custom include file.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Quin Glover

    Quin Glover Registered

    Joined:
    Nov 8, 2017
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    New York, New York
    cPanel Access Level:
    Root Administrator
    Thank you that did help a lot. But then what is the point of the Include conf.d line in the virtual host configuration?
     
  4. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,802
    Likes Received:
    1,895
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello,

    It's commented because it's only added as a note to instruct you on how to create the custom include file.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice