Fix allservicestatus
This commit is contained in:
parent
c1db6284a2
commit
513431b7a3
@ -20,7 +20,7 @@ SCRIPT_DIR="$(dirname "$0")"
|
||||
# // |-- (script files)
|
||||
|
||||
# Get all services on the server
|
||||
SERVICES_PATH="${SCRIPT_DIR}/../"
|
||||
SERVICES_PATH="${SCRIPT_DIR}/../../"
|
||||
|
||||
# Get all service names
|
||||
SERVICE_NAMES=$(ls "${SERVICES_PATH}")
|
||||
@ -44,8 +44,8 @@ for SERVICE_NAME in ${SERVICE_NAMES}; do
|
||||
# Get the service ports
|
||||
PORTS_FILE="${SERVICE_PATH}/template/ports.sh"
|
||||
if [ -f "${PORTS_FILE}" ]; then
|
||||
# suppress all output from the ports script
|
||||
SERVICE_PORTS=$(bash "${PORTS_FILE}" "${SERVICE_PATH}/config" > /dev/null 2>&1)
|
||||
# capture output from the ports script
|
||||
SERVICE_PORTS=$(bash "${PORTS_FILE}" "${SERVICE_PATH}/config" 2>&1)
|
||||
else
|
||||
SERVICE_PORTS="unknown"
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user