79684937

Date: 2025-06-30 14:53:06
Score: 1.5
Natty:
Report link

Solution is:

Example:

compose:
  tags: tags

groups:
  tag_Role_monitoring: >
    'prometheus' in (tags.get('ansible-tag-role', '') | split(',') | map('trim')) ...

I guess Ill leave off with a rant/comment to the Ansible developer community: why not name it 'expose' instead of 'compose' but more importantly why make tags available to keyed_groups, but not groups by default?!

Reasons:
  • Whitelisted phrase (-1): Solution is
  • Has code block (-0.5):
  • Ends in question mark (2):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: New2Python