homelab/roles/docker/tasks/main.yml
2024-09-29 18:04:34 +05:00

30 lines
768 B
YAML

---
- name: Install dependencies
become: true
ansible.builtin.apt:
pkg:
- curl
- ca-certificates
- python3-pip
- python3-docker
- python3-requests
- name: Download docker keyring
become: true
ansible.builtin.get_url:
url: https://download.docker.com/linux/debian/gpg
dest: /etc/apt/keyrings/docker.asc
mode: '0644'
- name: Add docker source
become: true
ansible.builtin.apt_repository:
repo: deb [arch=amd64 signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/debian bookworm stable
state: present
filename: docker
- name: Install docker engine
become: true
ansible.builtin.apt:
pkg:
- docker-ce
- docker-ce-cli
- containerd.io
update_cache: yes