Files
guru/sys-cluster/pcs/files/pcs-0.11.initd
Andrea Postiglione ceac712a60 sys-cluster/pcs-0.11.2: fix bashism
Signed-off-by: Andrea Postiglione <andrea.postiglione@gmail.com>
2022-04-24 13:30:02 +02:00

36 lines
770 B
Plaintext

#!/sbin/openrc-run
# Copyright 2019-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
name="pcs"
description="Pacemaker & Corosync configuration daemon"
command=/usr/sbin/pcs
command_args="${pcsd_args}"
PIDFILE=/var/run/$name.pid
# load defaults
if [ -f /etc/default/pcsd ]; then . /etc/default/pcsd; fi
depend() {
need net pcsd
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 $?
}