1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/gitlab_ynh.git synced 2024-09-03 18:36:35 +02:00

Fix waiting_to_start helper function

This commit is contained in:
Pierre Bourré 2019-01-13 18:39:57 +01:00
parent a019b8d0ca
commit db5512d6ac

View file

@ -152,19 +152,16 @@ waiting_to_start() {
tail -F -n1 "$log_path" > "$templog" &
# get the PID of the tail command
local pid_tail=$!
local inc=0
while ! grep --quiet "${line_match_new}" $templog && ! grep --quiet "${line_match_existing}" $templog
for i in $(seq 1 100)
do
# Timeout
if [ $inc -gt 100 ]
if grep --quiet "${line_match_new}" $templog || grep --quiet "${line_match_existing}" $templog
then
echo "Gitlab has correctly started." >&2
break
fi
sleep 1
echo -n "." >&2
((inc++))
done
echo "Stop Waiting"