Overhaul reuse structure from role to task orientation

The overall config this will end up with is going to be nowhere
near complicated enough to require the segmented structure of roles.
A single directory of reusable tasks and resources will be much better
This commit is contained in:
2020-12-04 14:47:33 -05:00
parent 5df550669a
commit f1639dce1e
26 changed files with 181 additions and 476 deletions

36
tasks/docker/install.yml Normal file
View File

@@ -0,0 +1,36 @@
---
# Just use the same repo for cent7 and cent8 because ¯\_(ツ)_/¯
- name: Install Docker repository
become: true
when: ansible_distribution == "CentOS"
yum_repository:
name: docker-ce-stable
description: Docker CE Stable - $basearch
file: docker-ce-stable
baseurl: https://download.docker.com/linux/centos/7/$basearch/stable
gpgcheck: false
- name: Install Docker on Cent7
become: true
when: ansible_distribution == "CentOS" and ansible_distribution_major_version == "7"
yum:
# Update the cache to update with the new docker repo
update_cache: true
state: "{{ _runtime_update_state }}"
name:
- device-mapper-persistent-data # Required for docker devicestorage driver
- lvm2 # same
- docker-ce
- containerd.io
- name: Install Docker on Cent8
become: true
when: ansible_distribution == "CentOS" and ansible_distribution_major_version == "8"
dnf:
# Update the cache to update with the new docker repo
update_cache: true
state: "{{ _runtime_update_state }}"
name:
- device-mapper-persistent-data # Required for docker devicestorage driver
- lvm2 # same
- docker-ce-3:18.09.1-3.el7