0

I'm working on a Symfony2 project (using latest 2.3.2) and for that I made this virtual host:

<VirtualHost *:80>
    DocumentRoot /var/www/html/nnplat/web
    ServerName nnplat.devserver

    <Directory /var/www/html/nnplat/web>
       AllowOverride all
       Allow from all
    </Directory>

    ErrorLog logs/nnplat-error_log
    CustomLog logs/nnplat-access_log common
</VirtualHost>

If I call http://nnplat.devserver I got this error:

Oops! An Error Occurred The server returned a "404 Not Found". Something is broken. Please e-mail us at [email] and let us know what you were doing when this error occurred. We will fix it as soon as possible. Sorry for any inconvenience caused.

But if I call this URL http://devserver/nnplat/web/app_dev.php it works, where is the problem? I can't find what is wrong in my VH

Reynier
  • 2,420
  • 11
  • 51
  • 91
  • Do you have `DirectoryIndex` set? Have you checked `http://nnplat.devserver/app_dev.php`? – vee Jul 27 '13 at 02:34
  • @vinodadhikary no in the sample code but yes already tried with `DirectoryIndex app.php` and results are the same also checked the `app_dev.php` and nothing `404 error found` – Reynier Jul 27 '13 at 02:59

1 Answers1

1

try this

ServerName nnplat.devserver
<VirtualHost *:80>
DocumentRoot /var/www/html/nnplat/web
<Directory "/var/www/html/nnplat/web">
DirectoryIndex app_dev.php
Options -Indexes FollowSymLinks SymLinksifOwnerMatch
AllowOverride All
Allow from All
</Directory>
</VirtualHost>
  • nothing, get the same error and `ServerName` should go inside the Virtual Host definition since I've some others VH in there – Reynier Jul 27 '13 at 13:14