I have a bash shell script which does a bunch of stuff before trying to mongorestore.
mongorestore
I want to make sure that not only MongoDB is up, but it is also re
To test the connection in a loop like you suggest,
until nc -z localhost 27017 do sleep 1 done