конфигурация mod_wsgi и django

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
NameVirtualHost *:80
<VirtualHost *:80>
ServerAdmin webmaster@jajaja
ServerName db.jajaja
ErrorLog logs/db.jajaja-error_log
LogLevel debug
CustomLog logs/db.jajaja-access_log combined
WSGIProcessGroup db1
WSGIDaemonProcess db1 processes=1 user=kron group=kron threads=5 maximum-requests=1000 home=/home/kron/hosts/db/links inactivity-timeout=300
WSGIScriptAlias / /home/kron/hosts/db/links/links.wsgi
WSGIScriptReloading On
WSGIReloadMechanism Process
Alias "/static/" "/home/kron/hosts/db/links/static/"
Alias "/media/" "/usr/lib/python2.5/site-packages/django/contrib/admin/media/"
<Location "/static/">
SetHandler None
</Location>
<Location "/media/">
SetHandler None
</Location>
<IfModule mod_expires.c>
<FilesMatch "\.(jpg|gif|png|css|js)$">
ExpiresActive on
ExpiresDefault "access plus 3 days"
</FilesMatch>
</IfModule>
</VirtualHost>