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 33 34 35 36 37 38 39 40 41 42 43 44
| NameVirtualHost 0.4.1.3 #(<= oui, c'est juste un exemple. L'hébergement ne permet pas le fonctionnement avec le classique *:80)
<VirtualHost 0.4.1.3>
ServerName test.site.com
ServerAdmin admin@exemple.com
Alias /static/ /home/user/projects/test/static/
Alias /media/ /home/user/projects/test/media/
WSGIDaemonProcess test python-path=/home/user/projects/test:/path/to/lib/python2.7/site-packages
WSGIProcessGroup test
WSGIScriptAlias / /home/user/projects/test/www/wsgi.py process-group=test
<Directory /home/user/projects/test/>
Order deny,allow
Allow from all
</Directory>
LogLevel warn
ErrorLog ${APACHE_LOG_DIR}/test_error.log
CustomLog ${APACHE_LOG_DIR}/test_access.log combined
</VirtualHost>
<VirtualHost 0.4.1.3>
ServerName site.com
ServerAlias site.com
ServerAdmin admin@exemple.com
Alias /static/ /home/user/projects/test/static/
Alias /media/ /home/user/projects/test/media/
WSGIDaemonProcess www python-path=/home/user/projects/www:/path/to/lib/python2.7/site-packages
WSGIProcessGroup www
WSGIScriptAlias / /home/user/projects/www/www/wsgi.py process-group=www
<Directory /home/user/projects/www/>
Order deny,allow
Allow from all
</Directory>
LogLevel warn
ErrorLog ${APACHE_LOG_DIR}/www_error.log
CustomLog ${APACHE_LOG_DIR}/www_access.log combined
</VirtualHost> |
Partager