X-Git-Url: https://git.mdrn.pl/fnpdjango.git/blobdiff_plain/b0651e9336adcddedfcb2c9fd9025c7d565c685f..e72e716a3a7088b07e5b2f3af87fe5a18adfbb64:/fnpdjango/deploy/__init__.py?ds=sidebyside diff --git a/fnpdjango/deploy/__init__.py b/fnpdjango/deploy/__init__.py index 6edaebc..f47790d 100644 --- a/fnpdjango/deploy/__init__.py +++ b/fnpdjango/deploy/__init__.py @@ -73,6 +73,7 @@ def deploy(): install_requirements() symlink_current_release() migrate() + pre_collectstatic() collectstatic() restart() @@ -237,6 +238,11 @@ def migrate(): run('%(app_path)s/ve/bin/python manage.py syncdb --noinput' % env, pty=True) run('%(app_path)s/ve/bin/python manage.py migrate' % env, pty=True) +def pre_collectstatic(): + print '>>> pre_collectstatic' + for task in env.get('pre_collectstatic', []): + execute(task) + def collectstatic(): """Collect static files""" print '>>> collectstatic'