Couldn't you set what you needed as a host specific variable in your inventory file and simply call that variable in the appropriate place?
On Wed, Aug 22, 2018, 9:50 AM Brian Coca <[email protected]> wrote: > Plays are what map hosts to tasks, there are a couple of other ways > you can single out a host, but a Play is the optimal path to do this. > Having multiple plays in a playbook was always the original intention > (why its named playbook), but if you insist on avoiding an additional > play, here are a couple of options: > > - when: inventory_hostname == 'specific host' > or > - run_once: True, and make sure that host is always the first host in > the selection for the play. > > -- > You received this message because you are subscribed to the Google Groups > "Ansible Project" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ansible-project/CACVha7eQe%2BVoyFQyoM2KQNjNe%3DsxsqWvZBgv4njd8qvT54MDHw%40mail.gmail.com > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CAPounx3VbFFmtjXkz7osC%3DeKEH10w9M6hOLiyGHMqTh5dxQSHw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
