Update powerwall.sh
This commit is contained in:
@@ -31,11 +31,13 @@ RESTARTALL_SERVICES(){
|
|||||||
STOPALL_SERVICES(){
|
STOPALL_SERVICES(){
|
||||||
for srvc in "${!PW_POWERWALL_SERVICES[@]}"; do
|
for srvc in "${!PW_POWERWALL_SERVICES[@]}"; do
|
||||||
SERVICE_MNG ${srvc} stop
|
SERVICE_MNG ${srvc} stop
|
||||||
|
echo -e "($(date +'%Y-%m-%d %H:%M:%S')) - '${PW_POWERWALL_SERVICES[${srvc}]}' Service Stopped" >> ${PW_LOGFILE}
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
STARTALL_SERVICES(){
|
STARTALL_SERVICES(){
|
||||||
for srvc in "${!PW_POWERWALL_SERVICES[@]}"; do
|
for srvc in "${!PW_POWERWALL_SERVICES[@]}"; do
|
||||||
SERVICE_MNG ${srvc} start
|
SERVICE_MNG ${srvc} start
|
||||||
|
echo -e "($(date +'%Y-%m-%d %H:%M:%S')) - '${PW_POWERWALL_SERVICES[${srvc}]}' Service Started" >> ${PW_LOGFILE}
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
SERVICE_MNG(){
|
SERVICE_MNG(){
|
||||||
@@ -884,7 +886,8 @@ fi
|
|||||||
|
|
||||||
elif [ "${2}" == "powerlogger" ]; then
|
elif [ "${2}" == "powerlogger" ]; then
|
||||||
STOP_SERVICE powerlogger
|
STOP_SERVICE powerlogger
|
||||||
|
echo "(`date +'%Y-%m-%d %H:%M:%S'`) Service Stopped" >> ${PW_LOGPOWER}
|
||||||
|
echo -e "($(date +'%Y-%m-%d %H:%M:%S')) - '${PW_POWERWALL_SERVICES[powerlogger]}' Service Stopped" >> ${PW_LOGFILE}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
elif [ "${3}" == "restart" ]; then
|
elif [ "${3}" == "restart" ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user