I have a bit of a problem, and was wondering if anyone has ever done something like this. I have a playbook I am working on, where it updates firewalld rules for some kubernetes clusters we have. Rather than have a playbook per cluster, we elected to use tags, one for prod, one for nonprod, and one for beta.
What I am trying to do, is have task, that if it isn’t one of the three mentioned tags ( Prod, Non-Prod, Beta) then it executes, basically outputting a debug message that the only accepted tags are those three. Is there a way to say something like “If tags !=[Prod,Non-Prod,Beta] then output text”?
I was fairly sure that at some point I saw that there was a way to do that, and I can’t seem to find the example anymore so any help anyone can offer wold be greatly appreciated.
–John