blob: a8babec102f5216718f46b4c061d72348d951b0e [file] [log] [blame]
jasmineWen85d9d732018-03-06 16:13:35 +00001
Priyanka Jainc07e1d12018-05-03 12:52:04 +00002NAME=$(/consul/bin/kubectl -n {{ include "common.namespace" . }} get pod | grep -o "aai-model-loader[^[:space:]]*")
jasmineWen85d9d732018-03-06 16:13:35 +00003
4if [ -n "$NAME" ]; then
Priyanka Jainc07e1d12018-05-03 12:52:04 +00005 if /consul/bin/kubectl -n {{ include "common.namespace" . }} exec -it $NAME -- ps -efww | grep 'java' | grep 'model-loader' > /dev/null; then
jasmineWen85d9d732018-03-06 16:13:35 +00006
7 echo Success. Model Loader process is running. 2>&1
8 exit 0
9 else
10 echo Failed. Model Loader process is not running. 2>&1
11 exit 1
12 fi
13else
14 echo Failed. Model Loader container is offline. 2>&1
15 exit 1
16fi