ansible / proposals

Repository for sharing and tracking progress on enhancement proposals for Ansible.
Creative Commons Zero v1.0 Universal
92 stars 19 forks source link

more ways to set tags #204

Open dberardo-com opened 2 years ago

dberardo-com commented 2 years ago

currently the only two ways i know of to set tags for current runs are:

however i would like to have ways to define different tags combinations in better ways and so this could happen via:

dberardo-com commented 2 years ago

i add to the above points, that would also be nice to have a possibility to set tags dynamically, like a "set_tags" module

bcoca commented 2 years ago

the part about mergable configs is much bigger than tags and is already in a separate proposal

a set_tags module would be very hard to implement as the engine now filters tags before processing tasks, set_tag would happen after that and would require re-initializing the whole stack.

for most cases, when does a better job of task execution selection, to the point I have many times considered deprecating 'tags'.

dberardo-com commented 2 years ago

so you are suggesting using when instead of tags ?

bcoca commented 2 years ago

yes

dberardo-com commented 2 years ago

i see. i will wait for the config merging to be put in place and see if that would do the job, i find tagging quite neat, but let's see.