changed_when

The task keyword that decides, from a condition, whether the task should report changed.

In more detail

changed_when: false tells Ansible a command only reads information, so it reports ok instead of the command module's usual changed. That keeps the change counter honest, so a real change still stands out. It does not stop the command from running.

Related terms

Taught in

References

Certification courses