I just created my first Symfony2 project. But the \"/web/app_dev.php\" part in the URL annoys me. It should be possible to do this without Virtual hosts...
//enable mod rewrite
sudo a2enmod rewrite
Change all occurrences of AllowOverride None by AllowOverride All
File: (/etc/apache2/apache2.conf) or (/etc/apache2/sites-available/000-default.conf) - for me work with /etc/apache2/apache2.conf file.
Example:
# enable the .htaccess rewrites
Options Indexes FollowSymLinks
#AllowOverride None #commented
AllowOverride All
Require all granted