Running an Ansible Playbook on a particular group

2019-02-05 13:01发布

问题:

I have the following /etc/ansible/hosts:

[ESNodes]
isk-vsrv643
isk-vsrv644
isk-vsrv645

[PerfSetup]
isk-dsrv613
isk-dsrv614

I know there is an option to run a playbook on particular hosts with -l Is there a way to run a playbook only on the PerfSetup group?

回答1:

Same way as you would do for hosts : -l PerfSetup