Files
vapemap/puppet/manifests/classes/supervisor.pp
Andrew Williams 572216d10b Vagrant Support
Brings in the basic config for Vagrant, missing elasticsearch but its enough to bring up a Vagrant instance of the main web app.
2013-03-31 23:53:55 +01:00

30 lines
633 B
Puppet

class supervisor {
package{'supervisor':
ensure => latest,
}
service{'supervisor':
ensure => running,
hasrestart => false,
require => Package['supervisor'],
}
}
define supervisor::program(
$command = $title,
$directory = "/tmp/",
$user = "nobody",
$autostart = true,
$autorestart = true,
$redirect_stderr = true)
{
file {"/etc/supervisor/conf.d/$title.conf":
ensure => present,
owner => "root",
group => "root",
content => template('supervisor/program.erb'),
notify => Service['supervisor'],
require => Package['supervisor'],
}
}