Browse Source

Atualização de forma de deploy

stable/1.0
Sesostris Vieira 12 years ago
parent
commit
ffc824312d
  1. 4
      etc/apache/django.wsgi
  2. 12
      etc/apache/sites-available/sigi.erb

4
etc/apache/django.wsgi

@ -2,8 +2,8 @@
# -*- mode: python -*- # -*- mode: python -*-
import os, sys import os, sys
sys.path.insert(0, '/var/aplicacoes/django/sigi') sys.path.insert(0, '/var/interlegis/sigi')
sys.path.insert(0, '/var/aplicacoes/django/sigi/sigi') sys.path.insert(0, '/var/interlegis/sigi/sigi')
os.environ['DJANGO_SETTINGS_MODULE'] = 'sigi.settings' os.environ['DJANGO_SETTINGS_MODULE'] = 'sigi.settings'
from django.core.management.validation import get_validation_errors from django.core.management.validation import get_validation_errors

12
etc/apache/sites-available/sigi.erb

@ -1,12 +1,12 @@
NameVirtualHost 10.1.2.48:80 NameVirtualHost 10.1.2.48:80
<VirtualHost 10.1.2.48:80> <VirtualHost 10.1.2.48:80>
ServerName sigi.interlegis.gov.br ServerName sigi.interlegis.leg.br
Redirect / https://intranet.interlegis.gov.br/sigi Redirect / https://intranet.interlegis.leg.br/sigi
WSGIScriptAlias /sigi /var/aplicacoes/django/SIGI/etc/apache/django.wsgi WSGIScriptAlias /sigi /var/interlegis/sigi/etc/apache/django.wsgi
Alias /sigi/media /var/aplicacoes/django/SIGI/media/ Alias /sigi/media /var/interlegis/django/sigi/media/
Alias /sigi/admin_media /usr/local/lib/python2.4/site-packages/django/contrib/admin/media/ Alias /sigi/admin_media /usr/local/lib/python2.7/dist-packages/django/contrib/admin/media/
ErrorLog /var/log/apache2/sigi-error.log ErrorLog /var/log/apache2/sigi-error.log
@ -16,4 +16,4 @@ NameVirtualHost 10.1.2.48:80
CustomLog /var/log/apache2/sigi-access.log combined CustomLog /var/log/apache2/sigi-access.log combined
ServerSignature Off ServerSignature Off
</VirtualHost> </VirtualHost>
Loading…
Cancel
Save