On Tue, 27 Jan 2015 17:24 -0800, Florin Andrei <
florin...@gmail.com>
wrote:
> I might be asking something obvious here, but anyway:
>
> I've a private repo on GitHub, with an account on a read-only team there. I would like to run ansible-pull in one step with that repo, but I can't seem to figure out how to tell ansible-pull to use the correct deploy key on GH. The git module in main ansible has options such as key_file (and accept_hostkey). There don't seem to be analogues for ansible-pull.
>
> A workaround would be to pull that repo some other way to localhost, then run ansible-playbook -c local. I don't particularly like that - for a variety of reasons (not all of a technical nature) I'm looking for a minimalist solution: install ansible, drop one key file on the host, and append one short line to cron.
If I understand how ansible-pull works, it will do the git checkout and
then call ansible-playbook.
You can try to specify private_key_file in ansible.cfg and see if
ansible-playbook picks it up.
Giovanni