{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible/issues/15947","repository_url":"https://api.github.com/repos/ansible/ansible","labels_url":"https://api.github.com/repos/ansible/ansible/issues/15947/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible/issues/15947/comments","events_url":"https://api.github.com/repos/ansible/ansible/issues/15947/events","html_url":"https://github.com/ansible/ansible/issues/15947","id":156093601,"number":15947,"title":"Ansible not looking for modules in ./library alongside playbook","user":{"login":"LuisBL","id":694774,"avatar_url":"https://avatars.githubusercontent.com/u/694774?v=3","gravatar_id":"","url":"https://api.github.com/users/LuisBL","html_url":"https://github.com/LuisBL","followers_url":"https://api.github.com/users/LuisBL/followers","following_url":"https://api.github.com/users/LuisBL/following{/other_user}","gists_url":"https://api.github.com/users/LuisBL/gists{/gist_id}","starred_url":"https://api.github.com/users/LuisBL/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LuisBL/subscriptions","organizations_url":"https://api.github.com/users/LuisBL/orgs","repos_url":"https://api.github.com/users/LuisBL/repos","events_url":"https://api.github.com/users/LuisBL/events{/privacy}","received_events_url":"https://api.github.com/users/LuisBL/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ansible/ansible/labels/bug_report","name":"bug_report","color":"fbca04"},{"url":"https://api.github.com/repos/ansible/ansible/labels/needs_info","name":"needs_info","color":"eb6420"},{"url":"https://api.github.com/repos/ansible/ansible/labels/P2","name":"P2","color":"fad8c7"}],"state":"open","locked":false,"assignee":{"login":"jctanner","id":1869705,"avatar_url":"https://avatars.githubusercontent.com/u/1869705?v=3","gravatar_id":"","url":"https://api.github.com/users/jctanner","html_url":"https://github.com/jctanner","followers_url":"https://api.github.com/users/jctanner/followers","following_url":"https://api.github.com/users/jctanner/following{/other_user}","gists_url":"https://api.github.com/users/jctanner/gists{/gist_id}","starred_url":"https://api.github.com/users/jctanner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jctanner/subscriptions","organizations_url":"https://api.github.com/users/jctanner/orgs","repos_url":"https://api.github.com/users/jctanner/repos","events_url":"https://api.github.com/users/jctanner/events{/privacy}","received_events_url":"https://api.github.com/users/jctanner/received_events","type":"User","site_admin":false},"assignees":[{"login":"jctanner","id":1869705,"avatar_url":"https://avatars.githubusercontent.com/u/1869705?v=3","gravatar_id":"","url":"https://api.github.com/users/jctanner","html_url":"https://github.com/jctanner","followers_url":"https://api.github.com/users/jctanner/followers","following_url":"https://api.github.com/users/jctanner/following{/other_user}","gists_url":"https://api.github.com/users/jctanner/gists{/gist_id}","starred_url":"https://api.github.com/users/jctanner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jctanner/subscriptions","organizations_url":"https://api.github.com/users/jctanner/orgs","repos_url":"https://api.github.com/users/jctanner/repos","events_url":"https://api.github.com/users/jctanner/events{/privacy}","received_events_url":"https://api.github.com/users/jctanner/received_events","type":"User","site_admin":false}],"milestone":null,"comments":5,"created_at":"2016-05-21T09:46:02Z","updated_at":"2016-09-07T21:08:04Z","closed_at":null,"body":"##### ISSUE TYPE\r\n - Bug Report\r\n\r\n##### ANSIBLE VERSION\r\n```\r\n$ ansible --version\r\nansible 2.0.0.2\r\n  config file = /etc/ansible/ansible.cfg\r\n$\r\n```\r\n\r\n\r\n##### CONFIGURATION\r\n<!---\r\nMention any settings you have changed/added/removed in ansible.cfg\r\n(or using the ANSIBLE_* environment variables).\r\n-->\r\n I took care to remove all ansible.cfg/.ansible.cfg files excepted the one provide by ubuntu in /etc/ansible/ansible.cfg\r\n\r\n##### OS / ENVIRONMENT\r\n<!---\r\nMention the OS you are running Ansible from, and the OS you are\r\nmanaging, or say “N/A” for anything that is not platform-specific.\r\n-->\r\n```\r\n$ more /etc/lsb-release \r\nDISTRIB_ID=Ubuntu\r\nDISTRIB_RELEASE=16.04\r\nDISTRIB_CODENAME=xenial\r\nDISTRIB_DESCRIPTION=\"Ubuntu 16.04 LTS\"\r\n$\r\n```\r\n##### SUMMARY\r\nAnsible not looking for modules in ./library alongside playbook\r\n\r\n##### STEPS TO REPRODUCE\r\n<!---\r\nFor bugs, show exactly how to reproduce the problem.\r\nFor new features, show how the feature would be used.\r\n-->\r\nOn a fresh ubuntu ansible installation with a minimal \r\n    $ cd playbook   # my folder were the plabooks are\r\n    $ ansible-galaxy install -p library gaqzi.ssh-config \r\n\r\nWith this `main.yml`: \r\n```\r\n- name: Add site.xxx.net to .ssh/config\r\n  ssh_config: >\r\n    host=site.xxx.net hostname=site.xxx.net\r\n    identity_file=\"{{ home }}/.ssh/{{ ssh_profile }}\"\r\n    port=443 state=present user={{ user }} remote_user=xxx\r\n```\r\nI get this error (ssh_config: name not found)\r\n```\r\n$ vagrant provision\r\n==> vagrant: Running provisioner: ansible...\r\n    vagrant: Running ansible-playbook...\r\n    ERROR! no action detected in task\r\n\r\n    The error appears to have been in\r\n    '/home/me/playbook/roles/keys_install/tasks/main.yml':\r\n    line 14, column 3, but may\r\n    be elsewhere in the file depending on the exact syntax problem.\r\n\r\n    The offending line appears to be:\r\n\r\n    - name: Add git.caritat.net to .ssh/config\r\n        ^ here\r\n\r\nAnsible failed to complete successfully. Any error output should be\r\nvisible above. Please fix these errors and try again.\r\n$\r\n\r\n```\r\n\r\n##### EXPECTED RESULTS\r\nIn the ansible documentation [intro_configuration](http://docs.ansible.com/ansible/intro_configuration.html#library) it is said that:\r\n\r\n> Ansible ... it also will look for modules in the ”./library”\r\n>   directory alongside a playbook.\r\n\r\nI expect that:\r\n```\r\n$ cd playbook   # my folder were the plabooks are\r\n    $ ansible-galaxy install -p library gaqzi.ssh-config \r\n```\r\nwork because `./library` is a directory alongside the playbook.\r\n\r\nThere is this stackoverflow question related issue:\r\nhttp://stackoverflow.com/questions/37235848/ansible-not-looking-for-modules-in-library-alongside-playbook\r\n\r\n##### ACTUAL RESULTS\r\n\r\nIm my case the only way I get that the directive provide by `gaqzi.ssh-config` was seen by ansible was to explicitly export ANSIBLE_LIBRARY with a full path ;(\r\n\r\nWithout that `gaqzi.ssh-config` module is not found by ansible, regarding the documentation it should.\r\n\r\nHere what I have to do to make it work::\r\n\r\n```\r\n    $ cd playbook   # my folder were the plabooks are\r\n    $ ansible-galaxy install -p library gaqzi.ssh-config  # I get a lib\r\n    $ export ANSIBLE_LIBRARY=/home/me/full/path/to/the/above/playbook/library\r\n    $    # the export above is annoying\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/ansible/ansible/issues/comments/245419679","html_url":"https://github.com/ansible/ansible/issues/15947#issuecomment-245419679","issue_url":"https://api.github.com/repos/ansible/ansible/issues/15947","id":245419679,"user":{"login":"ansibot","id":6585283,"avatar_url":"https://avatars.githubusercontent.com/u/6585283?v=3","gravatar_id":"","url":"https://api.github.com/users/ansibot","html_url":"https://github.com/ansibot","followers_url":"https://api.github.com/users/ansibot/followers","following_url":"https://api.github.com/users/ansibot/following{/other_user}","gists_url":"https://api.github.com/users/ansibot/gists{/gist_id}","starred_url":"https://api.github.com/users/ansibot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ansibot/subscriptions","organizations_url":"https://api.github.com/users/ansibot/orgs","repos_url":"https://api.github.com/users/ansibot/repos","events_url":"https://api.github.com/users/ansibot/events{/privacy}","received_events_url":"https://api.github.com/users/ansibot/received_events","type":"User","site_admin":false},"created_at":"2016-09-07T21:08:04Z","updated_at":"2016-09-07T21:08:04Z","body":"@LuisBL closure has been requested for this issue or it has timed out waiting for your response.\n[click here for bot help](https://github.com/ansible/ansibullbot/blob/master/ISSUE_HELP.md)\n<!--- boilerplate: issue_closure --->"}}
{"actor":{"display_login":"ansibot"}}