vhost_apache.conf 957 Bytes
Newer Older
1 2
# Configuration pour Django (03/12/2014)
# À adapter en fonction des besoins et de la config locale !
Nicolas G.'s avatar
Nicolas G. committed
3 4 5 6 7 8 9 10
# https://docs.djangoproject.com/fr/1.6/howto/deployment/wsgi/modwsgi/
# Avec le VHost en ++
<VirtualHost *:80>
ServerName django.localdomain

# Process à part pour chaque appli Django.
WSGIDaemonProcess firstjeudy display-name=%{GROUP} python-path=/var/www/firstjeudy
WSGIProcessGroup firstjeudy
11
WSGIPythonPath /var/www/firstjeudy:/chemin/vers/env/virtuel/lib/python2.7/site-packages
Nicolas G.'s avatar
Nicolas G. committed
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

WSGIScriptAlias / /var/www/firstjeudy/firstjeudy/wsgi.py

Alias /static /var/www/firstjeudy/static
Alias /static/admin/css /var/www/firstjeudy/admin/css

<Directory /var/www/firstjeudy/static>
Order deny,allow
Allow from all
</Directory>

<Directory /var/www/firstjeudy/admin>
Order deny,allow
Allow from all
</Directory>

<Directory /var/www/firstjeudy/firstjeudy>
	<Files wsgi.py>
		Order deny,allow
		Require all granted
	</Files>
</Directory>


</VirtualHost>