How do you always have a set of tasks run regardless of the tag being passed in on the command line?
I'm getting to the point where I have a 'core' playbook that must be run before any other playbook I have. This does specific things such as set specific facts based upon my local environments or OS distro that are to be used by all my later roles. However, when I use '-tags do_this' or '-tags do_that' tasks/roles executed in my core playbook are ignored because they aren't tagged with 'do_this' or 'do_that.' It doesn't seem reasonable (or scalable) to me to modify my core playbook and add every possible tag I can ever use, nor does it seem reasonable to force my fellow admins to always run Ansible with '-tags core,do_this' or '-tags core, do_that' when they only want a particular tag to be executed. It really feels to me that Ansible is missing some way to say 'this task/role/whatever REQUIRES this other code to be run as well'. It seems I'm not alone in this - there's some calls for similar functionality here: * https://github.com/ansible/ansible/issues/3157 * https://github.com/ansible/ansible/pull/7039 So what should I be doing here? Thx Chris. -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/BFD6B7398AEB474A9A28B39B9B5D00CB588B283D%40SRAexMBX05.sra.com. For more options, visit https://groups.google.com/d/optout.
