From e002161e6c6a9a1d965d61bb709cacc6402a0415 Mon Sep 17 00:00:00 2001 From: Graham Ullrich Date: Sat, 23 Jan 2016 12:20:18 -0700 Subject: [PATCH] Update django_manage documentation As of Ansible 2.x, invocation of Django's ```manage.py``` requires a valid "shebang". Additionally, ```manage.py``` must be executable. The old invocation was hardcoded as ```python manage.py ...``` while the new invocation is ```./manage.py ...```. See [this PR](https://github.com/ansible/ansible-modules-core/pull/1165). This change allows more flexibility for which Python interpreter is invoked, but breaks existing deployment when ```manage.py``` is not properly configured. This documentation update adds a note explaining the new requirements for ```manage.py```. --- web_infrastructure/django_manage.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/web_infrastructure/django_manage.py b/web_infrastructure/django_manage.py index 660f55fd9f0..a8485bd8e20 100644 --- a/web_infrastructure/django_manage.py +++ b/web_infrastructure/django_manage.py @@ -90,8 +90,9 @@ notes: - I(virtualenv) (U(http://www.virtualenv.org)) must be installed on the remote host if the virtualenv parameter is specified. - This module will create a virtualenv if the virtualenv parameter is specified and a virtualenv does not already exist at the given location. - This module assumes English error messages for the 'createcachetable' command to detect table existence, unfortunately. - - To be able to use the migrate command with django versions < 1.7, you must have south installed and added as an app in your settings - - To be able to use the collectstatic command, you must have enabled staticfiles in your settings + - To be able to use the migrate command with django versions < 1.7, you must have south installed and added as an app in your settings. + - To be able to use the collectstatic command, you must have enabled staticfiles in your settings. + - As of ansible 2.x, your I(manage.py) application must be executable (rwxr-xr-x), and must have a valid I(shebang), i.e. "#!/usr/bin/env python", for invoking the appropriate Python interpreter. requirements: [ "virtualenv", "django" ] author: "Scott Anderson (@tastychutney)" '''