Support for metrics port configuration

This commit is contained in:
NagyZoltanPeter 2024-10-25 12:39:01 +02:00
parent c36c02c31e
commit 30190e12eb
No known key found for this signature in database
GPG Key ID: 16EADB9673B65368
1 changed files with 4 additions and 1 deletions

View File

@ -30,6 +30,7 @@ if [ "${FUNCTION}" = "SENDER" ]; then
SERIVCE_NODE_ADDR=${LIGHTPUSH_SERVICE_PEER:-${LIGHTPUSH_BOOTSTRAP:-}} SERIVCE_NODE_ADDR=${LIGHTPUSH_SERVICE_PEER:-${LIGHTPUSH_BOOTSTRAP:-}}
NODE_ARG=${LIGHTPUSH_SERVICE_PEER:+--service-node="${LIGHTPUSH_SERVICE_PEER}"} NODE_ARG=${LIGHTPUSH_SERVICE_PEER:+--service-node="${LIGHTPUSH_SERVICE_PEER}"}
NODE_ARG=${NODE_ARG:---bootstrap-node="${LIGHTPUSH_BOOTSTRAP}"} NODE_ARG=${NODE_ARG:---bootstrap-node="${LIGHTPUSH_BOOTSTRAP}"}
METRICS_PORT=--metrics-port="${PUBLISHER_METRICS_PORT:-8003}"
fi fi
if [ "${FUNCTION}" = "RECEIVER" ]; then if [ "${FUNCTION}" = "RECEIVER" ]; then
@ -37,6 +38,7 @@ if [ "${FUNCTION}" = "RECEIVER" ]; then
SERIVCE_NODE_ADDR=${FILTER_SERVICE_PEER:-${FILTER_BOOTSTRAP:-}} SERIVCE_NODE_ADDR=${FILTER_SERVICE_PEER:-${FILTER_BOOTSTRAP:-}}
NODE_ARG=${FILTER_SERVICE_PEER:+--service-node="${FILTER_SERVICE_PEER}"} NODE_ARG=${FILTER_SERVICE_PEER:+--service-node="${FILTER_SERVICE_PEER}"}
NODE_ARG=${NODE_ARG:---bootstrap-node="${FILTER_BOOTSTRAP}"} NODE_ARG=${NODE_ARG:---bootstrap-node="${FILTER_BOOTSTRAP}"}
METRICS_PORT=--metrics-port="${RECEIVER_METRICS_PORT:-8003}"
fi fi
if [ -z "${SERIVCE_NODE_ADDR}" ]; then if [ -z "${SERIVCE_NODE_ADDR}" ]; then
@ -98,4 +100,5 @@ exec "${BINARY_PATH}"\
${FUNCTION}\ ${FUNCTION}\
${START_PUBLISHING_AFTER}\ ${START_PUBLISHING_AFTER}\
${MIN_MESSAGE_SIZE}\ ${MIN_MESSAGE_SIZE}\
${MAX_MESSAGE_SIZE} ${MAX_MESSAGE_SIZE}\
${METRICS_PORT}