summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
Diffstat (limited to 'build')
-rw-r--r--build/ves-agent/start.sh9
-rw-r--r--build/ves-collector/start.sh16
2 files changed, 20 insertions, 5 deletions
diff --git a/build/ves-agent/start.sh b/build/ves-agent/start.sh
index 0476316..fce0c74 100644
--- a/build/ves-agent/start.sh
+++ b/build/ves-agent/start.sh
@@ -38,7 +38,14 @@ EOF
cat ves_app_config.conf
echo "ves_mode=$ves_mode"
-python ves_app.py --events-schema=$ves_mode.yaml --loglevel DEBUG \
+
+if [[ "$ves_loglevel" == "" ]]; then
+ ves_loglevel=ERROR
+fi
+
+python ves_app.py --events-schema=$ves_mode.yaml --loglevel $ves_loglevel \
--config=ves_app_config.conf
+
+# Dump ves_app.log if the command above exits (fails)
echo "*** ves_app.log ***"
cat ves_app.log
diff --git a/build/ves-collector/start.sh b/build/ves-collector/start.sh
index 1c41778..be30c9a 100644
--- a/build/ves-collector/start.sh
+++ b/build/ves-collector/start.sh
@@ -34,7 +34,15 @@ sed -i -- "s~vel_topic_name = example_vnf~vel_topic_name = $ves_topic~g" \
sed -i -- "/vel_topic_name = /a influxdb = $ves_influxdb_host" \
evel-test-collector/config/collector.conf
-python /opt/ves/evel-test-collector/code/collector/monitor.py \
- --config /opt/ves/evel-test-collector/config/collector.conf \
- --influxdb $ves_influxdb_host \
- --section default > /opt/ves/monitor.log 2>&1
+if [[ "$ves_loglevel" != "" ]]; then
+ python /opt/ves/evel-test-collector/code/collector/monitor.py \
+ --config /opt/ves/evel-test-collector/config/collector.conf \
+ --influxdb $ves_influxdb_host \
+ --section default > /opt/ves/monitor.log 2>&1
+else
+ python /opt/ves/evel-test-collector/code/collector/monitor.py \
+ --config /opt/ves/evel-test-collector/config/collector.conf \
+ --influxdb $ves_influxdb_host \
+ --section default
+fi
+