Is it possible to auto create a host group based on manually defined host variables?
This is my inventory:
[webserver]
web1 ansible_host=192.168.20.1 production=False
web2 ansible_host=192.168.20.2 production=False
web3 ansible_host=192.168.20.3 production=True
web4 ansible_host=192.168.20.4 production=True
...
I want to have a dynamic hostgroup, e.g., webserver_production
and use this as target.
Is there another way to do archive this? Thank you.