Skip to content

Commit

Permalink
[ansible/venv] Don't start if /tmp/combo_locks doesn't exit
Browse files Browse the repository at this point in the history
  • Loading branch information
goldyfruit committed Oct 15, 2024
1 parent ef76901 commit 676c4a3
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@ combo_locks_path=/tmp/combo_locks
attempt_counter=0
max_attempt=10

# Wait for other OVOS compoenents to start
# Wait for other OVOS compoenents to start, if /tmp/combo_locks
# directory is not created by other components then ovos-phal-admin
# will not start as a deeper issue exists.
while ! [ -d "$combo_locks_path" ]; do
if [ "$attempt_counter" -lt "$max_attempt" ]; then
echo "Trying to start ovos-phal-admin systemd unit... Attempt ${attempt_counter}/${max_attempt}"
((attempt_counter++))
echo "Trying to start ovos-phal-admin systemd unit... Attempt ${attempt_counter}/${max_attempt}"
sleep 1
fi
mkdir "$combo_locks_path"
chown {{ ovos_installer_user }}: -R "$combo_locks_path"
done

# Starst ovos_PHAL_admin Python binary
Expand Down

0 comments on commit 676c4a3

Please sign in to comment.