docker/tasks/Debian.yaml

37 lines
816 B
YAML

---
- name: Install deps packages
apt:
name: "{{ docker_deps_packages }}"
state: present
update_cache: yes
- name: Add gpg keys for Docker repo
ansible.builtin.apt_key:
url: "{{ item.url }}"
keyring: "{{ item.keyring }}"
loop: "{{ docker_apt_key }}"
- name: Add Docker repository
ansible.builtin.apt_repository:
repo: "{{ item.repo }}"
state: present
filename: "{{ item.filename }}"
update_cache: yes
loop: "{{ docker_apt_repository }}"
- name: Ensure {{ docker_package }} installed
apt:
name: "{{ docker_package }}"
state: present
- name: Ensure docker service enabled and started
systemd:
name: "{{ docker_unit_name }}"
enabled: yes
state: started
- name: Ensure python3-docker installed
apt:
name: python3-docker
state: present