
- Add a shellcheck linter for the scripts in the multinode framework - Update all scripting to comply with shellcheck - Move linting job to Ubuntu Bionic as the multinode gate now requires Bionic versions of libvirt Change-Id: Ibee645331421e1e6cecd4e3daa8e9c321dce5523
18 lines
535 B
Bash
18 lines
535 B
Bash
#!/bin/bash
|
|
|
|
promenade_health_check() {
|
|
VIA=${1}
|
|
log "Checking Promenade API health"
|
|
MAX_HEALTH_ATTEMPTS=6
|
|
for attempt in $(seq ${MAX_HEALTH_ATTEMPTS}); do
|
|
if ssh_cmd "${VIA}" curl -v --fail "${PROMENADE_BASE_URL}/api/v1.0/health"; then
|
|
log "Promenade API healthy"
|
|
break
|
|
elif [[ $attempt == "${MAX_HEALTH_ATTEMPTS}" ]]; then
|
|
log "Promenade health check failed, max retries (${MAX_HEALTH_ATTEMPTS}) exceeded."
|
|
exit 1
|
|
fi
|
|
sleep 10
|
|
done
|
|
}
|