Skip to content

Instantly share code, notes, and snippets.

@yaodong
Created April 26, 2020 06:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yaodong/5c6033e354e1caafdbd28370cd8fbbc2 to your computer and use it in GitHub Desktop.
Save yaodong/5c6033e354e1caafdbd28370cd8fbbc2 to your computer and use it in GitHub Desktop.
---
- hosts: manage
remote_user: root
tasks:
- name: install dependencies
apt:
package:
- apt-transport-https
- ca-certificates
- curl
- gnupg-agent
- software-properties-common
state: present
- name: install key
apt_key:
url: https://download.docker.com/linux/debian/gpg
state: present
- name: repository
apt_repository:
repo: deb [arch=amd64] https://download.docker.com/linux/debian stretch stable
state: present
- name: install docker
apt:
package:
- docker-ce
- docker-ce-cli
- containerd.io
state: present
update_cache: true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment