test(roles): run molecule's check step before and after converge
Every role scenario with a converge now runs check right before it (a fresh host) and right after it (a configured host), and a script test fails a scenario without both. pihole and pve_lxc move their second check from after idempotence to after converge to match. The roles that failed under --check on a fresh host get the two allowed guards: cloudflared, docker, gitea, gitea_runner, traefik and user_management. ufw and fail2ban preview only a host where their package is installed, as their READMEs now say. Closes #134 Assisted-by: Claude Code
This commit is contained in:
1 parent
51b38211e7
commit
cf2286b7a7
56 files changed
+202
-35
No files matched your search
@@ -21,6 +21,7 @@
|
||||
cmd: touch {{ traefik_acme_file }}
|
||||
args:
|
||||
creates: "{{ traefik_acme_file }}"
|
||||
register: __traefik_acme_touch
|
||||
tags: [traefik, install, binary, update]
|
||||
|
||||
- name: Ensure correct permissions on ACME file
|
||||
@@ -30,6 +31,8 @@
|
||||
owner: "{{ traefik_user }}"
|
||||
group: "{{ traefik_user }}"
|
||||
mode: "0600"
|
||||
# Under --check the touch above is skipped, and the file module fails on a missing file.
|
||||
when: not ansible_check_mode or __traefik_acme_touch is not changed
|
||||
tags: [traefik, install, binary, update]
|
||||
|
||||
- name: Install the Traefik binary
|
||||
@@ -49,4 +52,6 @@
|
||||
that:
|
||||
- traefik_binary.stat.exists
|
||||
fail_msg: "Traefik binary not found after extraction"
|
||||
# Nothing is extracted under --check.
|
||||
when: not ansible_check_mode
|
||||
tags: [traefik, install, binary, health, update]
|
||||
Reference in new issue
Block a user