]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/examples/apache_24/eg.conf
Stamping upgrade for #deleted search modifier (and friends) fix
[working/Evergreen.git] / Open-ILS / examples / apache_24 / eg.conf
1 # :vim set syntax apache
2
3 LogLevel info 
4 # - log locally
5 CustomLog /var/log/apache2/access.log combined
6 ErrorLog /var/log/apache2/error.log
7 # - log to syslog 
8 # CustomLog "|/usr/bin/logger -p local7.info" common
9 # ErrorLog  "|logger -p local7.error"
10
11
12 # ----------------------------------------------------------------------------------
13 # Set up Perl 
14 # ----------------------------------------------------------------------------------
15
16 # - needed by CGIs
17 PerlRequire /etc/apache2/startup.pl
18 PerlChildInitHandler OpenILS::WWW::Reporter::child_init
19 PerlChildInitHandler OpenILS::WWW::SuperCat::child_init
20 PerlChildInitHandler OpenILS::WWW::AddedContent::child_init
21 PerlChildInitHandler OpenILS::WWW::PasswordReset::child_init
22 PerlChildInitHandler OpenILS::WWW::AutoSuggest::child_init
23
24 # ----------------------------------------------------------------------------------
25 # Set some defaults for our working directories
26 # ----------------------------------------------------------------------------------
27 <Directory /openils/var/web>
28    Require all granted
29 </Directory>
30
31
32 # ----------------------------------------------------------------------------------
33 # XUL directory
34 # ----------------------------------------------------------------------------------
35 <Directory /openils/var/web/xul>
36    Options Indexes FollowSymLinks
37    AllowOverride None
38    Require all granted
39 </Directory>
40
41
42 # ----------------------------------------------------------------------------------
43 # Remove the language portion from the URL
44 # ----------------------------------------------------------------------------------
45 AliasMatch ^/opac/.*/skin/(.*)/(.*)/(.*) /openils/var/web/opac/skin/$1/$2/$3
46 AliasMatch ^/opac/.*/extras/slimpac/(.*) /openils/var/web/opac/extras/slimpac/$1
47 AliasMatch ^/opac/.*/extras/selfcheck/(.*) /openils/var/web/opac/extras/selfcheck/$1
48
49
50
51 # ----------------------------------------------------------------------------------
52 # System config CGI scripts go here
53 # ----------------------------------------------------------------------------------
54 Alias /cgi-bin/offline/ "/openils/var/cgi-bin/offline/"
55 <Directory "/openils/var/cgi-bin/offline">
56         AddHandler cgi-script .cgi .pl
57         AllowOverride None
58         Options None
59     Require host 10.0.0.0/8
60         Options FollowSymLinks ExecCGI Indexes
61 </Directory>
62
63
64 # ----------------------------------------------------------------------------------
65 # Updates folder
66 # ----------------------------------------------------------------------------------
67 Alias /updates/ "/openils/var/updates/pub/"
68 <Directory "/openils/var/updates/pub">
69         <Files check>
70                 ForceType cgi-script
71         </Files>
72         <Files update.rdf>
73                 ForceType cgi-script
74         </Files>
75         <Files manualupdate.html>
76                 ForceType cgi-script
77         </Files>
78         <Files download>
79                 ForceType cgi-script
80         </Files>
81         AllowOverride None
82         Options None
83         Options ExecCGI
84     Require all granted
85 </Directory>
86
87
88 # ----------------------------------------------------------------------------------
89 # OPTIONAL: Set how long the client will cache our content.  Change to suit
90 # ----------------------------------------------------------------------------------
91 ExpiresActive On
92 ExpiresDefault "access plus 1 month"
93 ExpiresByType text/html "access plus 18 hours"
94 ExpiresByType application/xhtml+xml "access plus 18 hours"
95 ExpiresByType application/x-javascript "access plus 18 hours"
96 ExpiresByType application/javascript "access plus 18 hours"
97 ExpiresByType text/css "access plus 50 minutes"
98
99 # ----------------------------------------------------------------------------------
100 # Set up our SSL virtual host
101 # ----------------------------------------------------------------------------------
102 #Listen 443
103 NameVirtualHost *:443
104 <VirtualHost *:443>
105         DocumentRoot "/openils/var/web"
106         ServerName localhost:443
107         ServerAlias 127.0.0.1:443
108         SSLEngine on
109         SSLHonorCipherOrder On
110         SSLCipherSuite ECDHE-RSA-AES256-SHA384:AES256-SHA256:RC4:HIGH:!MD5:!aNULL:!EDH:!AESGCM
111
112     # If you don't have an SSL cert, you can create self-signed 
113     # certificate and key with:
114     # openssl req -new -x509 -nodes -out server.crt -keyout server.key
115         SSLCertificateFile ssl/server.crt
116         SSLCertificateKeyFile ssl/server.key
117
118     # - absorb the shared virtual host settings
119     Include eg_vhost.conf
120
121     # help IE along with SSL pages
122     SetEnvIf User-Agent ".*MSIE [1-5].*" \
123         nokeepalive ssl-unclean-shutdown \
124         downgrade-1.0 force-response-1.0
125
126     SetEnvIf User-Agent ".*MSIE [6-9].*" \
127         ssl-unclean-shutdown
128
129 </VirtualHost>
130
131 # ----------------------------------------------------------------------------------
132 # Set up our main virtual host
133 # Port 80 comes after 443 to avoid "unknown protocol speaking not SSL to HTTPS port!?" 
134 # errors, per http://wiki.apache.org/httpd/InternalDummyConnection
135 # ----------------------------------------------------------------------------------
136
137 # Commented to avoid warnings from duplicate "NameVirtualHost: *80" directives
138 #NameVirtualHost *:80
139 <VirtualHost *:80>
140         ServerName localhost:80
141         ServerAlias 127.0.0.1:80
142         DocumentRoot /openils/var/web/
143         DirectoryIndex index.xml index.html index.xhtml
144     # - absorb the shared virtual host settings
145     Include eg_vhost.conf
146 </VirtualHost>
147