1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

changed the docker version in vagrant to pull down latest version, moved some things around and put docker and dockerd into /usr/local/bin now. Also added git to install package list

This commit is contained in:
Ken Cochrane 2013-03-11 17:48:39 -07:00
parent 43875a73a0
commit d4da0a0ddb

View file

@ -1,14 +1,15 @@
class docker { class docker {
# update this with latest docker binary distro # update this with latest docker binary distro
$docker_url = "https://dl.dropbox.com/u/20637798/docker.tar.gz" $docker_url = "http://docker.io.s3.amazonaws.com/builds/$kernel/$hardwaremodel/docker-master.tgz"
# update this with latest go binary distry # update this with latest go binary distry
$go_url = "http://go.googlecode.com/files/go1.0.3.linux-amd64.tar.gz" $go_url = "http://go.googlecode.com/files/go1.0.3.linux-amd64.tar.gz"
Package { ensure => "installed" } Package { ensure => "installed" }
package { ["lxc", "debootstrap", "wget", "bsdtar"]: } package { ["lxc", "debootstrap", "wget", "bsdtar", "git"]: }
notify { "docker_url = $docker_url": withpath => true }
exec { "debootstrap" : exec { "debootstrap" :
require => Package["debootstrap"], require => Package["debootstrap"],
@ -26,7 +27,7 @@ class docker {
exec { "fetch-docker" : exec { "fetch-docker" :
require => Package["wget"], require => Package["wget"],
command => "/usr/bin/wget -O - $docker_url | /bin/tar xz -C /home/vagrant", command => "/usr/bin/wget -O - $docker_url | /bin/tar xz -C /home/vagrant",
creates => "/home/vagrant/docker/dockerd" creates => "/home/vagrant/docker-master"
} }
file { "/etc/init/dockerd.conf": file { "/etc/init/dockerd.conf":
@ -39,10 +40,16 @@ class docker {
exec { "copy-docker-bin" : exec { "copy-docker-bin" :
require => Exec["fetch-docker"], require => Exec["fetch-docker"],
command => "/bin/cp /home/vagrant/docker/docker /usr/local/bin", command => "/bin/cp /home/vagrant/docker-master/docker /usr/local/bin",
creates => "/usr/local/bin/docker" creates => "/usr/local/bin/docker"
} }
exec { "copy-dockerd-bin" :
require => Exec["fetch-docker"],
command => "/bin/cp /home/vagrant/docker-master/dockerd /usr/local/bin",
creates => "/usr/local/bin/dockerd"
}
service { "dockerd" : service { "dockerd" :
ensure => "running", ensure => "running",
start => "/sbin/initctl start dockerd", start => "/sbin/initctl start dockerd",