2014-08-22 Koichiro Kikuchi <koichiro@rworks.jp>
* FreeBSD/pandora_server: Fixed bug fail to start pandora_server with no profile. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@10446 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
dcf974bb46
commit
9c3208eff7
|
@ -1,3 +1,8 @@
|
||||||
|
2014-08-22 Koichiro Kikuchi <koichiro@rworks.jp>
|
||||||
|
|
||||||
|
* FreeBSD/pandora_server: Fixed bug fail to start pandora_server with
|
||||||
|
no profile.
|
||||||
|
|
||||||
2014-08-21 Hirofumi Kosaka <kosaka@rworks.jp>
|
2014-08-21 Hirofumi Kosaka <kosaka@rworks.jp>
|
||||||
|
|
||||||
* lib/PandoraFMS/Core.pm: Prevent some warnings would be
|
* lib/PandoraFMS/Core.pm: Prevent some warnings would be
|
||||||
|
|
|
@ -48,29 +48,28 @@ if [ "$2" ]; then
|
||||||
eval pandora_server_enable="\${pandora_server_${profile}_enable:-$pandora_server_enable}"
|
eval pandora_server_enable="\${pandora_server_${profile}_enable:-$pandora_server_enable}"
|
||||||
eval pandora_server_flags="\${pandora_server_${profile}_flags:-$pandora_server_flags}"
|
eval pandora_server_flags="\${pandora_server_${profile}_flags:-$pandora_server_flags}"
|
||||||
eval pidfile="\${pandora_server_${profile}_pidfile:-$pidfile}"
|
eval pidfile="\${pandora_server_${profile}_pidfile:-$pidfile}"
|
||||||
pandora_server_flags="$pandora_server_flags -P $pidfile $pandora_server_configfile"
|
|
||||||
else
|
else
|
||||||
echo "$0: extra argument ignored"
|
echo "$0: extra argument ignored"
|
||||||
fi
|
fi
|
||||||
else
|
elif [ "${pandora_server_profiles}" ] && [ "$1" ]; then
|
||||||
if [ "${pandora_server_profiles}" ] && [ "$1" ]; then
|
for profile in ${pandora_server_profiles}; do
|
||||||
for profile in ${pandora_server_profiles}; do
|
eval _enable="\${pandora_server_${profile}_enable}"
|
||||||
eval _enable="\${pandora_server_${profile}_enable}"
|
case "${_enable:-${pandora_server_enable}}" in
|
||||||
case "${_enable:-${pandora_server_enable}}" in
|
[Yy][Ee][Ss]);;
|
||||||
[Yy][Ee][Ss]);;
|
*) continue;;
|
||||||
*) continue;;
|
esac
|
||||||
esac
|
echo "===> pandora_server profile: ${profile}"
|
||||||
echo "===> pandora_server profile: ${profile}"
|
/usr/local/etc/rc.d/pandora_server $1 ${profile}
|
||||||
/usr/local/etc/rc.d/pandora_server $1 ${profile}
|
retcode="$?"
|
||||||
retcode="$?"
|
if [ "0${retcode}" -ne 0 ]; then
|
||||||
if [ "0${retcode}" -ne 0 ]; then
|
failed="${profile} (${retcode}) ${failed:-}"
|
||||||
failed="${profile} (${retcode}) ${failed:-}"
|
else
|
||||||
else
|
success="${profile} ${success:-}"
|
||||||
success="${profile} ${success:-}"
|
fi
|
||||||
fi
|
done
|
||||||
done
|
exit 0
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
pandora_server_flags="$pandora_server_flags -P $pidfile $pandora_server_configfile"
|
||||||
|
|
||||||
run_rc_command "$1"
|
run_rc_command "$1"
|
||||||
|
|
Loading…
Reference in New Issue