James E. Blair 7338da8e4b Add missing zuul parameters
Change-Id: I41e8eb35b34a7566e94ece4d144675faf6c93ba3
2012-05-30 09:26:51 -07:00

44 lines
892 B
Puppet

class zuul ()
{
$packages = ["python-webob",
"python-paste"]
package { $packages:
ensure => "present",
}
# if we already have the repo the pull updates
exec { "update_zuul":
command => "git pull --ff-only",
cwd => "/opt/zuul",
path => "/bin:/usr/bin",
onlyif => "test -d /opt/zuul",
before => Exec["get_zuul"],
}
# otherwise get a new clone of it
exec { "get_zuul":
command => "git clone https://github.com/openstack-ci/zuul /opt/zuul",
path => "/bin:/usr/bin",
onlyif => "test ! -d /opt/zuul"
}
exec { "install_zuul":
command => "python setup.py install",
cwd => "/opt/zuul",
path => "/bin:/usr/bin",
subscribe => [ Exec["get_zuul"], Exec["update_zuul"] ],
}
file { "/etc/zuul":
ensure => "directory",
}
file { "/var/log/zuul":
ensure => "directory",
owner => 'jenkins'
}
}