From 608d831646c467cb3b9140f3e5cf36e47fbf5f9e Mon Sep 17 00:00:00 2001 From: Tony Mack Date: Sun, 5 Aug 2012 21:17:24 -0400 Subject: [PATCH] fix boolean checks --- init.d/sfa | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/init.d/sfa b/init.d/sfa index 5a2fec71..6a3ed370 100755 --- a/init.d/sfa +++ b/init.d/sfa @@ -125,7 +125,7 @@ function reload () { function db_start () { # only if enabled - [ "$SFA_DB_ENABLED" == 1 -o "$SFA_DB_ENABLED" == true ] || return + [ "$SFA_DB_ENABLED" == 1 -o "$SFA_DB_ENABLED" == True ] || return if ! rpm -q myplc >& /dev/null; then @@ -244,7 +244,7 @@ function db_start () { function db_stop () { # only if enabled - [ "$SFA_DB_ENABLED" == 1 ] || return + [ "$SFA_DB_ENABLED" == 1 -o "$SFA_DB_ENABLED" == True ] || return # not too nice, but.. when co-located with myplc we'll let it start/stop postgresql if ! rpm -q myplc >& /dev/null ; then @@ -266,11 +266,11 @@ function start() { # install peer certs action $"SFA: installing peer certs" daemon /usr/bin/sfa-start.py -t -d $OPTIONS - [ "$SFA_REGISTRY_ENABLED" == 1 ] && action $"SFA: Registry" daemon /usr/bin/sfa-start.py -r -d $OPTIONS + [ "$SFA_REGISTRY_ENABLED" == 1 -o "$SFA_REGISTRY_ENABLED" == True ] && action $"SFA: Registry" daemon /usr/bin/sfa-start.py -r -d $OPTIONS - [ "$SFA_AGGREGATE_ENABLED" == 1 ] && action $"SFA: Aggregate" daemon /usr/bin/sfa-start.py -a -d $OPTIONS + [ "$SFA_AGGREGATE_ENABLED" == 1 -o "$SFA_AGGREGATE_ENABLED" == True ] && action $"SFA: Aggregate" daemon /usr/bin/sfa-start.py -a -d $OPTIONS - [ "$SFA_SM_ENABLED" == 1 ] && action "SFA: SliceMgr" daemon /usr/bin/sfa-start.py -s -d $OPTIONS + [ "$SFA_SM_ENABLED" == 1 -o "$SFA_SM_ENABLED" == True ] && action "SFA: SliceMgr" daemon /usr/bin/sfa-start.py -s -d $OPTIONS [ "$SFA_FLASHPOLICY_ENABLED" == 1 ] && \ action "Flash Policy Server" daemon /usr/bin/sfa_flashpolicy.py --file="$SFA_FLASHPOLICY_CONFIG_FILE" --port=$SFA_FLASHPOLICY_PORT -d -- 2.47.0