Skip to content

Instantly share code, notes, and snippets.

@level09
Created January 16, 2013 19:21
Show Gist options
  • Save level09/4549941 to your computer and use it in GitHub Desktop.
Save level09/4549941 to your computer and use it in GitHub Desktop.
Apache Virtual Host for Drupal
<VirtualHost *:80>
ServerName domain.com
DocumentRoot /path/to/root
ErrorLog path/to/error.log
CustomLog path/to/custom.log
<Directory "path/to/root">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
#Etag
#FileETag none
#Deflate
#AddOutputFilterByType DEFLATE text/html text/plain text/css text/xml application/x-javascript
</Directory>
<LocationMatch ^/user>
order deny,allow
Allow from ip/mask
deny from all
</LocationMatch>
<LocationMatch ^/admin>
order deny,allow
Allow from ip/mask
deny from all
</LocationMatch>
</VirtualHost>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment