summaryrefslogtreecommitdiff
path: root/app-admin/puppet-agent/files/puppet.initd
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /app-admin/puppet-agent/files/puppet.initd
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'app-admin/puppet-agent/files/puppet.initd')
-rw-r--r--app-admin/puppet-agent/files/puppet.initd29
1 files changed, 29 insertions, 0 deletions
diff --git a/app-admin/puppet-agent/files/puppet.initd b/app-admin/puppet-agent/files/puppet.initd
new file mode 100644
index 000000000000..1c366bcf9641
--- /dev/null
+++ b/app-admin/puppet-agent/files/puppet.initd
@@ -0,0 +1,29 @@
+#!/sbin/openrc-run
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+PUPPET_PID_DIR="${PUPPET_PID_DIR:-/var/run/puppet}"
+
+pidfile="${PUPPET_PID_DIR}/puppet.pid"
+PUPPET_LOG_DIR="/var/log/puppetlabs/puppet"
+
+command="/usr/bin/puppet"
+extra_started_commands="reload"
+
+command_args="agent --pidfile ${pidfile} --confdir /etc/puppetlabs/puppet ${PUPPET_EXTRA_OPTS}"
+
+depend() {
+ need localmount
+ use dns logger puppetserver netmount nfsmount
+}
+
+start_pre() {
+ checkpath --directory --owner puppet:puppet "${PUPPET_PID_DIR}"
+ checkpath --directory --owner puppet:puppet --mode 750 ${PUPPET_LOG_DIR}
+}
+
+reload() {
+ ebegin "Reloading $RC_SVCNAME"
+ start-stop-daemon --signal HUP --pidfile "${pidfile}"
+ eend $?
+}