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

fix: add support for Raspberry Pi Zero 2 W #2111

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

nicomiguelino
Copy link
Contributor

Description

Copy link

sonarcloud bot commented Nov 4, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
8 Security Hotspots

See analysis details on SonarCloud

Comment on lines -249 to -302
- name: Make sure distro package of Docker is absent
ansible.builtin.apt:
name:
- docker
- docker-engine
- docker.io
- containerd
- runc
- docker-compose
state: absent

- name: Add Docker apt key (x86)
ansible.builtin.apt_key:
url: https://download.docker.com/linux/debian/gpg
state: present
when: ansible_architecture == "x86_64"

- name: Add Docker apt key (Raspberry Pi)
ansible.builtin.apt_key:
url: https://download.docker.com/linux/raspbian/gpg
state: present
when: |
ansible_architecture == "aarch64" or
ansible_architecture == "armv7l" or
ansible_architecture == "armv6l"

- name: Get Debian name
ansible.builtin.command: lsb_release -cs
register: debian_name
changed_when: false

- name: Set architecture
ansible.builtin.set_fact:
architecture: "{{ 'amd64' if ansible_architecture == 'x86_64' else 'armhf' }}"

- name: Add Docker repo
ansible.builtin.lineinfile:
path: /etc/apt/sources.list.d/docker.list
create: true
line: "deb [arch={{ architecture }}] https://download.docker.com/linux/debian {{ debian_name.stdout }} stable"
state: present
owner: root
group: root
mode: "0644"

- name: Install Docker
ansible.builtin.apt:
name:
- docker-ce:{{ architecture }}
- docker-ce-cli:{{ architecture }}
- docker-compose-plugin:{{ architecture }}
update_cache: true
install_recommends: false

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mcrosson, I've created a PR (#2089, still in progress and being code-reviewed) for this so that arm64/aarch64 Docker will be installed instead.

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

Successfully merging this pull request may close these issues.

Raspberry Pi Zero 2 W Support?
1 participant