Skip to content

Instantly share code, notes, and snippets.

@koshatul
Last active May 4, 2018 05:43
Show Gist options
  • Save koshatul/fa7d71fc38037dbd3094be400f77bf74 to your computer and use it in GitHub Desktop.
Save koshatul/fa7d71fc38037dbd3094be400f77bf74 to your computer and use it in GitHub Desktop.
Updated docker-install for bionic (when docker releases it)
#!/bin/bash
set -ex
## Install Docker on Ubuntu 16.04 (and probably future versions)
## curl -sSL 'https://gist.githubusercontent.com/koshatul/fa7d71fc38037dbd3094be400f77bf74/raw/docker-install.sh' | /bin/bash /dev/stdin --
sudo apt-get install -qy --no-install-recommends \
apt-transport-https \
ca-certificates \
curl \
software-properties-common
case $(lsb_release -cs) in
xenial)
sudo apt-get install -qy --no-install-recommends \
linux-image-extra-$(uname -r) \
linux-image-extra-virtual
;;
bionic)
sudo apt-get install -qy --no-install-recommends \
gpg-agent
;;
esac
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
apt-key fingerprint 0EBFCD88
sudo add-apt-repository "deb [arch=$(dpkg --print-architecture)] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt-get update
sudo apt-get -y install docker-ce
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment