diff --git a/fabfile.py b/fabfile.py index c782aa1..98b4818 100644 --- a/fabfile.py +++ b/fabfile.py @@ -56,7 +56,7 @@ def deploy(): with virtualenv(): run('git pull') # Get source run('pip install -r requirements.txt') # install deps in virtualenv - run('python manage.py collectstatic --noinput') # Collect static + run('umask 002; python manage.py collectstatic --noinput') # Collect static run('python manage.py migrate') # Run DB migrations # Reload gunicorn diff --git a/mailadmin/api.py b/mailadmin/api.py index f3ee196..ace8d76 100644 --- a/mailadmin/api.py +++ b/mailadmin/api.py @@ -26,6 +26,8 @@ class DjangoPostfixDovecotAPI(object): json=json, headers=headers) + r.raise_for_status() + return r.json() def create_aliases(self, aliases): @@ -40,7 +42,6 @@ class DjangoPostfixDovecotAPI(object): 'domain__name': settings.NEUF_EMAIL_DOMAIN_NAME, 'source_regex': regex } - print params return self._api( 'GET', '/aliases/',