docker_apt_arch defaults to amd64, and the README says to override it per host on anything else. On an arm64 Ubuntu host (for example a Raspberry Pi) that has not been overridden, the source line is written as deb [arch=amd64 ...]. apt then finds no arm64 packages from Docker's repository, so Install Docker Engine packages fails with no installable candidate, or a distribution docker.io is picked up silently. The role already gathers facts, so it can choose the right value itself.
Out of scope: any non-Ubuntu platform, and the apt source file format.
Proposal
Default docker_apt_arch to a value derived from ansible_facts['architecture'] (x86_64 gives amd64, aarch64 gives arm64), and fail with a clear message for any other architecture instead of guessing.
An explicitly set docker_apt_arch keeps winning, so no existing override changes.
Update meta/argument_specs.yml, the README variable table and the Molecule verification, and add a changelog fragment (minor_changes).
Acceptance criteria
On an x86_64 host with no override the source line contains arch=amd64 (Molecule verify.yml reads the file).
With the fact set to aarch64 and no override it contains arch=arm64 (a converge case with ansible_architecture overridden, or an unit-style assert on the computed value).
With docker_apt_arch: amd64 set on an aarch64 fact, the override is used.
An unsupported architecture value fails the play with a message that names the variable.
ansible-test sanity, ansible-lint and yamllint are clean, and the README table matches argument_specs.yml.
Not verified
I have not run this role on an arm64 host. The failure above is what the source line and apt's behaviour imply, not something I reproduced with this role.
Whether arm64 is a platform you want to support: the README declares Ubuntu and amd64 as the default architecture, and the Molecule image is amd64 only.
Questions for the maintainer
Is deriving the value from the fact acceptable as the new default, given the README currently documents amd64?
Should an unsupported architecture fail, or fall back to amd64?
Assisted-by: Claude Code
## Problem
`docker_apt_arch` defaults to `amd64`, and the README says to override it per host on anything else. On an arm64 Ubuntu host (for example a Raspberry Pi) that has not been overridden, the source line is written as `deb [arch=amd64 ...]`. apt then finds no `arm64` packages from Docker's repository, so `Install Docker Engine packages` fails with no installable candidate, or a distribution `docker.io` is picked up silently. The role already gathers facts, so it can choose the right value itself.
Out of scope: any non-Ubuntu platform, and the apt source file format.
## Proposal
- Default `docker_apt_arch` to a value derived from `ansible_facts['architecture']` (`x86_64` gives `amd64`, `aarch64` gives `arm64`), and fail with a clear message for any other architecture instead of guessing.
- An explicitly set `docker_apt_arch` keeps winning, so no existing override changes.
- Update `meta/argument_specs.yml`, the README variable table and the Molecule verification, and add a changelog fragment (`minor_changes`).
## Acceptance criteria
- [ ] On an `x86_64` host with no override the source line contains `arch=amd64` (Molecule `verify.yml` reads the file).
- [ ] With the fact set to `aarch64` and no override it contains `arch=arm64` (a converge case with `ansible_architecture` overridden, or an unit-style assert on the computed value).
- [ ] With `docker_apt_arch: amd64` set on an `aarch64` fact, the override is used.
- [ ] An unsupported architecture value fails the play with a message that names the variable.
- [ ] `ansible-test sanity`, ansible-lint and yamllint are clean, and the README table matches `argument_specs.yml`.
## Not verified
- I have not run this role on an arm64 host. The failure above is what the source line and apt's behaviour imply, not something I reproduced with this role.
- Whether arm64 is a platform you want to support: the README declares Ubuntu and `amd64` as the default architecture, and the Molecule image is amd64 only.
## Questions for the maintainer
- Is deriving the value from the fact acceptable as the new default, given the README currently documents `amd64`?
- Should an unsupported architecture fail, or fall back to `amd64`?
Assisted-by: Claude Code
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Problem
docker_apt_archdefaults toamd64, and the README says to override it per host on anything else. On an arm64 Ubuntu host (for example a Raspberry Pi) that has not been overridden, the source line is written asdeb [arch=amd64 ...]. apt then finds noarm64packages from Docker's repository, soInstall Docker Engine packagesfails with no installable candidate, or a distributiondocker.iois picked up silently. The role already gathers facts, so it can choose the right value itself.Out of scope: any non-Ubuntu platform, and the apt source file format.
Proposal
docker_apt_archto a value derived fromansible_facts['architecture'](x86_64givesamd64,aarch64givesarm64), and fail with a clear message for any other architecture instead of guessing.docker_apt_archkeeps winning, so no existing override changes.meta/argument_specs.yml, the README variable table and the Molecule verification, and add a changelog fragment (minor_changes).Acceptance criteria
x86_64host with no override the source line containsarch=amd64(Moleculeverify.ymlreads the file).aarch64and no override it containsarch=arm64(a converge case withansible_architectureoverridden, or an unit-style assert on the computed value).docker_apt_arch: amd64set on anaarch64fact, the override is used.ansible-test sanity, ansible-lint and yamllint are clean, and the README table matchesargument_specs.yml.Not verified
amd64as the default architecture, and the Molecule image is amd64 only.Questions for the maintainer
amd64?amd64?Assisted-by: Claude Code