Interview Prep/Ansible/Project Structure and Design

What is your idempotency review checklist for a PR?

IntermediateProductionProject Structure and Design
Answer
  1. Second run reports changed=0 (checked in Molecule's idempotence step).
  2. No shell/command without guards.
  3. state: latest avoided for packages unless patching is the goal.
  4. Templates contain no timestamps or random values.
  5. Handlers used instead of unconditional restarts.
  6. --check --diff output is sane.
  7. Passwords use fixed salts or update_password: on_create.
  8. Downloads have a checksum.

Most "flapping" playbooks fail on 2 or 4.

All Ansible questions Roadmap: Ansible

More on Project Structure and Design