redirect apache/wsgi output flow to /var/log/apache2/myslice*
[myslice.git] / apache / myslice.conf
1 # xxx it might be smarter to install wsgi.py in some other location 
2 # so we don't have to hard-wire these paths here
3 # xxx it might also be helpful to set up a specific log channel for this
4 # e.g. in /var/log/myslice.log
5 <VirtualHost *:80>
6         WSGIDaemonProcess myslice processes=2 threads=25
7         WSGIProcessGroup myslice
8         CustomLog ${APACHE_LOG_DIR}/myslice-access.log common
9         ErrorLog ${APACHE_LOG_DIR}/myslice-error.log
10         WSGIScriptAlias / /usr/lib/python2.7/dist-packages/myslice/wsgi.py
11         <Directory /usr/share/unfold/myslice>
12         <Files wsgi.py>
13         Order deny,allow
14         Allow from all
15         </Files>
16         </Directory>
17         Alias /static/ /usr/share/unfold/static/
18         <Directory /usr/share/unfold/static>
19         Order deny,allow
20         Allow from all
21         </Directory>
22 </VirtualHost>
23
24 # This port (not necessarily well picked) is configured 
25 # with client-certificate required
26 # corresponding trusted roots (e.g. ple.gid and plc.gid) should be 
27 # configured in /etc/unfold/trusted_roots
28 # check Jordan's email and pointer to trac, although we do not want 
29 # this to be optional on that port
30
31 <VirtualHost *:443>
32         WSGIDaemonProcess myslice-ssl processes=2 threads=25
33         WSGIProcessGroup myslice-ssl
34         CustomLog ${APACHE_LOG_DIR}/myslice-ssl-access.log common
35         ErrorLog ${APACHE_LOG_DIR}/myslice-ssl-error.log
36         WSGIScriptAlias / /usr/lib/python2.7/dist-packages/myslice/wsgi.py
37         <Directory /usr/share/unfold/apache>
38         <Files myslice.wsgi>
39         Order deny,allow
40         Allow from all
41         </Files>
42         </Directory>
43         Alias /static/ /usr/share/unfold/static/
44         <Directory /usr/share/unfold/static>
45         Order deny,allow
46         Allow from all
47         </Directory>
48
49         SSLEngine on
50         SSLVerifyClient require
51         SSLVerifyDepth 5
52 # make this a symlink to /etc/sfa/trusted_roots if that makes sense in your env.
53         SSLCACertificatePath /etc/unfold/trusted_roots
54 # see init-ssl.sh for how to create self-signed stuff in here
55         SSLCertificateFile    /etc/unfold/myslice.cert
56         SSLCertificateKeyFile /etc/unfold/myslice.key
57
58 #       SSLOptions +StdEnvVars +ExportCertData
59         SSLOptions +StdEnvVars
60 </VirtualHost>