Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DEV] Docker Installation Fails on Ubuntu Due to Incorrect Architecture Naming in Ansible Playbook #1472

Closed
shark4ce opened this issue Feb 5, 2024 · 3 comments

Comments

@shark4ce
Copy link

shark4ce commented Feb 5, 2024

Summary

Attempting to install the T-Pot platform on Ubuntu results in a failure during the Docker Engine installation step, with an error indicating that the package docker-ce is not available. The root cause is identified as incorrect architecture naming in the Ansible playbook (tpot.yml), specifically in the task that adds the Docker Engine repository for Debian, Raspbian, and Ubuntu environments.

Environment

  • Branch: dev
  • OS: Ubuntu 22.04.3 LTS Server Edition
  • Playbook: tpot.yml

Issue Description

During the T-Pot installation, the Ansible playbook fails to install Docker Engine due to the repository configuration not recognizing x86_64 as a valid architecture, which Docker expects to be named amd64. The affected task is "Add Docker Engine repository (Debian, Raspbian, Ubuntu)", which lacks the necessary normalization of ansible_architecture from x86_64 to amd64.

Reproduction Steps

  1. Run install.sh on an Ubuntu system.
  2. Observe the failure during the Docker Engine installation phase.

Expected Behavior

To ensure compatibility across all supported architectures, the playbook must include the normalization of x86_64 to amd64 for the Docker Engine repository configuration. Currently, while normalizations for other architectures are in place, this specific conversion is absent. Adding it will guarantee the availability of the docker-ce package for installation on systems using the x86_64 architecture.

Actual Behavior

The playbook fails to find the docker-ce package due to incorrect repository configuration, resulting in the error: "msg": "No package matching 'docker-ce' is available".

Screenshot

image

Suggested Fix

Modify the playbook to include normalization from x86_64 to amd64 for the Docker Engine repository configuration step:

- name: Add Docker Engine repository (Debian, Raspbian, Ubuntu)
  repo: "deb [arch={{ ansible_architecture | regex_replace('^(aarch64)$', 'arm64') | regex_replace('^(x86_64)$', 'amd64') }}...
@shark4ce shark4ce changed the title [dev] Docker Installation Fails on Ubuntu Due to Incorrect Architecture Naming in Ansible Playbook [DEV] Docker Installation Fails on Ubuntu Due to Incorrect Architecture Naming in Ansible Playbook Feb 5, 2024
t3chn0m4g3 added a commit that referenced this issue Feb 6, 2024
thanks to @shark4ce for taking the time to test, debug and offer a solution #1472.
@t3chn0m4g3
Copy link
Member

@shark4ce Thanks for taking the time to test, debug and the solution!
Just pushed the fix, please let me know if this works now.

Thank you!

@shark4ce
Copy link
Author

@t3chn0m4g3 Yes, it is working. Thank you!

@t3chn0m4g3
Copy link
Member

Thanks for the feedback @shark4ce!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants