Skip to content

Instantly share code, notes, and snippets.

@rmzamora
Created January 16, 2014 04:56
Show Gist options
  • Save rmzamora/8450000 to your computer and use it in GitHub Desktop.
Save rmzamora/8450000 to your computer and use it in GitHub Desktop.
Apache vhost for symfony2 apps
<VirtualHost *:80>
ServerName www.domain.com.localhost
ServerAlias domain.com.localhost
ServerAdmin webmaster@localhost
DocumentRoot /home/user/www/project/web
<Directory /home/user/www/project/web/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ /app.php [QSA,L]
</IfModule>
</Directory>
</VirtualHost>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment