2022-11-09 06:11:12 +00:00
|
|
|
# This playbook downloads all the basic requirements to give containers
|
|
|
|
# an environment where they can be brought up safely. We focus primarily
|
|
|
|
# on the host with this playbook
|
|
|
|
---
|
|
|
|
- hosts: atlas
|
|
|
|
become: yes
|
|
|
|
become_method: sudo
|
|
|
|
tasks:
|
|
|
|
- name: Install docker dependencies
|
|
|
|
apt:
|
|
|
|
name: "{{item}}"
|
|
|
|
update_cache: yes
|
|
|
|
loop:
|
|
|
|
- apt-transport-https
|
|
|
|
- ca-certificates
|
|
|
|
- curl
|
|
|
|
- gnupg
|
|
|
|
- software-properties-common
|
|
|
|
- lsb-release
|
2022-11-09 08:17:22 +00:00
|
|
|
- python3
|
|
|
|
- python3-pip
|
|
|
|
|
|
|
|
- name: Install docker-py
|
|
|
|
pip:
|
|
|
|
name: docker-py
|
|
|
|
state: present
|
2022-11-09 06:11:12 +00:00
|
|
|
|
|
|
|
- name: Install docker GPG key
|
|
|
|
apt_key:
|
|
|
|
url: https://download.docker.com/linux/ubuntu/gpg
|
|
|
|
state: present
|
|
|
|
|
|
|
|
- name: Add Docker Apt Repo
|
|
|
|
apt_repository:
|
|
|
|
repo: deb https://download.docker.com/linux/ubuntu impish stable
|
|
|
|
state: present
|
|
|
|
|
|
|
|
- name: Install Docker components
|
|
|
|
apt:
|
|
|
|
name: "{{item}}"
|
|
|
|
update_cache: yes
|
|
|
|
loop:
|
|
|
|
- docker-ce
|
|
|
|
- docker-ce-cli
|
|
|
|
- containerd.io
|
|
|
|
|