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!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

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 Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    42,782
    Likes Received:
    1,712
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    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.
     
  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 Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    42,782
    Likes Received:
    1,712
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    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.
     
Loading...

Share This Page