Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save jan-swiecki/4f5491b5218d23f30f19 to your computer and use it in GitHub Desktop.
Save jan-swiecki/4f5491b5218d23f30f19 to your computer and use it in GitHub Desktop.
Installs docker-compose inside docker-machine
#!/bin/sh
# Installs docker-compose inside docker-machine
DOCKER_COMPOSE_VERSION=1.6.0
# Download docker-compose to the permanent storage
echo 'Downloading docker-compose to the permanent VM storage...'
sudo mkdir -p /var/lib/boot2docker/bin
sudo curl -sL https://github.com/docker/compose/releases/download/${DOCKER_COMPOSE_VERSION}/docker-compose-`uname -s`-`uname -m` -o /var/lib/boot2docker/bin/docker-compose
sudo chmod +x /var/lib/boot2docker/bin/docker-compose
sudo ln -sf /var/lib/boot2docker/bin/docker-compose /usr/local/bin/docker-compose
# Making the symlink persistent via bootlocal.sh
echo 'Writing to bootlocal.sh to make docker-compose available on every boot...'
cat <<SCRIPT | sudo tee -a /var/lib/boot2docker/bootlocal.sh > /dev/null
# docker-compose
sudo ln -sf /var/lib/boot2docker/bin/docker-compose /usr/local/bin/docker-compose
SCRIPT
sudo chmod +x /var/lib/boot2docker/bootlocal.sh
echo 'Launching docker-compose...'
docker-compose --version
@qgervacio
Copy link

Thank you

@legionovo
Copy link

Wielkie Dzięki!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment