Created
December 9, 2018 18:46
-
-
Save petarnikolovski/d3a9b080d6b3f1149104b10a81921635 to your computer and use it in GitHub Desktop.
Install Docker CE on Ubuntu 18.04 using Ansible 2.7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- name: Install Docker | |
hosts: all | |
become: yes | |
tasks: | |
- name: Install Docker dependencies | |
apt: | |
pkg: | |
- apt-transport-https | |
- ca-certificates | |
- software-properties-common | |
state: present | |
update_cache: yes | |
- name: Add GPG key | |
apt_key: | |
url: https://download.docker.com/linux/ubuntu/gpg | |
state: present | |
- name: Add stable Docker repository | |
apt_repository: | |
repo: "deb [arch=amd64] https://download.docker.com/linux/ubuntu bionic stable" | |
state: present | |
update_cache: yes | |
- name: Install latest Docker CE | |
apt: | |
pkg: | |
- docker-ce | |
state: present | |
update_cache: yes |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment