1

I'm setting up a new cake php site into my local.

In the index there is an .htaccess with some rules, it needs to be there, but once i trying to get into the page i only can see the directory list.

if i check my php erros i have:

[Thu Aug 01 14:24:22.065471 2019] [authz_core:error] [pid 44232] [client 127.0.0.1:50926] AH01630: client denied by server configuration: /usr/local/var/www/cis/portal_remote/core/.htaccess

I have this in my vhost file

<VirtualHost *:80>
      ServerAdmin webmaster@dummy-host2.example.com
      DocumentRoot "/usr/local/var/www/cis/portal_remote/core"
      ServerName cis-portal72.local
      ErrorLog "/usr/local/var/log/httpd/cis-portal.local-error_log"
      CustomLog "/usr/local/var/log/httpd/cis-portal.local_access_log" common
      <Directory "/usr/local/var/www/portal_remote/core">
         AllowOverride FileInfo
         Order allow,deny
         Allow from all
         #all New directive needed in Apache 2.4.3:
         AllowOverride All
         Require all granted
     </Directory>
 </VirtualHost>

I'm using Mojave with apache

Server version: Apache/2.4.39 (Unix) Server built: Apr 19 2019 17:53:55

The weird thing is that it works in remote using ubuntu and same vhost, but not locally with my mac.

.htaccess file

<IfModule mod_rewrite.c>
   RewriteEngine on

   RewriteRule    ^$ app/webroot/    [L]
   RewriteRule    (.*) app/webroot/$1 [L]
    php_value session.cookie_lifetime 0
    php_value session.gc_maxlifetime 3600
    php_value session.gc_probability 1
    php_value session.gc_divisor 1000
    php_value post_max_size 128M

    php_value max_input_vars 1000000
</IfModule>
alexmorgan.cr
  • 270
  • 6
  • 18
  • Possible duplicate of [Apache2: 'AH01630: client denied by server configuration'](https://stackoverflow.com/questions/18392741/apache2-ah01630-client-denied-by-server-configuration) – zbee Aug 01 '19 at 21:10
  • @zbee i saw that, but doesn't fix my issue, actually is pretty much the same as my vhost configuration. – alexmorgan.cr Aug 01 '19 at 21:10
  • Have you tried removing the old syntax and reloading Apache? You have both syntax right now, I imagine Apache can't even build properly right now, or is ultimately misunderstanding the configuration provided. – zbee Aug 01 '19 at 21:12
  • @zbee yes i tried only with ` Require all granted ` and same issue – alexmorgan.cr Aug 01 '19 at 21:16
  • You must have some authorization directive in `.htaccess`, judging by the log message so I'd say it's not because of the vhost config. – msg Aug 01 '19 at 21:16
  • Alright. Share the `.htaccess` file as @msg suggests then for that to be examined. – zbee Aug 01 '19 at 21:17
  • Just added the .htaccess, just wondering why this is working in remote server (Same code) but not in my local – alexmorgan.cr Aug 01 '19 at 21:19

1 Answers1

0

Non relevant solution, was a terrible type of my own.

alexmorgan.cr
  • 270
  • 6
  • 18