Last active
December 28, 2015 18:59
-
-
Save jpfuentes2/7547214 to your computer and use it in GitHub Desktop.
Latest stable docker + Ubuntu Precise (12.04) 64bit
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
def machine_exists? | |
!Dir.glob("#{File.dirname(__FILE__)}/.vagrant/machines/default/*/id").empty? | |
end | |
Vagrant::Config.run do |config| | |
config.vm.box = "precise-64-docker" | |
config.vm.box_url = "http://bit.ly/dockerprecise64" | |
config.ssh.forward_agent = true | |
unless machine_exists? | |
cmd = "apt-get update -qq; | |
service docker stop; | |
apt-get install -q -y --force-yes lxc-docker" | |
config.vm.provision :shell, :inline => cmd | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment