Skip to content

Instantly share code, notes, and snippets.

@misraX
Last active August 11, 2017 12:06
Show Gist options
  • Save misraX/ce79cb38358cc4895ca8dd9ca7e13d5f to your computer and use it in GitHub Desktop.
Save misraX/ce79cb38358cc4895ca8dd9ca7e13d5f to your computer and use it in GitHub Desktop.
Installing docker in Debian amd64 using the official method
#!/bin/bash
# installing dependencies
apt-get install -y apt-transport-https ca-certificates curl gnupg2 software-properties-common
# Adding docker keys to apt-keys
curl -fsSL https://download.docker.com/linux/debian/gpg | apt-key add -
# Verifying the docker figerprint
apt-key fingerprint 0EBFCD88
# Adding docker soure to apt-list /etc/source.list.d/docker.list
echo "deb [arch=amd64] https://download.docker.com/linux/debian $(lsb_release -cs) stable" > /etc/apt/sources.list.d/docker.list
# In my case I was using debian jessie The echo output should be:
# deb [arch=amd64] https://download.docker.com/linux/debian jessie stable
# Update apt-get cache
apt-get update
# Instlaad docker-ce
apt-get install -y docker-ce
# Running the hello world to verify docker
docker run hello-world
# Printing docker info
docker info
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment