So I just ran a clean install of Mountain Lion OSX 10.8 and am trying to get everything back up and running again. I uncommented the php module and vhosts in http.conf, added brew, mcrypt, autoconf etc.. I use VirtualHostX and I set my domain and local path but when I pull it up it shows Index of / instead of my app.

I have an index.php in my root and my vhosts looks like this:

NameVirtualHost *:80

<Directory "/Users/me/Sites/">
    Allow From All
    AllowOverride All
    Options +Indexes

<VirtualHost *:80>
    ServerName ""
    DocumentRoot "/Users/me/Sites/"

I've spend hours troubleshooting issues like these in the past...getting better, but this is a new one and I can't seem to track down the issue.

  • I'm using a php framework called Laravel and the doc root must be directed to public directory.

closed as off topic by Michael Hampton, EEAA, Ward, Khaled, dunxd Feb 27 '13 at 16:31

Questions on Server Fault are expected to relate to server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here. If this question can be reworded to fit the rules in the help center, please edit the question.

  • Something stupid, do you need a trailing slash at the end of you virtual host like you do in directory – Mistry Feb 27 '13 at 4:04

Find DirectoryIndex in your apache config files (probably in the httpd.conf), and check whether index.php is there. I assume that it is not.

  • thx, worked for me :) – nerdess Feb 11 '15 at 19:48

You need to disable indexes in vhost

 <Directory /www/somefolder>
 Options -Indexes FollowSymLinks
 AllowOverride None

Not the answer you're looking for? Browse other questions tagged or ask your own question.