mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-13 07:34:50 +00:00
Fixes problems with the 2 rc.d scripts.
Submitted by: dougb@ (via mail) Approved by: vsevolod@ (via mail)
This commit is contained in:
parent
54dbf5386c
commit
9dfd0c0cff
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=296682
@ -7,7 +7,7 @@
|
||||
|
||||
PORTNAME= rspamd
|
||||
PORTVERSION= 0.4.6
|
||||
PORTREVISION= 2
|
||||
PORTREVISION= 3
|
||||
CATEGORIES= mail
|
||||
MASTER_SITES= http://highsecure.ru/
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
|
||||
# $FreeBSD$
|
||||
#
|
||||
# PROVIDE: rspamd
|
||||
@ -21,40 +21,37 @@
|
||||
|
||||
name=rspamd
|
||||
rcvar=rspamd_enable
|
||||
|
||||
load_rc_config $name
|
||||
|
||||
: ${rspamd_enable:="NO"}
|
||||
: ${rspamd_user="nobody"}
|
||||
: ${rspamd_group="nobody"}
|
||||
: ${rspamd_flags="-c %%PREFIX%%/etc/rspamd.xml"}
|
||||
|
||||
pidfile=${rspamd_pidfile:-"/var/run/rspamd/rspamd.pid"}
|
||||
|
||||
command=%%PREFIX%%/bin/rspamd
|
||||
restart_precmd="rspamd_checkconfig"
|
||||
reload_precmd="rspamd_checkconfig"
|
||||
configtest_cmd="rspamd_checkconfig"
|
||||
reopenlog_cmd="reopenlog_cmd"
|
||||
|
||||
pidfile="$rspamd_pidfile"
|
||||
required_files=%%PREFIX%%/etc/rspamd.xml
|
||||
|
||||
load_rc_config $name
|
||||
|
||||
: ${rspamd_enable="NO"}
|
||||
: ${rspamd_pidfile="/var/run/rspamd/rspamd.pid"}
|
||||
: ${rspamd_user="nobody"}
|
||||
: ${rspamd_group="nobody"}
|
||||
: ${rspamd_flags="-c %%PREFIX%%/etc/rspamd.xml"}
|
||||
|
||||
stop_postcmd="rm -f $rspamd_pidfile"
|
||||
command_args="-u ${rspamd_user} -g ${rspamd_group}"
|
||||
sig_reload="HUP"
|
||||
extra_commands="reload configtest reopenlog"
|
||||
stop_postcmd="rm -f $pidfile"
|
||||
|
||||
rspamd_checkconfig()
|
||||
{
|
||||
echo "Performing sanity check on rspamd configuration:"
|
||||
eval ${command} ${command_args} -t
|
||||
echo "Performing sanity check on rspamd configuration:"
|
||||
eval ${command} ${command_args} -t
|
||||
}
|
||||
|
||||
reopenlog_cmd()
|
||||
{
|
||||
pkill -USR1 -F $rspamd_pidfile
|
||||
pkill -USR1 -F $pidfile
|
||||
}
|
||||
|
||||
sig_reload="HUP"
|
||||
|
||||
command_args="-u ${rspamd_user} -g ${rspamd_group}"
|
||||
|
||||
extra_commands="reload configtest reopenlog"
|
||||
run_rc_command "$1"
|
||||
|
||||
|
@ -1,11 +1,10 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
|
||||
# $FreeBSD$
|
||||
#
|
||||
# PROVIDE: rspamd_redirector
|
||||
# REQUIRE: LOGIN
|
||||
# KEYWORD: shutdown
|
||||
|
||||
#
|
||||
# Add the following line to /etc/rc.conf to enable rspamd_redirector:
|
||||
#
|
||||
@ -16,18 +15,17 @@
|
||||
|
||||
name="rspamd_redirector"
|
||||
rcvar=rspamd_redirector_enable
|
||||
command="%%PREFIX%%/bin/rspamd-redirector"
|
||||
|
||||
load_rc_config $name
|
||||
|
||||
: ${rspamd_redirector_enable="NO"}
|
||||
: ${rspamd_redirector_pidfile="/var/run/rspamd/redirector.pid"}
|
||||
: ${rspamd_redirector_enable:="NO"}
|
||||
|
||||
stop_postcmd="rm -f $rspamd_redirector_pidfile"
|
||||
pidfile=${rspamd_redirector_pidfile:-"/var/run/rspamd/redirector.pid"}
|
||||
|
||||
command="%%PREFIX%%/bin/rspamd-redirector"
|
||||
command_interpreter="/usr/bin/perl"
|
||||
extra_commands="reload"
|
||||
sig_reload="USR1"
|
||||
|
||||
command_interpreter="/usr/bin/perl"
|
||||
stop_postcmd="rm -f $pidfile"
|
||||
|
||||
run_rc_command "$1"
|
||||
|
Loading…
Reference in New Issue
Block a user