View | Details | Raw Unified | Return to bug 227056
Collapse All | Expand All

(-)sysutils/sec/files/sec.in (-3 / +14 lines)
Lines 34-42 Link Here
34
command_args="-detach"
34
command_args="-detach"
35
command_interpreter="%%PERL%%"
35
command_interpreter="%%PERL%%"
36
extra_commands="reload"
36
extra_commands="reload"
37
pidfile="/var/run/sec.pid"
37
pidfile="/var/run/sec/sec.pid"
38
38
39
start_precmd="sec_checkconfig"
39
start_precmd="sec_precmd"
40
reload_precmd="sec_checkconfig"
40
reload_precmd="sec_checkconfig"
41
restart_precmd="sec_checkconfig"
41
restart_precmd="sec_checkconfig"
42
sig_reload=HUP
42
sig_reload=HUP
Lines 46-51 Link Here
46
[ -z "${sec_flags}" ]        && sec_flags="-log=/var/log/sec.log"
46
[ -z "${sec_flags}" ]        && sec_flags="-log=/var/log/sec.log"
47
[ -z "${sec_configfile}" ]   && sec_configfile="%%PREFIX%%/etc/sec.conf"
47
[ -z "${sec_configfile}" ]   && sec_configfile="%%PREFIX%%/etc/sec.conf"
48
48
49
sec_precmd() {
50
  dn=`dirname ${pidfile}`
51
  if [ ! -d ${dn} ]; then
52
    mkdir -p ${dn}
53
    if [ -n $sec_user ]; then
54
	/usr/sbin/chown ${sec_user} ${dn}
55
    fi
56
  fi
57
  sec_checkconfig
58
}
59
49
sec_checkconfig() {
60
sec_checkconfig() {
50
  if [ -z $instance ]
61
  if [ -z $instance ]
51
  then
62
  then
Lines 75-81 Link Here
75
	do
86
	do
76
                # Iterate through all instances
87
                # Iterate through all instances
77
                name="sec_${instance}"
88
                name="sec_${instance}"
78
                pidfile="/var/run/sec_${instance}.pid"
89
                pidfile="/var/run/sec/sec_${instance}.pid"
79
                eval required_files=\$sec_${instance}_configfile
90
                eval required_files=\$sec_${instance}_configfile
80
                eval sec_${instance}_flags="\"-conf=\$sec_${instance}_configfile -pid=\$pidfile \$sec_${instance}_flags\""
91
                eval sec_${instance}_flags="\"-conf=\$sec_${instance}_configfile -pid=\$pidfile \$sec_${instance}_flags\""
81
92

Return to bug 227056