diff options
author | Leonardo Arena <rnalrd@alpinelinux.org> | 2017-12-11 08:30:19 +0000 |
---|---|---|
committer | Leonardo Arena <rnalrd@alpinelinux.org> | 2017-12-11 08:31:38 +0000 |
commit | bd02f881f2cd3d8b1ef786ba3e7482deafb58793 (patch) | |
tree | e5a4a3156041b7c85c36d424c15fd8dd625409e9 /main/bacula/bacula-sd.initd | |
parent | 9fd8829c5749a60c34abbd36f01ecd27177fa751 (diff) | |
download | aports-bd02f881f2cd3d8b1ef786ba3e7482deafb58793.tar.bz2 aports-bd02f881f2cd3d8b1ef786ba3e7482deafb58793.tar.xz |
main/bacula: various improvements and small bug fixes
- use /run dir
- fix conf file permissions
- Inits:
points bacula-sd to right conf file
use openrc to set daemon user
soft depends on firewall added
cosmetic fixes
Diffstat (limited to 'main/bacula/bacula-sd.initd')
-rw-r--r-- | main/bacula/bacula-sd.initd | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/main/bacula/bacula-sd.initd b/main/bacula/bacula-sd.initd index 3d56a9e8f2..a678299e55 100644 --- a/main/bacula/bacula-sd.initd +++ b/main/bacula/bacula-sd.initd @@ -1,20 +1,23 @@ #!/sbin/openrc-run : ${port:=9103} -: ${cfgfile:=/etc/bacula/bacula-dir.conf} -: ${exec_user:=bacula} -: ${exec_group:=bacula} +: ${cfgfile:=/etc/bacula/bacula-sd.conf} +: ${command_user:=bacula} +: ${command_group:=bacula} name="Bacula Storage Daemon" -command="/usr/sbin/$RC_SVCNAME" -command_args="-u $exec_user -g $exec_group -c $cfgfile" -pidfile="/var/run/bacula/$RC_SVCNAME.$port.pid" +command="/usr/sbin/${RC_SVCNAME}" +command_args="-c $cfgfile" +start_stop_daemon_args="--user $command_user --group $command_group" +pidfile="/run/bacula/${RC_SVCNAME}.$port.pid" depend() { need net use dns + after firewall } start_pre() { - checkpath -d -m 0775 -o ${exec_user}:${exec_group} /var/run/bacula + checkpath --directory --mode 0775 \ + --owner ${command_user}:${command_group} /run/bacula } |