From 03a6e82e3e3b78c65af34e95ec751208d8c3f6b7 Mon Sep 17 00:00:00 2001 From: niksis02 Date: Wed, 16 Sep 2026 18:57:12 +0400 Subject: [PATCH] fix: replace fixed sleep with readiness polling in azurite CI The azurite workflow waited a hardcoded `sleep 40` for the gateway container to compile and start listening before running tests. The container cold-builds `versitygw` from source on every run via `CompileDaemon`, and as the codebase grew that build increasingly exceeded the 40s budget, so tests started against a port with nothing listening yet and failed with connection resets. Poll `http://127.0.0.1:7070/` with `curl` until it responds, bounded by a `timeout`, so the wait scales with actual build time instead of a stale constant. --- .github/workflows/azurite.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/azurite.yml b/.github/workflows/azurite.yml index c1e4b0de..11fb6089 100644 --- a/.github/workflows/azurite.yml +++ b/.github/workflows/azurite.yml @@ -20,8 +20,9 @@ jobs: run: | docker compose -f tests/docker-compose.yml --env-file .env.dev --project-directory . up -d azurite azuritegw - - name: Wait for Azurite to be ready - run: sleep 40 + - name: Wait for services to be ready + run: | + timeout 180 bash -c 'until curl -s -o /dev/null http://127.0.0.1:7070/; do sleep 2; done' - name: Get Dependencies run: |