2021-11-25 09:09:29 +00:00
|
|
|
---
|
|
|
|
- hosts: alpha
|
|
|
|
remote_user: ubuntu
|
|
|
|
tasks:
|
|
|
|
- name: Install docker dependencies
|
|
|
|
become: yes
|
|
|
|
become_method: sudo
|
|
|
|
apt:
|
|
|
|
name: "{{item}}"
|
|
|
|
update_cache: yes
|
|
|
|
loop:
|
|
|
|
- apt-transport-https
|
|
|
|
- ca-certificates
|
|
|
|
- curl
|
|
|
|
- gnupg
|
|
|
|
- software-properties-common
|
|
|
|
- lsb-release
|
|
|
|
|
|
|
|
- name: Install docker GPG key
|
|
|
|
become: yes
|
|
|
|
become_method: sudo
|
|
|
|
apt_key:
|
|
|
|
url: https://download.docker.com/linux/ubuntu/gpg
|
|
|
|
state: present
|
|
|
|
|
|
|
|
- name: Add Docker Apt Repo
|
|
|
|
become: yes
|
|
|
|
become_method: sudo
|
|
|
|
apt_repository:
|
2021-12-01 07:12:49 +00:00
|
|
|
repo: deb https://download.docker.com/linux/ubuntu impish stable
|
2021-11-25 09:09:29 +00:00
|
|
|
state: present
|
|
|
|
|
|
|
|
- name: Install Docker components
|
|
|
|
become: yes
|
|
|
|
become_method: sudo
|
|
|
|
apt:
|
|
|
|
name: "{{item}}"
|
|
|
|
update_cache: yes
|
|
|
|
loop:
|
|
|
|
- docker-ce
|
|
|
|
- docker-ce-cli
|
|
|
|
- containerd.io
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|