Skip to content

Instantly share code, notes, and snippets.

@justenwalker
Created November 12, 2014 23:44
Show Gist options
  • Save justenwalker/908d91026ca318a64135 to your computer and use it in GitHub Desktop.
Save justenwalker/908d91026ca318a64135 to your computer and use it in GitHub Desktop.
boot2docker shim
#! /bin/bash
if [ "running" = `boot2docker status` ]; then
IP=`boot2docker ip 2>/dev/null`
export DOCKER_CERT_PATH="$HOME/.boot2docker/certs/boot2docker-vm"
export DOCKER_TLS_VERIFY=1
export DOCKER_HOST="tcp://$IP:2376"
/usr/local/bin/docker "$@"
else
echo "boot2docker is not running"
exit 1
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment