fix(images): let become work on molecule-ubuntu2604 and add gnupg
In the booted 26.04 container, pam_unix's account check for sudo runs the unix_chkpwd helper, which fails there, so become from root fails with "account validation failure". /etc/pam.d/sudo now lets root through with pam_rootok before common-account; a non-root caller still goes through pam_unix. The build fails if the line does not apply. gnupg joins the image, as in the 24.04 image: the docker and gitea scenarios need it on the target. The temporary diagnostics are removed. Closes #376 Assisted-by: Claude Code
This commit is contained in:
1 parent
5364f18728
commit
efd3a550c5
3 files changed
+15
-26
No files matched your search
@@ -12,7 +12,9 @@ It is the release the hosts are moving to; the roles are tested on it next to 24
|
||||
`ca-certificates`.
|
||||
- Python for Ansible on the target: `python3`, `python3-apt`, `python3-systemd`.
|
||||
- The packages the roles manage, preinstalled so a converge makes no network calls:
|
||||
`iptables`, `ufw`, `fail2ban`, `openssh-server` (the `ssh` unit is enabled).
|
||||
`iptables`, `ufw`, `fail2ban`, `openssh-server` (the `ssh` unit is enabled), and `gnupg`
|
||||
(the docker scenario signs its stand-in APT repository with it).
|
||||
- root's `sudo` skips the PAM account check (`pam_rootok`), so `become` works in the container.
|
||||
- Throwaway SSH host keys and a machine-id generated at build time. They are not secrets and the
|
||||
image is a test target that must never be exposed to a network.
|
||||
|
||||
|
||||
Reference in new issue
Block a user