I already tried to use ‘when: variableA == variableB’ but then it literally evaluates variableA and variableB. Not the outputs of variableA and variableB. And that results in:
skipping: [localhost] => {
“changed”: false,
“skip_reason”: “Conditional result was False”
}
Sometimes variableA could be abc and in that case variableB should also be abc
Sometimes variableA could be 123 and in that case variableB should also be 123
So the when needs to evaluate the contents of each variable, then match them.
That was a fantastic test to run! Many thanks for sending that across.
I first used your test yaml file to run it with the variables you had set in place. I then replaced your variables with my variables, and found that one of my variables was outputting a trailing back-slash \ at the end of the string - which is why the Conditional was resulting in a False.
All sorted now.
Once again, Thank you so much - highly appreciated!