Skip to content

Instantly share code, notes, and snippets.

@spjwebster
Created January 30, 2014 12:20
Show Gist options
  • Save spjwebster/8707368 to your computer and use it in GitHub Desktop.
Save spjwebster/8707368 to your computer and use it in GitHub Desktop.
class supervisor {
package {'python-pip-supervisor':
ensure => latest,
name => 'supervisor',
provider => 'pip',
}
File {
owner => root,
group => root,
}
file { "/etc/supervisor.d":
ensure => directory,
mode => 755,
require => Package['python-pip-supervisor'],
}
file { "/etc/supervisord.conf":
mode => 644,
source => "puppet:///modules/supervisor/supervisord.conf",
require => Package['python-pip-supervisor'],
}
file { "/etc/init.d/supervisord":
mode => 744,
source => "puppet:///modules/supervisor/supervisord.initd",
require => Package['python-pip-supervisor'],
}
service { "supervisord":
enable => true,
ensure => running,
pattern => 'supervisord',
hasrestart => true,
hasstatus => false,
require => File['/etc/init.d/supervisord'],
subscribe => File['/etc/supervisord.conf']
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment