summaryrefslogtreecommitdiff
path: root/examples/httpd2-blogsum.conf
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2012-09-05 18:34:48 +0000
committerDimitri Sokolyuk <demon@dim13.org>2012-09-05 18:34:48 +0000
commitacb38afcd4780191569ee809f3e8bdb550a634bc (patch)
treed54e4354f5758ee547c14c04bed307c5a473c854 /examples/httpd2-blogsum.conf
blogsum
Diffstat (limited to 'examples/httpd2-blogsum.conf')
-rw-r--r--examples/httpd2-blogsum.conf49
1 files changed, 49 insertions, 0 deletions
diff --git a/examples/httpd2-blogsum.conf b/examples/httpd2-blogsum.conf
new file mode 100644
index 0000000..a887d0d
--- /dev/null
+++ b/examples/httpd2-blogsum.conf
@@ -0,0 +1,49 @@
+<VirtualHost *:80>
+ ServerName www.example.com
+ DocumentRoot /var/www/blogsum
+ DirectoryIndex index.cgi
+ PerlRequire /www/blogsum/startup.pl
+
+ Options +FollowSymlinks
+ RewriteEngine On
+ RewriteRule ^/rss.xml$ /index.cgi?rss=1 [PT,QSA]
+ RewriteRule ^/rss2.xml$ /index.cgi?rss=2 [PT,QSA]
+ RewriteRule ^/Page/([^/]+)$ /index.cgi?page=$1 [PT,QSA]
+ RewriteRule ^/Tags/([^/]+)$ /index.cgi?search=$1 [PT,QSA]
+ RewriteRule ^/([0-9]{4})/([0-9]{2})/([^/]+)$ /index.cgi?view=article&year=$1&month=$2&uri=$3 [PT,QSA]
+ RewriteRule ^/([0-9]{4})/([0-9]{2})/?$ /index.cgi?view=article&year=$1&month=$2 [PT,QSA]
+ RewriteRule ^/([0-9]{4})/?$ /index.cgi?view=article&year=$1 [PT,QSA]
+
+ PerlModule ModPerl::PerlRun
+ <LocationMatch ^/index.cgi>
+ SetHandler perl-script
+ PerlResponseHandler ModPerl::PerlRunPrefork
+ Options ExecCGI
+ Order deny,allow
+ Allow from all
+ </LocationMatch>
+ <LocationMatch ^/admin.cgi>
+ SetHandler perl-script
+ PerlResponseHandler ModPerl::PerlRunPrefork
+ Options ExecCGI
+ Order deny,allow
+ Allow from all
+ AuthUserFile /var/www/conf/blogsum.htpasswd
+ AuthName "Blogsum Admin - example.com"
+ AuthType Basic
+ <limit GET POST>
+ require valid-user
+ </limit>
+ </LocationMatch>
+ <LocationMatch ^/Blogsum/>
+ SetHandler perl-script
+ PerlResponseHandler ModPerl::PerlRunPrefork
+ Options -ExecCGI
+ Order deny,allow
+ Allow from all
+ </LocationMatch>
+ <LocationMatch ^/data/>
+ Order deny,allow
+ Deny from all
+ </LocationMatch>
+</VirtualHost>