freebsd-ports/archivers/urbackup-server/files/urbackup_server.in
Kurt Jaeger af79bc01d0 archivers/urbackup-server: add default config and log rotation (via newsyslog)
PR:		227853
Submitted by:	Kirk Coombs <freebsd@coombscloud.com> (maintainer)
2018-07-31 18:43:04 +00:00

30 lines
595 B
Bash

#!/bin/sh
# $FreeBSD$
#
# PROVIDE: urbackup_server
# REQUIRE: LOGIN
# KEYWORD: shutdown
#
# Add these lines to /etc/rc.conf.local or /etc/rc.conf
# to enable this service:
#
# urbackup_server_enable (bool): Set to NO by default.
# Set it to YES to enable the UrBackup Server.
. /etc/rc.subr
name=urbackup_server
desc="UrBackup Daemon"
rcvar=urbackup_server_enable
load_rc_config $name
: ${urbackup_server_enable:=NO}
command=%%PREFIX%%/bin/urbackupsrv
pidfile=/var/run/urbackupsrv.pid
command_args="run -d -w $pidfile -c %%PREFIX%%/etc/urbackup/urbackupsrv.conf"
run_rc_command "$1"