ansible/roles/docker/tasks/main.yml

34 lines
707 B
YAML

---
- name: add docker gpg key
apt_key:
keyserver: pgp.mit.edu
id: 8D81803C0EBFCD88
state: present
- name: add docker apt repository
ansible.builtin.apt_repository:
repo: deb https://download.docker.com/linux/ubuntu bionic stable
state: present
update_cache: true
- name: install docker-ce
ansible.builtin.apt:
name: docker-ce
state: present
- name: install docker python bindings
pip:
executable: pip3
name: docker-compose
state: present
- name: create folder structure for bind mounts
ansible.builtin.file:
name: '{{ volume_root_folder }}'
state: directory
- name: setup services
import_tasks: services.yml
tags:
- setup_services