Fixed puppetd service for older OpenBSD versions

This commit is contained in:
Ossi Salmi 2011-11-29 22:34:52 +02:00 committed by Timo Mkinen
parent 385cbeeb5a
commit e43512adad

View file

@ -47,17 +47,16 @@ class puppet::client {
case $operatingsystem {
openbsd: {
service { "puppet":
name => "puppetd",
name => $operatingsystemrelease ? {
/4\.[1-8]/ => "puppet",
default => "puppetd",
},
ensure => running,
enable => true,
start => $operatingsystemrelease ? {
/4\.[1-6]/ => "/usr/local/bin/puppetd",
default => "/usr/local/sbin/puppetd",
},
restart => $operatingsystemrelease ? {
/4\.[1-6]/ => "/usr/bin/pkill -HUP -f /usr/local/bin/puppetd",
default => "/usr/bin/pkill -HUP -f /usr/local/sbin/puppetd",
},
start => "/usr/local/sbin/puppetd",
stop => "pkill -f /usr/local/sbin/puppetd",
status => "pgrep -f /usr/local/sbin/puppetd",
restart => "pkill -HUP -f /usr/local/sbin/puppetd",
subscribe => File["/etc/puppet/puppet.conf"],
}
}