This is a short quick tip about Ansible. TL;DR: it’s possible to use a wildcard in the target hosts specifier. This became useful to me when I dynamically created the inventory based on Ansible facts.
This is a short quick tip. When executing Ansible playbooks, you might need to execute a task as another user than the one you established the connection with. This post shows an example how to do it and deal with the environment variables.