mirror of
https://github.com/freeipa/ansible-freeipa.git
synced 2026-07-25 00:44:42 +00:00
utils/setup_test_container.sh: Wait till systemd-journald is running
This ensures that systemctl list-jobs could be executed and it will be waited till the list of jobs is empty.
This commit is contained in:
@@ -79,6 +79,20 @@ shift
|
|||||||
prepare_container "${scenario}" "${IMAGE_TAG}"
|
prepare_container "${scenario}" "${IMAGE_TAG}"
|
||||||
start_container "${scenario}"
|
start_container "${scenario}"
|
||||||
|
|
||||||
|
log info "Wait till systemd-journald is running"
|
||||||
|
max=20
|
||||||
|
wait=2
|
||||||
|
count=0
|
||||||
|
while ! podman exec "${scenario}" ps -x | grep -q "systemd-journald"
|
||||||
|
do
|
||||||
|
if [ $count -ge $max ]; then
|
||||||
|
die "Timeout: systemd-journald is not starting up"
|
||||||
|
fi
|
||||||
|
count=$((count+1))
|
||||||
|
log none "Waiting ${wait} seconds .."
|
||||||
|
sleep ${wait}
|
||||||
|
done
|
||||||
|
|
||||||
# wait for FreeIPA services to be available (usually ~45 seconds)
|
# wait for FreeIPA services to be available (usually ~45 seconds)
|
||||||
log info "Wait for container to be initialized."
|
log info "Wait for container to be initialized."
|
||||||
wait=15
|
wait=15
|
||||||
|
|||||||
Reference in New Issue
Block a user