X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/ae60b2a3949e96357477cc04f90fd0873cee8a92..37e0abac697f5dee3c1301eb3b6f94de7a3104fb:/fabfile.py diff --git a/fabfile.py b/fabfile.py index a9e621d78..ff9a4b4f8 100644 --- a/fabfile.py +++ b/fabfile.py @@ -10,19 +10,6 @@ except ImportError: env.project_name = 'wolnelektury' -@task -def production(): - env.hosts = ['giewont.icm.edu.pl'] - env.user = 'lektury' - env.app_path = '/srv/wolnelektury.pl' - env.django_root_path = 'src' - env.requirements_file = 'requirements/requirements.txt' - env.services = [ - Supervisord('wolnelektury'), - Supervisord('wolnelektury.celery'), - ] - - def update_counters(): print '>>> updating counters' require('app_path', 'project_name') @@ -37,6 +24,23 @@ def compile_messages(): run('source %(ve)s/bin/activate && python manage.py localepack -c' % env, pty=True) +@task +def production(): + env.hosts = ['giewont.icm.edu.pl'] + env.user = 'lektury' + env.app_path = '/srv/wolnelektury.pl' + env.django_root_path = 'src' + env.requirements_file = 'requirements/requirements.txt' + env.pre_collectstatic = [ + update_counters, + compile_messages, + ] + env.services = [ + Supervisord('wolnelektury'), + Supervisord('wolnelektury.celery'), + ] + + @task def beta(): env.hosts = ['giewont.icm.edu.pl']