This is an automated email from the ASF dual-hosted git repository. junouyang pushed a commit to branch chore/ci-minio-healthcheck-new in repository https://gitbox.apache.org/repos/asf/incubator-opendal.git
commit c3be8fc74bdee49ec6613a4bdcc5b7a7c3636b99 Author: owl <[email protected]> AuthorDate: Tue Aug 22 11:42:44 2023 +0800 chore(ci): offload healthcheck logic to docker-compose config --- .github/workflows/service_test_s3.yml | 5 ----- core/src/services/s3/fixtures/docker-compose-minio.yml | 5 +++++ 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/service_test_s3.yml b/.github/workflows/service_test_s3.yml index b83b89dd2..80ed0ee4e 100644 --- a/.github/workflows/service_test_s3.yml +++ b/.github/workflows/service_test_s3.yml @@ -146,11 +146,6 @@ jobs: working-directory: core/src/services/s3/fixtures run: | docker-compose -f docker-compose-minio.yml up -d - while :; do - echo "waiting minio docker to be ready" - [[ "$(curl -I http://127.0.0.1:9000/minio/health/live 2>/dev/null | head -n 1 | cut -d$' ' -f2)" == "200" ]] && break - sleep 1 - done - name: Setup test bucket run: | curl -O https://dl.min.io/client/mc/release/linux-amd64/mc diff --git a/core/src/services/s3/fixtures/docker-compose-minio.yml b/core/src/services/s3/fixtures/docker-compose-minio.yml index 0e47e8d49..53a0217c3 100644 --- a/core/src/services/s3/fixtures/docker-compose-minio.yml +++ b/core/src/services/s3/fixtures/docker-compose-minio.yml @@ -25,3 +25,8 @@ services: environment: MINIO_ACCESS_KEY: "minioadmin" MINIO_SECRET_KEY: "minioadmin" + healthcheck: + test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"] + interval: 30s + timeout: 20s + retries: 3 \ No newline at end of file
