diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0e0cf0e..3a5a304 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,7 +25,7 @@ jobs: npm run build - name: Start environment run: | - docker compose up -d + docker compose -f compose.test.yml up -d - name: Run test run: | npm run test diff --git a/compose.test.yml b/compose.test.yml index f9289d6..ab9376a 100644 --- a/compose.test.yml +++ b/compose.test.yml @@ -7,3 +7,7 @@ services: - 5432:5432 volumes: - ./mockup-data.sql:/docker-entrypoint-initdb.d/data.sql + healthcheck: + test: ["CMD-SHELL", "pg_isready"] + interval: 1s + retries: 30