I can't figure out why apache is throwing this error, all the files in the document root directory can be accessed but I get a forbidden error when I try to access files named dhtxxxx.xxx, if I change the filename to "htmlxgrid_dhx_terrace.css" it works fine.
The document root dir has the require all granted so that's not the problem:
<Directory /path/to/document/root >
AllowOverride All
Require all granted
</Directory>
Here's what I see in the logs:
[authz_core:error] [pid XXXX:tid XXXXXXX] [client xx.xx.xx.xx:XXXX] AH01630: client denied by server configuration: /path/to/document/root/dhtmlxGrid/skins/dhtmlxgrid_dhx_terrace.css
apachectl -v Server version: Apache/2.4.7 (Ubuntu) Server built: Oct 14 2015 14:20:21
I solved this adding
Require all granted
to my /etc/apache2/site-available/d8.conf
This is a working file for Drupal 8
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName local.d8
ServerAlias *.local.d8 local.d8.*
DocumentRoot /home/a/Public/d8
<Directory /home/a/Public/d8>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/d8_error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel notice
CustomLog ${APACHE_LOG_DIR}/d8_access.log combined
</VirtualHost>
I finally found the problem, it was this in the /etc/apache2/apache2.conf:
<Files ~ "^.ht">
Require all denied
</Files>
It should be:
<Files ~ "^\.ht">
Require all denied
</Files>
It turns out to be a bug in the apache2 chef cookbook that was introduced here: https://github.com/svanzoest-cookbooks/apache2/commit/6cb7d794cdf6fe05e650d17e432e5f5a6a86c8ea
Solution was to downgrade apache2 cookbook to 3.0.1.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With