Tags catch-all

I have some roles that always need to be run, whereas, others depend on tags. I’m specifying tags for my playbook:

ansible-playbook ansible/app.yml --tags=‘production,web’

My playbook:

roles:

  • { role: ruby193, tags: [“web”, “queue”, “mail”] }

  • { role: deployer, tags: [“web”, “queue”, “mail”] }

“web”, “queue”, and “mail” are ALL of the options, however, I’m finding that I’m doing this for a lot of roles just to catch everything. Worse, when a tag is added, i’d have to go through the whole playbook and add it to the array to make sure it runs.

Is there a way to specify that when you do specify tags, that the role should run for ANY tag?

I tried:

roles:

  • { role: common, tags: [“*”] }

But that obviously didn’t work.

Thanks.

This is the proposal for a magic tag called ‘all’, there is a open RFE on it I believe.

Would be a super easy contribution, hint, hint :slight_smile:

– Michael