{"action":"opened","issue":{"url":"https://api.github.com/repos/debops/debops-playbooks/issues/288","repository_url":"https://api.github.com/repos/debops/debops-playbooks","labels_url":"https://api.github.com/repos/debops/debops-playbooks/issues/288/labels{/name}","comments_url":"https://api.github.com/repos/debops/debops-playbooks/issues/288/comments","events_url":"https://api.github.com/repos/debops/debops-playbooks/issues/288/events","html_url":"https://github.com/debops/debops-playbooks/issues/288","id":167981397,"number":288,"title":"Xenial doesn't come with Python2 installed","user":{"login":"carlalexander","id":654684,"avatar_url":"https://avatars.githubusercontent.com/u/654684?v=3","gravatar_id":"","url":"https://api.github.com/users/carlalexander","html_url":"https://github.com/carlalexander","followers_url":"https://api.github.com/users/carlalexander/followers","following_url":"https://api.github.com/users/carlalexander/following{/other_user}","gists_url":"https://api.github.com/users/carlalexander/gists{/gist_id}","starred_url":"https://api.github.com/users/carlalexander/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/carlalexander/subscriptions","organizations_url":"https://api.github.com/users/carlalexander/orgs","repos_url":"https://api.github.com/users/carlalexander/repos","events_url":"https://api.github.com/users/carlalexander/events{/privacy}","received_events_url":"https://api.github.com/users/carlalexander/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-07-27T23:38:14Z","updated_at":"2016-07-27T23:38:14Z","closed_at":null,"body":"Easy to test with `debops-task fqdn -m setup`. You get this output:\r\n\r\n```console\r\nfqdn | FAILED! => {\r\n    \"changed\": false,\r\n    \"failed\": true,\r\n    \"module_stderr\": \"\",\r\n    \"module_stdout\": \"/bin/sh: 1: /usr/bin/python: not found\\r\\n\",\r\n    \"msg\": \"MODULE FAILURE\",\r\n    \"parsed\": false\r\n}\r\n```\r\n\r\nThis seems to be an issue since 15.10, but since I've only used 14.04 until now I never encountered it. It's documented [here](http://stackoverflow.com/questions/32429259/ansible-fails-with-bin-sh-1-usr-bin-python-not-found). Have you encountered this with Debian yet?\r\n\r\nFor now, I had to run `debops-task fqdn -m raw -a \"apt-get -y install python2.7\"` before using DebOps. I also needed to add this variable to the host variables based on information found [here](http://blog.swwomm.com/2016/04/xenial-ansible.html):\r\n\r\n```yml\r\nansible_python_interpreter: /usr/bin/python2.7\r\n```\r\n\r\nI'm not quite sure what to change in the playbooks to fix this. Seems we'd need a step with a `pre_task` to ensure that python2 is installed. Maybe in the core playbook? The `ansible_python_interpreter` variable is harder since you need to set this before you get any information from the host."}}
{"actor":{"display_login":"carlalexander"}}