diff --git a/roles/gitlab-runner/tasks/docker.yml b/roles/gitlab-runner/tasks/docker.yml index cde36a2..1613de3 100644 --- a/roles/gitlab-runner/tasks/docker.yml +++ b/roles/gitlab-runner/tasks/docker.yml @@ -8,11 +8,19 @@ id: 9DC858229FC7DD38854AE2D88D81803C0EBFCD88 url: https://download.docker.com/linux/debian/gpg -- name: Add Docker apt repo to souces.list +- name: Add arm64 Docker apt repo to souces.list apt_repository: codename: "{{ ansible_distribution_release }}" - repo: "deb [arch={% if {{ ansible_architecture }} == aarch64 %}arm64 {% endif %}] https://download.docker.com/linux/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} stable" + repo: "deb [arch=arm64] https://download.docker.com/linux/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} stable" update_cache: yes + when: ansible_architecture == "aarch64" + +- name: Add amd64 Docker apt repo to souces.list + apt_repository: + codename: "{{ ansible_distribution_release }}" + repo: "deb [arch=amd64] https://download.docker.com/linux/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} stable" + update_cache: yes + when: ansible_architecture == "amd64" - name: Install Docker CE apt: