ansible-playbook playbook_debug.yml --list-hosts
see https://docs.ansible.com/ansible/latest/inventory_guide/intro_patterns.html
in this example only hosts are affected who match the regex: f\d.*-imap00\d
. this is usefull if you use import_playbook to import the playbook playbook_debug.yml
ansible-playbook playbook_debug.yml -e hosts=":&~f\d.*-imap00\d$" --list-hosts
good to know that the playbooks also works the standard way
ansible-playbook playbook_debug.yml -l '~f3mb-imap' --list-hosts