]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/examples/apache/eg_vhost.conf
Merge branch 'master' of git.evergreen-ils.org:Evergreen into template-toolkit-opac
[working/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 # Point / to the opac - if you have a custom skin or locale, point at it here
8 # ----------------------------------------------------------------------------------
9 RedirectMatch 301 ^/$ /opac/en-US/skin/default/xml/index.xml
10
11 # ----------------------------------------------------------------------------------
12 # Point / to the IP address redirector
13 # ----------------------------------------------------------------------------------
14 #<LocationMatch ^/$>
15 #    SetHandler perl-script
16 #    PerlHandler OpenILS::WWW::Redirect
17 #    Options +ExecCGI
18 #    PerlSendHeader On
19 #    #PerlSetVar OILSRedirectSkin "default"
20 #    # OILSRedirectDepth defaults to the depth of the branch that the OPAC was directed to
21 #    #PerlSetVar OILSRedirectDepth "0"
22 #    #PerlSetVar OILSRedirectLocale "en-US"
23 #    allow from all
24 #</LocationMatch>
25
26
27 # ----------------------------------------------------------------------------------
28 # Assign a default locale to the accessible OPAC
29 # ----------------------------------------------------------------------------------
30 RedirectMatch 301 ^/opac/extras/slimpac/start.html$    /opac/en-US/extras/slimpac/start.html
31 RedirectMatch 301 ^/opac/extras/slimpac/advanced.html$ /opac/en-US/extras/slimpac/advanced.html
32
33 # ----------------------------------------------------------------------------------
34 # Configure the gateway
35 # ----------------------------------------------------------------------------------
36 OSRFGatewayConfig /openils/conf/opensrf_core.xml
37 # Translator memcache server.  Default is localhost
38 # OSRFTranslatorCacheServer 127.0.0.1:11211
39
40
41 # ----------------------------------------------------------------------------------
42 # Added content plugin
43 # ----------------------------------------------------------------------------------
44 <Location /opac/extras/ac/>
45     SetHandler perl-script
46     PerlHandler OpenILS::WWW::AddedContent
47     Options +ExecCGI
48     PerlSendHeader On
49     allow from all
50 </Location>
51
52 # ----------------------------------------------------------------------------------
53 # Replace broken cover images with a transparent GIF by default
54 # ----------------------------------------------------------------------------------
55 RewriteEngine ON
56 RewriteRule ^/opac/extras/ac/jacket/(small|medium|large)/$ \
57     /opac/images/blank.png [P,L]
58
59 # ----------------------------------------------------------------------------------
60 # Add the row ID (RID) and date so we can make unAPI happy
61 # ----------------------------------------------------------------------------------
62 RewriteCond %{QUERY_STRING} (^r|&r)=(\d+)
63 RewriteRule . - [E=OILS_OPAC_RID:%2,E=OILS_TIME_YEAR:%{TIME_YEAR}]
64
65 # ----------------------------------------------------------------------------------
66 # Pull the locale from the URL
67 # ----------------------------------------------------------------------------------
68 RewriteCond %{REQUEST_URI} ^/opac/(.*?)/
69 RewriteRule . - [E=locale:%1]
70
71 # ----------------------------------------------------------------------------------
72 # Configure the OPAC
73 # ----------------------------------------------------------------------------------
74 <LocationMatch /opac/>
75     AddType application/xhtml+xml .xml
76    
77     # - configure mod_xmlent
78     XMLEntStripPI "yes"
79     XMLEntEscapeScript "no"
80     XMLEntStripComments "yes"
81     XMLEntContentType "text/html; charset=utf-8"
82     # forces quirks mode which we want for now
83     XMLEntStripDoctype "yes" 
84
85     # - set up the include handlers
86     Options +Includes
87     AddOutputFilter INCLUDES .xsl
88     AddOutputFilter INCLUDES;XMLENT .xml
89                     
90     SetEnvIf Request_URI ".*" OILS_OPAC_BASE=/opac/
91     
92     # This gives you the option to configure a different host to serve OPAC images from
93     # Specify the hostname (without protocol) and path to the images.  Protocol will
94     # be determined at runtime
95     #SetEnvIf Request_URI ".*" OILS_OPAC_IMAGES_HOST=static.example.org/opac/
96
97     # In addition to loading images from a static host, you can also load CSS and/or
98     # Javascript from a static host or hosts. Protocol will be determined at runtime
99     # and/or by configuration options immediately following.
100     #SetEnvIf Request_URI ".*" OILS_OPAC_CSS_HOST=static.example.org/opac/
101     #SetEnvIf Request_URI ".*" OILS_OPAC_JS_HOST=static.example.org/opac/
102
103     # If you are not able to serve static content via https and 
104     # wish to force http:// (and are comfortable with mixed-content
105     # warnings in client browsers), set this:
106     #SetEnvIf Request_URI ".*" OILS_OPAC_STATIC_PROTOCOL=http
107
108     # If you would prefer to fall back to your non-static servers for 
109     # https pages, avoiding mixed-content warnings in client browsers
110     # and are willing to accept some increased server load, set this:
111     #SetEnvIf Request_URI ".*" OILS_OPAC_BYPASS_STATIC_FOR_HTTPS=yes
112
113     # Specify a ChiliFresh account to integrate their services with the OPAC
114     #SetEnv OILS_CHILIFRESH_ACCOUNT
115     #SetEnv OILS_CHILIFRESH_PROFILE
116     #SetEnv OILS_CHILIFRESH_URL http://chilifresh.com/on-site/js/evergreen.js
117     #SetEnv OILS_CHILIFRESH_HTTPS_URL https://secure.chilifresh.com/on-site/js/evergreen.js
118
119     # Specify the initial script URL for Novelist (containing account credentials, etc.)
120     #SetEnv OILS_NOVELIST_URL
121     
122
123     # Uncomment to force SSL any time a patron is logged in.  This protects 
124     # authentication tokens.  Left commented out for backwards compat for now.
125     #SetEnv OILS_OPAC_FORCE_LOGIN_SSL 1
126
127
128     # If set, the skin uses the combined JS file at $SKINDIR/js/combined.js
129     #SetEnv OILS_OPAC_COMBINED_JS 1
130
131 </LocationMatch>
132
133 <Location /opac/>
134     # ----------------------------------------------------------------------------------
135     # Some mod_deflate fun
136     # ----------------------------------------------------------------------------------
137     <IfModule mod_deflate.c>
138         SetOutputFilter DEFLATE
139
140         BrowserMatch ^Mozilla/4 gzip-only-text/html
141         BrowserMatch ^Mozilla/4\.0[678] no-gzip
142         BrowserMatch \bMSI[E] !no-gzip !gzip-only-text/html
143
144         SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
145
146         <IfModule mod_headers.c>
147             Header append Vary User-Agent env=!dont-vary
148         </IfModule>
149     </IfModule>
150
151 </Location>
152
153 <Location //opac/>
154     # ----------------------------------------------------------------------------------
155     # Some mod_deflate fun
156     # ----------------------------------------------------------------------------------
157     <IfModule mod_deflate.c>
158         SetOutputFilter DEFLATE
159
160         BrowserMatch ^Mozilla/4 gzip-only-text/html
161         BrowserMatch ^Mozilla/4\.0[678] no-gzip
162         BrowserMatch \bMSI[E] !no-gzip !gzip-only-text/html
163
164         SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
165
166         <IfModule mod_headers.c>
167             Header append Vary User-Agent env=!dont-vary
168         </IfModule>
169     </IfModule>
170
171 </Location>
172
173 # ----------------------------------------------------------------------------------
174 # Force SSL on the OPAC's "My Account" page
175 # ----------------------------------------------------------------------------------
176 <LocationMatch .*/myopac.xml>
177     SSLRequireSSL
178 </LocationMatch>
179
180 <LocationMatch /opac/extras/>
181     # Force to en-US for now to satisfy bbags.xml
182     SetEnv locale en-US
183     Options +Includes
184     AddOutputFilter INCLUDES .xml
185     AddType application/xhtml+xml .xml
186 </LocationMatch>
187
188 RewriteCond %{QUERY_STRING} locale=([^&]*)
189 RewriteRule ^/opac/[a-z]{2}-[A-Z]{2}/extras/slimpac/(.*)$ /opac/%1/extras/slimpac/$1? [redirect]
190 <LocationMatch /opac/[a-z]{2}-[A-Z]{2}/extras/slimpac/>
191     AddOutputFilter INCLUDES;XMLENT .html
192 </LocationMatch>
193
194 # ----------------------------------------------------------------------------------
195 # Run server-side XUL and XHTML through xmlent to load the correct XML entities
196 # ----------------------------------------------------------------------------------
197 RewriteCond %{HTTP:Accept-Language} ([a-z]{2}-[A-Z]{2})
198 RewriteRule ^/xul/      -       [E=locale:%1]
199 RewriteRule ^/reports/  -       [E=locale:%1]
200
201 # Default to en-US if we haven't matched a locale of the form xx-YY 
202 RewriteCond %{HTTP:Accept-Language} !([a-z]{2}-[A-Z]{2})
203 RewriteRule ^/xul/      -       [E=locale:en-US]
204 RewriteRule ^/reports/  -       [E=locale:en-US]
205
206 # Default to en-US if we are just given en
207 RewriteCond %{ENV:locale} ^$ [OR]
208 RewriteCond %{ENV:locale} ^en$
209 RewriteRule . - [E=locale:en-US]
210
211 <LocationMatch /xul/.*\.x?html$>
212     Options +Includes
213     XMLEntEscapeScript "no"
214     XMLEntStripComments "yes"
215     XMLEntStripPI "yes"
216     XMLEntStripDoctype "yes"
217     XMLEntContentType "text/html; charset=utf-8"
218     AddOutputFilter INCLUDES;XMLENT .xhtml
219     AddOutputFilter INCLUDES;XMLENT .html
220     allow from all
221 </LocationMatch>
222
223
224 <LocationMatch /xul/.*\.xul$>
225     Options +Includes
226     XMLEntContentType "application/vnd.mozilla.xul+xml"
227     AddOutputFilter INCLUDES;XMLENT .xul
228     allow from all
229 </LocationMatch>
230
231 # ----------------------------------------------------------------------------------
232 # Self-serve password interface
233 # ----------------------------------------------------------------------------------
234 <Location /opac/password>
235     SetHandler perl-script
236     PerlHandler OpenILS::WWW::PasswordReset::password_reset
237     Options +ExecCGI
238     PerlSendHeader On
239     allow from all
240
241     # Force clients to use HTTPS
242     RewriteCond %{HTTPS} !=on [NC]
243     RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [R,L]
244 </Location>
245
246 # ----------------------------------------------------------------------------------
247 # Supercat feeds
248 # ----------------------------------------------------------------------------------
249 <Location /opac/extras/oisbn>
250     SetHandler perl-script
251     PerlHandler OpenILS::WWW::SuperCat::oisbn
252     Options +ExecCGI
253     PerlSendHeader On
254     allow from all
255 </Location>
256 <Location /opac/extras/supercat>
257     SetHandler perl-script
258     PerlHandler OpenILS::WWW::SuperCat::supercat
259     Options +ExecCGI
260     PerlSendHeader On
261     allow from all
262 </Location>
263 <Location /opac/extras/unapi>
264     SetHandler perl-script
265     PerlHandler OpenILS::WWW::SuperCat::unapi
266     Options +ExecCGI
267     PerlSendHeader On
268     allow from all
269 </Location>
270 <Location /opac/extras/feed/bookbag>
271     SetHandler perl-script
272     PerlHandler OpenILS::WWW::SuperCat::bookbag_feed
273     Options +ExecCGI
274     PerlSendHeader On
275     allow from all
276 </Location>
277 <Location /opac/extras/opensearch>
278     SetHandler perl-script
279     PerlHandler OpenILS::WWW::SuperCat::opensearch_feed
280     Options +ExecCGI
281     PerlSendHeader On
282     allow from all
283 </Location>
284 <Location /opac/extras/sru>
285     SetHandler perl-script
286     PerlHandler OpenILS::WWW::SuperCat::sru_search
287     Options +ExecCGI
288     PerlSendHeader On
289     allow from all
290 </Location>
291 <Location /opac/extras/sru_auth>
292     SetHandler perl-script
293     PerlHandler OpenILS::WWW::SuperCat::sru_auth_search
294     Options +ExecCGI
295     PerlSendHeader On
296     allow from all
297 </Location>
298 <Location /opac/extras/feed/freshmeat>
299     SetHandler perl-script
300     PerlHandler OpenILS::WWW::SuperCat::changes_feed
301     Options +ExecCGI
302     PerlSendHeader On
303     allow from all
304 </Location>
305 <Location /opac/extras/browse>
306     SetHandler perl-script
307     PerlHandler OpenILS::WWW::SuperCat::string_browse
308     Options +ExecCGI
309     PerlSendHeader On
310     allow from all
311 </Location>     
312 <Location /opac/extras/startwith>
313     SetHandler perl-script
314     PerlHandler OpenILS::WWW::SuperCat::string_startwith
315     Options +ExecCGI
316     PerlSendHeader On
317     allow from all
318 </Location>     
319         
320 # ----------------------------------------------------------------------------------
321 # Module for displaying OpenSRF API documentation
322 # ----------------------------------------------------------------------------------
323 <Location /opac/extras/docgen.xsl>
324     AddOutputFilter INCLUDES .xsl
325 </Location>
326
327 # ----------------------------------------------------------------------------------
328 # Module for processing staff-client offline scripts lives here
329 # ----------------------------------------------------------------------------------
330 <Directory "/openils/var/cgi-bin/offline">
331     AddHandler cgi-script .pl
332     AllowOverride None
333     Options +ExecCGI
334     allow from all
335 </Directory>
336         
337         
338 # ----------------------------------------------------------------------------------
339 # XXX Note, it's important to explicitly set the JSON encoding style 
340 # (OSRFGatewayLegacyJSON), since the default encoding style will likely change 
341 # with OpenSRF 1.0
342 # ----------------------------------------------------------------------------------
343 # OpenSRF JSON legacy gateway
344 # ----------------------------------------------------------------------------------
345 <Location /gateway>
346     SetHandler osrf_json_gateway_module
347     OSRFGatewayLegacyJSON "true"
348     allow from all
349 </Location>
350 # ----------------------------------------------------------------------------------
351 # New-style OpenSRF JSON gateway
352 # ----------------------------------------------------------------------------------
353 <Location /osrf-gateway-v1>
354     SetHandler osrf_json_gateway_module
355     OSRFGatewayLegacyJSON "false"
356     allow from all
357 </Location>
358
359 # ----------------------------------------------------------------------------------
360 # OpenSRF-over-HTTP translator
361 # (http://open-ils.org/dokuwiki/doku.php?id=opensrf_over_http)
362 # ----------------------------------------------------------------------------------
363 <Location /osrf-http-translator>
364     SetHandler osrf_http_translator_module
365     allow from all
366 </Location>
367
368 # ----------------------------------------------------------------------------------
369 # The exporter lives here
370 # ----------------------------------------------------------------------------------
371 <Location /exporter>
372     SetHandler perl-script
373     PerlSetVar OILSProxyTitle "Exporter Login"
374     PerlSetVar OILSProxyDescription "Please log in with an authorized staff account to export records"
375     PerlSetVar OILSProxyPermissions "STAFF_LOGIN"
376     PerlHandler OpenILS::WWW::Proxy OpenILS::WWW::Exporter
377     Options +ExecCGI
378     PerlSendHeader On
379     allow from all
380 </Location>
381
382 <Location /opac/extras/merge_template>
383     SetHandler perl-script
384     PerlSetVar OILSProxyTitle "Batch Update Login"
385     PerlSetVar OILSProxyDescription "Please log in to update records in batch"
386     PerlSetVar OILSProxyPermissions "STAFF_LOGIN"
387     PerlHandler OpenILS::WWW::Proxy OpenILS::WWW::TemplateBatchBibUpdate
388     PerlSendHeader On
389     Options +ExecCGI
390     allow from all
391 </Location>
392
393 <Location /opac/extras/circ>
394     SetHandler perl-script
395     PerlSetVar OILSProxyTitle "Circ Extras Login"
396     PerlSetVar OILSProxyDescription "Please log in with an authorized staff account to export records"
397     PerlSetVar OILSProxyPermissions "STAFF_LOGIN"
398     PerlHandler OpenILS::WWW::Proxy
399     Options +ExecCGI
400     PerlSendHeader On
401     allow from all
402 </Location>
403
404 # ----------------------------------------------------------------------------------
405 # Reporting output lives here
406 # ----------------------------------------------------------------------------------
407 <Location /reporter/>
408     SetHandler perl-script
409     PerlSetVar OILSProxyTitle "Report Login"
410     PerlSetVar OILSProxyDescription "Please log in with an authorized staff account to view this report"
411     PerlSetVar OILSProxyPermissions "VIEW_REPORT_OUTPUT"
412     PerlHandler OpenILS::WWW::Proxy
413     Options +ExecCGI
414     PerlSendHeader On
415     allow from all
416 </Location>
417
418 # ----------------------------------------------------------------------------------
419 # Selfcheck interface
420 # ----------------------------------------------------------------------------------
421 <LocationMatch .*/selfcheck.xml>
422     SetHandler perl-script
423     PerlSetVar OILSProxyTitle "Self-check Login"
424     PerlSetVar OILSProxyDescription "Please log in with an authorized staff account to activate the self-check interface"
425     PerlSetVar OILSProxyPermissions "STAFF_LOGIN"
426     PerlHandler OpenILS::WWW::Proxy
427     Options +ExecCGI
428     PerlSendHeader On
429     allow from all
430 </LocationMatch>
431
432
433 # ----------------------------------------------------------------------------------
434 # Reports GUI
435 # ----------------------------------------------------------------------------------
436 <LocationMatch /reports>
437     Options +Includes
438     AddOutputFilter INCLUDES;XMLENT .xhtml
439 </LocationMatch>
440
441 <LocationMatch /reports/fm_IDL.xml>
442     IDLChunkStripPI "yes"
443     IDLChunkEscapeScript "no"
444     IDLChunkStripComments "yes"
445     IDLChunkStripDoctype "yes"
446     IDLChunkContentType "application/xml; charset=utf-8"
447     AddOutputFilter INCLUDES;IDLCHUNK .xml
448 </LocationMatch>
449
450 # ----------------------------------------------------------------------------------
451 # EDI Message viewer
452 # ----------------------------------------------------------------------------------
453 <Location /edi>
454     SetHandler perl-script
455     PerlHandler OpenILS::WWW::EDI
456     Options +ExecCGI
457     PerlSendHeader On
458     allow from all
459 </Location>     
460
461 # ----------------------------------------------------------------------------------
462 # XML-RPC gateway
463 # ----------------------------------------------------------------------------------
464 <Location /xml-rpc>
465     SetHandler perl-script
466     PerlHandler OpenILS::WWW::XMLRPCGateway
467     Options +ExecCGI
468     PerlSendHeader On
469     allow from all
470 </Location>
471
472 # ----------------------------------------------------------------------------------
473 # Conify - next-generation Evergreen administration interface
474 # ----------------------------------------------------------------------------------
475 RewriteRule ^/conify/([a-z]{2}-[A-Z]{2})/global/(.*)$ /conify/global/$2 [E=locale:$1,L]
476 <Location /conify>
477     Options +Includes
478     XMLEntStripPI "yes"
479     XMLEntEscapeScript "no"
480     XMLEntStripComments "no"
481     XMLEntContentType "text/html; charset=utf-8"
482     AddOutputFilter INCLUDES;XMLENT .html
483  
484     SetHandler perl-script
485     PerlSetVar OILSProxyTitle "Dojo Admin Login"
486     PerlSetVar OILSProxyDescription "Please log in with an authorized staff account to administer Evergreen"
487     PerlSetVar OILSProxyPermissions "STAFF_LOGIN"
488     PerlHandler OpenILS::WWW::Proxy
489     Options +ExecCGI
490     PerlSendHeader On
491     allow from all
492 </Location>
493
494 # ----------------------------------------------------------------------------------
495 # Vandelay importers / exporters (your Web interface to bibliographic travel)
496 # ----------------------------------------------------------------------------------
497 RedirectMatch 301 ^/vandelay/vandelay.xml(.*)$ /vandelay/en-US/vandelay.xml$1
498
499 RewriteRule ^/vandelay/([a-z]{2}-[A-Z]{2})/(.*)$ /vandelay/$2 [E=locale:$1]
500
501 <LocationMatch /vandelay.*xml>
502     XMLEntStripPI "yes"
503     XMLEntEscapeScript "no"
504     XMLEntStripComments "yes"
505     XMLEntContentType "text/html; charset=utf-8"
506     XMLEntStripDoctype "yes"
507     AddOutputFilter INCLUDES;XMLENT .xml
508         SetHandler perl-script
509         PerlSetVar OILSProxyTitle "Vandelay Login"
510         PerlSetVar OILSProxyDescription "Please log in with an authorized staff account to import MARC records"
511         PerlSetVar OILSProxyPermissions "IMPORT_MARC"
512         PerlHandler OpenILS::WWW::Proxy
513         Options +ExecCGI
514         PerlSendHeader On
515         allow from all
516 </LocationMatch>
517 <Location /vandelay-upload>
518     SetHandler perl-script
519     PerlHandler OpenILS::WWW::Vandelay::spool_marc
520     Options +ExecCGI
521     allow from all
522 </Location>
523
524 # OpenURL 0.1 searching based on OpenSearch
525 RewriteMap openurl prg:/openils/bin/openurl_map.pl
526 RewriteCond %{QUERY_STRING} (^.*$)
527 RewriteRule ^/openurl$ ${openurl:%1} [NE,PT]
528
529
530
531 # General Evergreen web template processor
532 <Location /eg>
533     SetHandler perl-script
534     PerlHandler OpenILS::WWW::EGWeb
535     Options +ExecCGI
536     PerlSendHeader On
537     allow from all
538     <IfModule mod_deflate.c>
539         SetOutputFilter DEFLATE
540         BrowserMatch ^Mozilla/4 gzip-only-text/html
541         BrowserMatch ^Mozilla/4\.0[678] no-gzip
542         BrowserMatch \bMSI[E] !no-gzip !gzip-only-text/html
543         SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
544         <IfModule mod_headers.c>
545             Header append Cache-Control "public"
546             Header append Vary User-Agent env=!dont-vary
547         </IfModule>
548     </IfModule>
549 </Location>
550 <LocationMatch ^/(images|css|js)/>
551     # should pick up the default expire time from eg.conf...
552     <IfModule mod_deflate.c>
553         SetOutputFilter DEFLATE
554         BrowserMatch ^Mozilla/4 gzip-only-text/html
555         BrowserMatch ^Mozilla/4\.0[678] no-gzip
556         BrowserMatch \bMSI[E] !no-gzip !gzip-only-text/html
557         SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
558         <IfModule mod_headers.c>
559             Header append Cache-Control "public"
560             Header append Vary User-Agent env=!dont-vary
561         </IfModule>
562     </IfModule>
563 </LocationMatch>
564 <Location /eg/opac>
565     PerlSetVar OILSWebContextLoader "OpenILS::WWW::EGCatLoader"
566     # Expire the HTML quickly since we're loading dynamic data for each page
567     ExpiresActive On
568     ExpiresByType text/html "access plus 5 seconds"
569 </Location>
570
571
572 # Note: the template processor will decline handling anything it does not
573 # have an explicit configuration for, which means it will fall back to 
574 # Apache to serve the file.  However, in the interest of speed, go ahead 
575 # and tell Apache to avoid asking OpenILS::WWW::EGWeb for static content.
576 # Add more exemptions as needed.
577 <LocationMatch ^/eg/.*(\.js|\.css|\.html|\.xhtml|\.xml|\.jpg|\.png|\.gif)$>
578     SetHandler None
579 </LocationMatch>
580
581 # ----------------------------------------------------------------------------------
582 # Some mod_deflate logging setup
583 # ----------------------------------------------------------------------------------
584 <IfModule mod_deflate.c>
585     DeflateFilterNote Input instream
586     DeflateFilterNote Output outstream
587     DeflateFilterNote Ratio ratio
588
589     LogFormat '"%r" %{outstream}n/%{instream}n (%{ratio}n%%)' deflate
590     CustomLog /var/log/apache2/deflate_log deflate
591 </IfModule>
592
593
594 <Location /IDL2js>
595
596     SetHandler perl-script
597     PerlHandler OpenILS::WWW::IDL2js
598     Options +ExecCGI
599     PerlSendHeader On
600     allow from all
601
602     <IfModule mod_headers.c>
603         Header append Cache-Control "public"
604     </IFModule>
605
606     <IfModule mod_deflate.c>
607         SetOutputFilter DEFLATE
608         BrowserMatch ^Mozilla/4 gzip-only-text/html
609         BrowserMatch ^Mozilla/4\.0[678] no-gzip
610         BrowserMatch \bMSI[E] !no-gzip !gzip-only-text/html
611         SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
612         <IfModule mod_headers.c>
613             Header append Vary User-Agent env=!dont-vary
614         </IfModule>
615     </IfModule>
616 </Location>