1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Added os.path.expanduser to app_path in django_manage

This commit is contained in:
Florian Apolloner 2015-03-29 21:34:29 +02:00 committed by Matt Clay
parent f07096bfe5
commit a925a075a6

View file

@ -232,8 +232,6 @@ def main():
if not module.params[param]:
module.fail_json(msg='%s param is required for command=%s' % (param, command))
venv = module.params['virtualenv']
_ensure_virtualenv(module)
cmd = "python manage.py %s" % (command, )
@ -254,7 +252,7 @@ def main():
if module.params[param]:
cmd = '%s %s' % (cmd, module.params[param])
rc, out, err = module.run_command(cmd, cwd=app_path)
rc, out, err = module.run_command(cmd, cwd=os.path.expanduser(app_path))
if rc != 0:
if command == 'createcachetable' and 'table' in err and 'already exists' in err:
out = 'Already exists.'