Skip to content

Instantly share code, notes, and snippets.

@yoelfme
Created June 10, 2016 23:29
Show Gist options
  • Select an option

  • Save yoelfme/ad3c57e5401e4fb64c312a23458af9d4 to your computer and use it in GitHub Desktop.

Select an option

Save yoelfme/ad3c57e5401e4fb64c312a23458af9d4 to your computer and use it in GitHub Desktop.
Used to upgrade version of docker client in docker machine
mcn_name='prod'
apt_url='https://apt.dockerproject.org'
lsb_dist='ubuntu'
dist_version='trusty'
arch=$(docker-machine ssh ${mcn_name} dpkg --print-architecture)
repo='main'
docker-machine ssh ${mcn_name} "echo deb [arch=${arch}] ${apt_url}/repo ${lsb_dist}-${dist_version} ${repo} | sudo tee /etc/apt/sources.list.d/docker.list"
docker-machine ssh ${mcn_name} sudo apt-get update
docker-machine ssh ${mcn_name} sudo apt-get install -y docker-engine
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment