aboutsummaryrefslogtreecommitdiffstats
path: root/vnfs/vLBMS/scripts/run_health.sh
diff options
context:
space:
mode:
Diffstat (limited to 'vnfs/vLBMS/scripts/run_health.sh')
-rw-r--r--vnfs/vLBMS/scripts/run_health.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/vnfs/vLBMS/scripts/run_health.sh b/vnfs/vLBMS/scripts/run_health.sh
new file mode 100644
index 00000000..ed3b0423
--- /dev/null
+++ b/vnfs/vLBMS/scripts/run_health.sh
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+SERVICE=$(cat /opt/config/service.txt)
+
+PID=$(pgrep $SERVICE)
+if [[ -z $PID ]]; then
+ echo "unhealthy" > status.txt
+else
+ echo "healthy" > status.txt
+fi