Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ch06 django_manage #5

Open
tylrd opened this issue Sep 10, 2015 · 3 comments
Open

ch06 django_manage #5

tylrd opened this issue Sep 10, 2015 · 3 comments

Comments

@tylrd
Copy link

tylrd commented Sep 10, 2015

Cloned ch06 playbook and ran the playbook and keep getting this output for the manage.py tasks.

failed: [web] => (item=syncdb) => {"cmd": "./manage.py syncdb --noinput", 
"failed": true, "item": "syncdb", "msg": "[Errno 13] Permission denied", "rc": 13}
failed: [web] => (item=migrate) => {"cmd": "./manage.py migrate --noinput", 
"failed": true, "item": "migrate", "msg": "[Errno 13] Permission denied", "rc": 13}
failed: [web] => (item=collectstatic) => {"cmd": "./manage.py collectstatic --noinput", 
"failed": true, "item": "collectstatic", "msg": "[Errno 13] Permission denied", "rc": 13}

I've gotten manage.py to run by vagrant ssh, making it executable with chmod +x manage.py and changing the #!/usr/bin/env on the top of the file to the virtual env. How to get around this with ansible?

@saschagottfried
Copy link

I succeeded running this playbook today using Ansible 1.9.3 without needing the modifications you mentioned.

(ansible-venv) $ ansible --version
ansible 1.9.3
  configured module search path = None

Python/Django virtual environment on the Vagrant machine

vagrant@vagrant-ubuntu-trusty-64:~/mezzanine-example$ bin/pip freeze
Django==1.6.11
Mezzanine==3.1.10
Pillow==2.9.0
South==1.0.2
argparse==1.2.1
beautifulsoup4==4.1.3
bleach==1.4.2
django-appconf==1.0.1
django-compressor==1.5
filebrowser-safe==0.4.0
future==0.9.0
grappelli-safe==0.4.1
gunicorn==19.3.0
html5lib==0.9999999
oauthlib==1.0.3
psycopg2==2.6.1
python-memcached==1.57
pytz==2015.6
requests==2.7.0
requests-oauthlib==0.5.0
setproctitle==1.1.9
six==1.9.0
tzlocal==1.0
wsgiref==0.1.2 

Please provide more information on your environment (control machine and remote machine)

@dbrgn
Copy link

dbrgn commented Apr 20, 2016

Might be related to ansible/ansible-modules-core#2856

@shiiaii
Copy link

shiiaii commented Aug 12, 2016

Does anybody solve this issue? I met the same issue now. Stucking.....

ansible --version
ansible 2.1.1.0
config file = /root/ansible/postgresql/ansible.cfg
configured module search path = Default w/o overrides
root@eshiaii-Z600:~/ansible/postgresql#

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants