short summary: I have a playbook from where I wanna start other playbooks hosted on Bitbucket. In short words: Got a server and want to clone repository on Bitbucket where are all the other playbooks which I want to run on the remote server.
I was thinking of ansible-pull. I know Brian Coca that frequents this forum had a github or galaxy entry on the subject some time ago but I can’t seem to find it. But this is a good reference (or you can just do a ‘man ansible-pull’):
I’ll take a look. The weird thing is following: The remote server is cloning the files (checked it manually if they’re there) but with “include_tasks” or “import_playbook” I’m not able to execute the playbooks lying around there.
Yeah I have not tried to execute a playbook like that so I don’t have anything to offer there. I’ve done your exact scenerio though using ansible-pull to run a playbook from my BitBucket repo.
Ansible CANNOT read the files on the remote as part of the playbook,
you need to either check them out on the controller (git +
delegate_to: localhost) or 'fetch' them via the module with the same
name.
AWX will just checkout that repo onto the AWX machine and run Ansible
'locally' on those files, either way works