# :vim set syntax apache
LogLevel notice
PerlChildInitHandler OpenILS::WWW::Reporter::child_init
PerlChildInitHandler OpenILS::WWW::SuperCat::child_init
Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
ExpiresActive On
ExpiresByType image/jpg "access plus 1 month"
ExpiresByType image/jpeg "access plus 1 month"
ExpiresByType image/gif "access plus 1 month"
ExpiresByType image/png "access plus 1 month"
ExpiresByType text/html "access plus 250 minutes"
ExpiresByType application/x-javascript "access plus 240 minutes"
ExpiresByType text/css "access plus 230 minutes"
AliasMatch ^/opac/.*/skin/(.*)/(.*)/(.*) /openils/var/web/opac/skin/$1/$2/$3
AliasMatch ^/opac/slimpac/.*/skin/(.*)/xml/(.*) /openils/var/web/opac/skin/$1/xml/$2
NameVirtualHost *:80
ServerName demo.gapines.org:80
ServerAlias 10.3.0.103:80
DocumentRoot /openils/var/web/
PerlRequire /opt/conf/startup.pl
PassEnv PERL5LIB
DirectoryIndex index.xml index.html
# ----------------------------------------------------------------------------------
# Configure the gateways
# ----------------------------------------------------------------------------------
OSRFGatewayConfig /openils/conf/opensrf_core.xml
ILSRestGatewayConfig /openils/conf/opensrf_core.xml
# Deflate whatever we can
AddOutputFilterByType DEFLATE application/x-javascript text/html text/plain text/xml text/css
# ----------------------------------------------------------------------------------
# DEMO server redirect
# ----------------------------------------------------------------------------------
#RedirectMatch 301 ^/$ /opac/en-US/skin/default/xml/index.xml
SetHandler perl-script
PerlHandler OpenILS::WWW::Redirect
PerlSendHeader On
allow from all
AddType application/xhtml+xml .xml
AddType application/xhtml+xml .xml
ExpiresByType text/xml "access plus 1 hour"
Options +Includes
XBitHack Full
RewriteEngine on
BrowserMatchNoCase MSIE IE
BrowserMatchNoCase mozilla mozilla
BrowserMatchNoCase safari safari
XMLEntStripPI "yes"
XMLEntEscapeScript "no"
XMLEntStripComments "yes"
XMLEntContentType "text/html; charset=utf-8"
# forces quirks mode
XMLEntStripDoctype "yes"
AddOutputFilter INCLUDES .xsl
AddOutputFilter INCLUDES;XMLENT .xml
# add languages as necessary
SetEnvIf Request_URI "^/opac/slimpac/" slimpac=true
SetEnvIf Request_URI "/en-US/" locale=en-US
SetEnvIf Request_URI "/fr/" locale=fr
SetEnvIf Request_URI ".*" OILS_OPAC_BASE=/opac/
# ----------------------------------------------------------------------------------
# Run server-side XUL through xmlent to load the correct XML entities
# ----------------------------------------------------------------------------------
Options +Includes
XMLEntContentType "application/vnd.mozilla.xul+xml"
AddOutputFilter INCLUDES;XMLENT .xul
allow from all
SetHandler perl-script
PerlHandler OpenILS::WWW::SuperCat::oisbn
Options +ExecCGI
PerlSendHeader On
allow from all
SetHandler perl-script
PerlHandler OpenILS::WWW::SuperCat::supercat
Options +ExecCGI
PerlSendHeader On
allow from all
SetHandler perl-script
PerlHandler OpenILS::WWW::SuperCat::unapi
Options +ExecCGI
PerlSendHeader On
allow from all
SetHandler perl-script
PerlHandler OpenILS::WWW::SuperCat::bookbag_feed
Options +ExecCGI
PerlSendHeader On
allow from all
XMLEntContentType "text/html"
SetOutputFilter XMLENT
SetHandler perl-script
PerlHandler OpenILS::WWW::SuperCat::opensearch_feed
Options +ExecCGI
PerlSendHeader On
allow from all
XMLEntContentType "text/html"
SetOutputFilter XMLENT
SetHandler perl-script
PerlHandler OpenILS::WWW::SuperCat::changes_feed
Options +ExecCGI
PerlSendHeader On
allow from all
# ----------------------------------------------------------------------------------
# System config CGI scripts go here
# ----------------------------------------------------------------------------------
Alias /cgi-bin/ "/openils/var/cgi-bin/"
AddHandler cgi-script .cgi .pl
AllowOverride None
Options None
Order deny,allow
Deny from all
Allow from 10.0.0.0/8
Options FollowSymLinks ExecCGI Indexes
AddHandler cgi-script .pl
AllowOverride None
Options FollowSymLinks ExecCGI
allow from all
# ----------------------------------------------------------------------------------
# JSON gateway
# ----------------------------------------------------------------------------------
SetHandler osrf_json_gateway_module
allow from all
# ----------------------------------------------------------------------------------
# ILS-concious XML Gateway
# ----------------------------------------------------------------------------------
SetHandler ils_rest_gateway_module
allow from all
# ----------------------------------------------------------------------------------
# Force SSL on the OPAC's "My Account" page
# ----------------------------------------------------------------------------------
SSLRequireSSL
# ----------------------------------------------------------------------------------
# The reporting engine lives here
# ----------------------------------------------------------------------------------
RedirectMatch ^/reporter/?$ /reporter/dashboard
SetHandler perl-script
PerlHandler OpenILS::WWW::Reporter
Options +ExecCGI
PerlSendHeader On
allow from all