]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/examples/apache/eg_vhost.conf
adding some default configs
[Evergreen.git] / Open-ILS / examples / apache / eg_vhost.conf
1 # ----------------------------------------------------------------------------------
2 # This is the global Evergreen virtual host config.  Anything you want published
3 # through all virtual hosts (port 80, port 443, etc.) should live in here.
4 # ----------------------------------------------------------------------------------
5
6
7 # ----------------------------------------------------------------------------------
8 # Point / to the opac
9 # ----------------------------------------------------------------------------------
10 RedirectMatch 301 ^/$ /opac/en-US/skin/default/xml/index.xml
11
12
13 # ----------------------------------------------------------------------------------
14 # Configure the gateway
15 # ----------------------------------------------------------------------------------
16 OSRFGatewayConfig /openils/conf/opensrf_core.xml
17
18
19 # ----------------------------------------------------------------------------------
20 # Set up the book jackets URL
21 # XXX This pulls images from Amazon, don't use this in a production environment
22 # ----------------------------------------------------------------------------------
23 RewriteEngine on
24 ProxyTimeout 2
25 RewriteRule /opac/extras/jacket/small/(.*) \
26     http://images.amazon.com/images/P/$1.01._SCMZZZZZZZ_.jpg [P,L]
27 RewriteRule /opac/extras/jacket/large/(.*) \
28     http://images.amazon.com/images/P/$1.01._SCLZZZZZZZ_.jpg [P,L]
29
30
31
32 # ----------------------------------------------------------------------------------
33 # Added content plugin
34 # ----------------------------------------------------------------------------------
35 <Location /opac/extras/ac/>
36     SetHandler perl-script
37     PerlHandler OpenILS::WWW::AddedContent
38     Options +ExecCGI
39     PerlSendHeader On
40     allow from all
41 </Location>
42
43         
44 # ----------------------------------------------------------------------------------
45 # Configure the OPAC
46 # ----------------------------------------------------------------------------------
47 <LocationMatch /opac/>
48     AddType application/xhtml+xml .xml
49    
50     # - configure mod_xmlent
51     XMLEntStripPI "yes"
52     XMLEntEscapeScript "no"
53     XMLEntStripComments "yes"
54     XMLEntContentType "text/html; charset=utf-8"
55     # forces quirks mode which we want for now
56     XMLEntStripDoctype "yes" 
57
58     # - set up the include handlers
59     Options +Includes
60     AddOutputFilter INCLUDES .xsl
61     AddOutputFilter INCLUDES;XMLENT .xml
62                     
63     # add languages as necessary
64     SetEnvIf Request_URI "/en-US/" locale=en-US
65     SetEnvIf Request_URI "/fr/" locale=fr
66     SetEnvIf Request_URI ".*" OILS_OPAC_BASE=/opac/
67 </LocationMatch>
68
69
70 # ----------------------------------------------------------------------------------
71 # Force SSL on the OPAC's "My Account" page
72 # ----------------------------------------------------------------------------------
73 <LocationMatch .*/myopac.xml>
74     SSLRequireSSL
75 </LocationMatch>
76
77 <LocationMatch /opac/extras/>
78     AddType application/xhtml+xml .xml
79 </LocationMatch>
80
81 <LocationMatch /opac/extras/slimpac/>
82     AddOutputFilter INCLUDES .html
83 </LocationMatch>
84         
85 # ----------------------------------------------------------------------------------
86 # Run server-side XUL through xmlent to load the correct XML entities
87 # ----------------------------------------------------------------------------------
88 <LocationMatch /xul/.*\.xul$>
89     Options +Includes
90     XMLEntContentType "application/vnd.mozilla.xul+xml"
91     AddOutputFilter INCLUDES;XMLENT .xul
92     allow from all
93 </LocationMatch>
94
95 # ----------------------------------------------------------------------------------
96 # Supercat feeds
97 # ----------------------------------------------------------------------------------
98 <Location /opac/extras/oisbn>
99     SetHandler perl-script
100     PerlHandler OpenILS::WWW::SuperCat::oisbn
101     Options +ExecCGI
102     PerlSendHeader On
103     allow from all
104 </Location>
105 <Location /opac/extras/supercat>
106     SetHandler perl-script
107     PerlHandler OpenILS::WWW::SuperCat::supercat
108     Options +ExecCGI
109     PerlSendHeader On
110     allow from all
111 </Location>
112 <Location /opac/extras/unapi>
113     SetHandler perl-script
114     PerlHandler OpenILS::WWW::SuperCat::unapi
115     Options +ExecCGI
116     PerlSendHeader On
117     allow from all
118 </Location>
119 <Location /opac/extras/feed/bookbag>
120     SetHandler perl-script
121     PerlHandler OpenILS::WWW::SuperCat::bookbag_feed
122     Options +ExecCGI
123     PerlSendHeader On
124     allow from all
125 </Location>
126 <Location /opac/extras/opensearch>
127     SetHandler perl-script
128     PerlHandler OpenILS::WWW::SuperCat::opensearch_feed
129     Options +ExecCGI
130     PerlSendHeader On
131     allow from all
132 </Location>
133 <Location /opac/extras/feed/freshmeat>
134     SetHandler perl-script
135     PerlHandler OpenILS::WWW::SuperCat::changes_feed
136     Options +ExecCGI
137     PerlSendHeader On
138     allow from all
139 </Location>
140 <Location /opac/extras/browse>
141     SetHandler perl-script
142     PerlHandler OpenILS::WWW::SuperCat::string_browse
143     Options +ExecCGI
144     PerlSendHeader On
145     allow from all
146 </Location>     
147         
148 # ----------------------------------------------------------------------------------
149 # Module for processing staff-client offline scripts lives here
150 # ----------------------------------------------------------------------------------
151 <Directory "/openils/var/cgi-bin/offline">
152     AddHandler cgi-script .pl
153     AllowOverride None
154     Options +ExecCGI
155     allow from all
156 </Directory>
157         
158         
159 # ----------------------------------------------------------------------------------
160 # OpenSRF JSON gateway
161 # ----------------------------------------------------------------------------------
162 <Location /gateway>
163     SetHandler osrf_json_gateway_module
164     allow from all
165 </Location>
166
167         
168 # ----------------------------------------------------------------------------------
169 # Reporting output lives here
170 # ----------------------------------------------------------------------------------
171 <Location /reporter/>
172     SetHandler perl-script
173     PerlHandler OpenILS::Reporter::Proxy
174     Options +ExecCGI
175     PerlSendHeader On
176     allow from all
177 </Location>
178
179 # ----------------------------------------------------------------------------------
180 # Reports GUI
181 # ----------------------------------------------------------------------------------
182 <LocationMatch /reports/>
183     Options +Includes
184     AddOutputFilter INCLUDES .xhtml
185 </LocationMatch>
186
187 # ----------------------------------------------------------------------------------
188 # XML-RPC gateway
189 # ----------------------------------------------------------------------------------
190 <Location /xml-rpc>
191     SetHandler perl-script
192     PerlHandler OpenILS::WWW::XMLRPCGateway
193     Options +ExecCGI
194     PerlSendHeader On
195     allow from all
196 </Location>
197
198
199 # ----------------------------------------------------------------------------------
200 # Django admin interface (experimental)
201 #  - requires mod_python and django
202 #  - requires a symlink from WEBROOT/media to 
203 #  /usr/lib/python2.4/site-packages/django/contrib/admin/media/ (or similar)
204 # ----------------------------------------------------------------------------------
205 #<Location /ils_setup/>
206 #   Order deny,allow
207 #   Deny from all
208 #   Allow from 10.0.0.0/8
209 #   SetHandler mod_python
210 #   PythonHandler django.core.handlers.modpython
211 #   SetEnv DJANGO_SETTINGS_MODULE ils_admin.settings
212 #   PythonDebug On
213 #   PythonPath "['/openils/var/admin/', '/usr/lib/python2.4/site-packages/'] +sys.path"
214 #   PythonAutoReload On
215 #</Location>
216
217