openbsd-ports/sysutils/ruby-puppet/pkg/puppetd.rc
2012-10-28 18:48:45 +00:00

19 lines
397 B
Bash

#!/bin/sh
#
# $OpenBSD: puppetd.rc,v 1.3 2012/10/28 18:48:45 robert Exp $
daemon="/usr/local/bin/puppet agent"
. /etc/rc.d/rc.subr
pexp=".*ruby.* ${daemon}${daemon_flags:+ ${daemon_flags}}"
rc_reload=NO
# XXX can't stop within a fair amount of time when puppetmasterd is unreachable;
# related to: http://projects.puppetlabs.com/issues/11360 ?
rc_stop() {
pkill -9 -f "^${pexp}"
}
rc_cmd $1