Skip to content

Commit

Permalink
Merge pull request #28 from n0n0x/add-django-tasks
Browse files Browse the repository at this point in the history
Add django tasks
  • Loading branch information
n0n0x authored Dec 15, 2016
2 parents 9541388 + 4f6d56e commit fe6fe85
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions deployer/tasks/django.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from fabric.api import run
from fabric.decorators import with_settings

from fabtools import require
from fabtools.python import virtualenv

@with_settings(warn_only=True)
def collectstatic(app_name='', python_version=''):
with virtualenv('/home/deploy/.pyenv/versions/{0}-{1}'.format(app_name, python_version)):
run('python manage.py collectstatic -v0 --noinput')

0 comments on commit fe6fe85

Please sign in to comment.