Commit 9367871f2e958502047c2992395a7b10064d09f3
Committed by
GitHub
1 parent
1c8d58e8
Added filtered state to cassandra service check.
When running thingsboard with docker swarm port is reported as ```filtered``` as rather than ```open```
Showing
1 changed file
with
2 additions
and
2 deletions
... | ... | @@ -19,7 +19,7 @@ |
19 | 19 | dpkg -i /thingsboard.deb |
20 | 20 | |
21 | 21 | if [ "$DATABASE_TYPE" == "cassandra" ]; then |
22 | - until nmap $CASSANDRA_HOST -p $CASSANDRA_PORT | grep "$CASSANDRA_PORT/tcp open" | |
22 | + until nmap $CASSANDRA_HOST -p $CASSANDRA_PORT | grep "$CASSANDRA_PORT/tcp open\|filtered" | |
23 | 23 | do |
24 | 24 | echo "Wait for cassandra db to start..." |
25 | 25 | sleep 10 |
... | ... | @@ -28,7 +28,7 @@ fi |
28 | 28 | |
29 | 29 | if [ "$DATABASE_TYPE" == "sql" ]; then |
30 | 30 | if [ "$SPRING_DRIVER_CLASS_NAME" == "org.postgresql.Driver" ]; then |
31 | - until nmap $POSTGRES_HOST -p $POSTGRES_PORT | grep "$POSTGRES_PORT/tcp open" | |
31 | + until nmap $POSTGRES_HOST -p $POSTGRES_PORT | grep "$POSTGRES_PORT/tcp open\filtered" | |
32 | 32 | do |
33 | 33 | echo "Waiting for postgres db to start..." |
34 | 34 | sleep 10 | ... | ... |