ansible/roles/docker/tasks/main.yml

34 lines
755 B
YAML
Raw Normal View History

2018-05-10 09:19:54 +00:00
---
2022-11-26 09:47:37 +00:00
- name: Add docker gpg key
ansible.builtin.apt_key:
keyserver: pgp.mit.edu
2018-05-10 09:19:54 +00:00
id: 8D81803C0EBFCD88
state: present
2022-11-26 09:47:37 +00:00
- name: Add docker apt repository
2022-11-26 08:52:41 +00:00
ansible.builtin.apt_repository:
repo: deb https://download.docker.com/linux/ubuntu bionic stable
2018-05-10 09:19:54 +00:00
state: present
2022-11-26 08:52:41 +00:00
update_cache: true
2018-05-10 09:19:54 +00:00
2022-11-26 09:47:37 +00:00
- name: Install docker-ce
2022-11-26 08:52:41 +00:00
ansible.builtin.apt:
2018-05-10 09:19:54 +00:00
name: docker-ce
state: present
2022-11-26 09:47:37 +00:00
- name: Install docker python bindings
ansible.builtin.pip:
2022-11-26 08:52:41 +00:00
executable: pip3
name: docker-compose
state: present
2022-11-26 09:47:37 +00:00
- name: Create folder structure for bind mounts
2022-11-26 08:52:41 +00:00
ansible.builtin.file:
name: '{{ volume_root_folder }}'
2019-02-13 09:05:00 +00:00
state: directory
2022-11-26 09:47:37 +00:00
- name: Setup services
ansible.builtin.import_tasks: services.yml
tags:
- setup_services