feat: add sanitized internal main deployment
Some checks failed
State Corp Backend CI/CD / Quality gate (push) Successful in 5m25s
State Corp Backend CI/CD / Build linux/amd64 images once (push) Successful in 2m44s
State Corp Backend CI/CD / Release dev (push) Failing after 8s
State Corp Backend CI/CD / Refresh and release internal main (push) Has been skipped
State Corp Backend CI/CD / Release customer main (push) Has been skipped
Some checks failed
State Corp Backend CI/CD / Quality gate (push) Successful in 5m25s
State Corp Backend CI/CD / Build linux/amd64 images once (push) Successful in 2m44s
State Corp Backend CI/CD / Release dev (push) Failing after 8s
State Corp Backend CI/CD / Refresh and release internal main (push) Has been skipped
State Corp Backend CI/CD / Release customer main (push) Has been skipped
This commit is contained in:
26
scripts/ci/smoke.sh
Executable file
26
scripts/ci/smoke.sh
Executable file
@@ -0,0 +1,26 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
smoke_url="${1:-}"
|
||||
[[ "${smoke_url}" =~ ^https?:// ]] || {
|
||||
printf 'a complete http(s) smoke URL is required\n' >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
for attempt in $(seq 1 24); do
|
||||
if curl --fail --silent \
|
||||
--connect-timeout 5 \
|
||||
--max-time 15 \
|
||||
--output /dev/null \
|
||||
"${smoke_url}"; then
|
||||
printf 'Smoke check passed.\n'
|
||||
exit 0
|
||||
fi
|
||||
|
||||
printf 'Smoke attempt %s/24 failed; retrying in 5 seconds.\n' "${attempt}" >&2
|
||||
sleep 5
|
||||
done
|
||||
|
||||
printf 'Smoke check failed after 24 attempts.\n' >&2
|
||||
exit 1
|
||||
Reference in New Issue
Block a user