diff --git a/.github/workflows/ci-backend.yml b/.github/workflows/ci-backend.yml index a3560ec5aea42..082bd0c20c5c7 100644 --- a/.github/workflows/ci-backend.yml +++ b/.github/workflows/ci-backend.yml @@ -260,6 +260,13 @@ jobs: # Use PostHog Bot token when not on forks to enable proper snapshot updating token: ${{ github.event.pull_request.head.repo.full_name == github.repository && secrets.POSTHOG_BOT_GITHUB_TOKEN || github.token }} + - name: Install curl + # Used to check if ClickHouse is up within the docker network vs exposing the host port + if: needs.changes.outputs.backend == 'true' + run: | + sudo apt-get update + sudo apt-get install -y curl + - uses: ./.github/actions/run-backend-tests if: needs.changes.outputs.backend == 'true' with: diff --git a/.github/workflows/ci-e2e.yml b/.github/workflows/ci-e2e.yml index 97deeffe6bd2a..536ed87f57c6c 100644 --- a/.github/workflows/ci-e2e.yml +++ b/.github/workflows/ci-e2e.yml @@ -120,6 +120,13 @@ jobs: with: node-version: 18.12.1 + - name: Install curl + # Used to check if ClickHouse is up within the docker network vs exposing the host port + if: needs.changes.outputs.shouldTriggerCypress == 'true' + run: | + sudo apt-get update + sudo apt-get install -y curl + - name: Get pnpm cache directory path if: needs.changes.outputs.shouldTriggerCypress == 'true' id: pnpm-cache-dir diff --git a/.github/workflows/ci-plugin-server.yml b/.github/workflows/ci-plugin-server.yml index 4ee25d612039d..75e06e93ea51e 100644 --- a/.github/workflows/ci-plugin-server.yml +++ b/.github/workflows/ci-plugin-server.yml @@ -209,6 +209,13 @@ jobs: if: needs.changes.outputs.plugin-server == 'true' uses: actions/checkout@v3 + - name: Install curl + # Used to check if ClickHouse is up within the docker network vs exposing the host port + if: needs.changes.outputs.plugin-server == 'true' + run: | + sudo apt-get update + sudo apt-get install -y curl + - name: Stop/Start stack with Docker Compose if: needs.changes.outputs.plugin-server == 'true' run: | diff --git a/bin/check_kafka_clickhouse_up b/bin/check_kafka_clickhouse_up index 4217f70e69309..24cf62d139e17 100755 --- a/bin/check_kafka_clickhouse_up +++ b/bin/check_kafka_clickhouse_up @@ -7,7 +7,7 @@ while true; do nc -z localhost 9092 && break || echo 'Checking Kafka status...' && sleep 1 done -# Check ClickHouse +# Check ClickHouse within Docker Compose network using the service name 'clickhouse' while true; do -curl -s -o /dev/null -I 'http://localhost:8123/' && break || echo 'Checking ClickHouse status...' && sleep 1 + curl -s -o /dev/null -I 'http://clickhouse:8123/' && break || echo 'Checking ClickHouse status...' && sleep 1 done