Skip to content

Commit

Permalink
Improve the wait condition for post-install check
Browse files Browse the repository at this point in the history
  • Loading branch information
archis-polyverse committed Jan 19, 2021
1 parent 872d168 commit e90138b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions install/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,9 @@ ensure_zerotect_running() {
sleep_seconds=$3

if [ ! -z "$sleep_seconds" ]; then
printf " |--> waiting upto $sleep_seconds seconds for zerotect to start"
printf " |--> waiting upto $sleep_seconds seconds"
pid=$(pgrep zerotect)
while [ -z "$pid" ]; do
while ([ $sleep_seconds -gt 0 ]) && (([ -z "$pid" ] && [ "$expected" = "yes" ]) || ([ ! -z "$pid" ] && [ "$expected" = "no" ])); do
printf "."
sleep 1
sleep_seconds="$(($sleep_seconds-1))"
Expand Down

0 comments on commit e90138b

Please sign in to comment.