diff options
Diffstat (limited to 'priv/templates/builtin_hook_wait_for_process')
-rw-r--r-- | priv/templates/builtin_hook_wait_for_process | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/priv/templates/builtin_hook_wait_for_process b/priv/templates/builtin_hook_wait_for_process new file mode 100644 index 0000000..af5994d --- /dev/null +++ b/priv/templates/builtin_hook_wait_for_process @@ -0,0 +1,17 @@ +#!/bin/bash + +# loop until the VM starts responding to pings +while ! $(relx_nodetool "ping">/dev/null) +do + sleep 1 +done + +# loop until the name provided as argument gets +# registered +while true +do + if [ "$(relx_nodetool eval "whereis($1).")" != "undefined" ] + then + break + fi +done |