mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-17 11:04:10 -04:00
Package-Manager: Portage-3.0.11, Repoman-3.0.2 Signed-off-by: Andrea Postiglione <andrea.postiglione@gmail.com>
36 lines
784 B
Plaintext
36 lines
784 B
Plaintext
#!/sbin/openrc-run
|
|
# Copyright 2019-2020 Gentoo Authors
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
name="pcsd"
|
|
description="Pacemaker & Corosync configuration daemon"
|
|
command=/usr/sbin/pcsd
|
|
command_args="${pcsd_args}"
|
|
|
|
PIDFILE=/var/run/$name.pid
|
|
|
|
# load defaults
|
|
if [ -f /etc/default/pcsd ]; then source /etc/default/pcsd; fi
|
|
|
|
depend() {
|
|
need net pcsd-daemon
|
|
use syslog
|
|
}
|
|
|
|
start() {
|
|
nc=0
|
|
ebegin "Starting $description"
|
|
|
|
mkdir -p /var/run
|
|
|
|
start-stop-daemon --start -q --exec $command $command_args \
|
|
--pidfile "${PIDFILE}" --make-pidfile --background
|
|
eend $?
|
|
}
|
|
|
|
stop() {
|
|
ebegin "Stopping $description"
|
|
start-stop-daemon --stop -q --pidfile "${PIDFILE}"
|
|
eend $?
|
|
}
|