summaryrefslogtreecommitdiffstats
path: root/testapi/htmlize/finish.sh
diff options
context:
space:
mode:
Diffstat (limited to 'testapi/htmlize/finish.sh')
-rw-r--r--testapi/htmlize/finish.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/testapi/htmlize/finish.sh b/testapi/htmlize/finish.sh
new file mode 100644
index 0000000..dc3aa86
--- /dev/null
+++ b/testapi/htmlize/finish.sh
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+
+# Stop opnfv-testapi server
+proc_number=`ps -ef | grep opnfv-testapi | grep -v grep | wc -l`
+
+if [ $proc_number -gt 0 ]; then
+ procs=`ps -ef | grep opnfv-testapi | grep -v grep`
+ echo "Kill opnfv-testapi server $procs"
+ ps -ef | grep opnfv-testapi | grep -v grep | awk '{print $2}' | xargs kill -kill &>/dev/null
+fi