Skip to content

Instantly share code, notes, and snippets.

@beingadityak
Last active August 16, 2020 16:23
Show Gist options
  • Save beingadityak/35569b90724088606efc2035eac483d5 to your computer and use it in GitHub Desktop.
Save beingadityak/35569b90724088606efc2035eac483d5 to your computer and use it in GitHub Desktop.
Docker installation - Cloud Config
#cloud-config
apt_update: true
apt_upgrade: true
ssh_authorized_keys:
- SSH_KEY_HERE
packages:
- apt-transport-https
- ca-certificates
- curl
- gnupg-agent
- software-properties-common
runcmd:
- curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -
- add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
- apt-get update -y
- apt-get install -y docker-ce docker-ce-cli containerd.io
- systemctl start docker
- systemctl enable docker
system_info:
default_user:
groups: [docker]
final_message: "The system is finally up, after $UPTIME seconds"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment