jasmineWen | 85d9d73 | 2018-03-06 16:13:35 +0000 | [diff] [blame] | 1 | |
Priyanka Jain | c07e1d1 | 2018-05-03 12:52:04 +0000 | [diff] [blame^] | 2 | NAME=$(/consul/bin/kubectl -n {{ include "common.namespace" . }} get pod | grep -o "aai-data-router[^[:space:]]*") |
jasmineWen | 85d9d73 | 2018-03-06 16:13:35 +0000 | [diff] [blame] | 3 | |
| 4 | if [ -n "$NAME" ]; then |
Priyanka Jain | c07e1d1 | 2018-05-03 12:52:04 +0000 | [diff] [blame^] | 5 | if /consul/bin/kubectl -n {{ include "common.namespace" . }} exec -it $NAME -- ps -efww | grep 'java' | grep 'data-router' > /dev/null; then |
jasmineWen | 85d9d73 | 2018-03-06 16:13:35 +0000 | [diff] [blame] | 6 | |
| 7 | echo Success. Synapse process is running. 2>&1 |
| 8 | exit 0 |
| 9 | else |
| 10 | echo Failed. Synapse process is not running. 2>&1 |
| 11 | exit 1 |
| 12 | fi |
| 13 | else |
| 14 | echo Failed. Synapse container is offline. 2>&1 |
| 15 | exit 1 |
| 16 | fi |