regarding inventory scripts

36 views
Skip to first unread message

Florin Andrei

unread,
Oct 15, 2014, 9:18:06 PM10/15/14
to ansible...@googlegroups.com
(New to Ansible, still figuring out things)

If I have several inventory scripts, is it possible to use them all at once, e.g. like this?

ansible -i ec2.py -i some-other-provider.py ...

Are there any guidelines or templates for writing your own inventory script?

What prompts these questions is the fact that I have instances in AWS (for which there is an inventory script already) and also some instances with another provider (that doesn't have an inventory script yet, so I'll have to write my own).

Serge van Ginderachter

unread,
Oct 16, 2014, 3:14:25 AM10/16/14
to ansible...@googlegroups.com

On 16 October 2014 03:18, Florin Andrei <florin...@gmail.com> wrote:
If I have several inventory scripts, is it possible to use them all at once, e.g. like this?

ansible -i ec2.py -i some-other-provider.py ...


​put both sript in a directory and pint -i .. to that directory​

Serge van Ginderachter

unread,
Oct 16, 2014, 3:14:58 AM10/16/14
to ansible...@googlegroups.com
On 16 October 2014 03:18, Florin Andrei <florin...@gmail.com> wrote:
If I have several inventory scripts, is it possible to use them all at once, e.g. like this?

ansible -i ec2.py -i some-other-provider.py ...


​put both scripts in a directory and pint -i .. to that directory​

there are example inventory scripts in the repository, and a tech description on the json format it should return, in the docs
Reply all
Reply to author
Forward
0 new messages