#
-# Apache/PHP/Drupal settings:
+# Apache/PHP/Drupal settings.
+
+# Default setup is for running drupal in vhost.
+# You can setup drupal as alias /drupal, but you need to comment/uncomment few things.
#
+# Please note that drupal-ID's don't work in subdirs, you need vhost for that.
<Directory /usr/share/drupal/htdocs>
Options FollowSymLinks
AllowOverride None
- <IfModule mod_access.c>
- order allow,deny
- allow from all
- </IfModule>
- <IfModule mod_php4.c>
- php_value include_path "/usr/share/drupal:/etc/drupal:."
- </IfModule>
+ Order allow,deny
+ Allow from all
# Set the default handler.
<IfModule mod_dir.c>
# Override PHP settings. More exist in sites/default/settings.php, but
# the following cannot be changed at runtime. The first IfModule is
# for Apache 1.3, the second for Apache 2.
+ # php4 module under Apache 1.3
<IfModule mod_php4.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
+ php_value memory_limit 12M
+ </IfModule>
+ # php5 module under Apache 1.3
+ <IfModule mod_php5.c>
+ php_value magic_quotes_gpc 0
+ php_value register_globals 0
+ php_value session.auto_start 0
+ php_value memory_limit 12M
</IfModule>
+ # php under Apache 2.x module
<IfModule sapi_apache2.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
+ php_value memory_limit 12M
</IfModule>
# Reduce the time dynamically generated pages are cache-able.
# Modify the RewriteBase if you are using Drupal in a subdirectory and
# the rewrite rules are not working properly.
- # Comment it out if you have drupal configured in virtualhost root.
- RewriteBase /drupal
+ # Enable RewriteBase if you have drupal configured in virtualhost root.
+ #RewriteBase /drupal
# Rewrite old-style URLs of the form 'node.php?id=x'.
#RewriteCond %{REQUEST_FILENAME} !-f
ErrorDocument 404 /index.php
</Directory>
-<IfModule mod_alias.c>
- Alias /drupal /usr/share/drupal/htdocs
-</IfModule>
+# If having drupal installed as /drupal
+#<IfModule mod_alias.c>
+# Alias /drupal/files /var/lib/drupal
+# Alias /drupal /usr/share/drupal/htdocs
+#</IfModule>
+#
+#<Location /drupal>
+# # Customized error messages.
+# ErrorDocument 404 /drupal/index.php
+#</Location>
-# Comment out this block if you have drupal configured in virtualhost root.
-<Location /drupal>
- # Customized error messages.
- ErrorDocument 404 /drupal/index.php
-</Location>
+<Directory /var/lib/drupal>
+ Allow from all
+ SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
+ Options None
+ <IfModule mod_rewrite.c>
+ RewriteEngine off
+ </IfModule>
+</Directory>
-# use something like this for vhost setup, and remember to disable Alias
-# /drupal and RewriteBase /drupal above.
-# Please note that drupal-ID's don't work in subdirs, you need vhost for that.
-#<VirtualHost *:80>
-# ServerName drupal
-# DocumentRoot /usr/share/drupal/htdocs
-#</VirtualHost>
+<VirtualHost *:80>
+ ServerName drupal
+ ServerAlias www.drupal
+ DocumentRoot /usr/share/drupal/htdocs
-# vim: filetype=apache ts=4 sw=4 et
+ <IfModule mod_alias.c>
+ Alias /files /var/lib/drupal
+ </IfModule>
+</VirtualHost>