Ansible - When
About
This page is about the conditional operator when.
all with (loop) clauses get executed BEFORE the when: as the when: can include 'item' to make each iteration of the loop conditional.
Syntax
when is a task property.
task:
when: expression
where:
- expression is a conditional expression