diff --git a/.github/workflows/pythonpackage.yml b/.github/workflows/pythonpackage.yml index 429d18640b..14f91162cd 100644 --- a/.github/workflows/pythonpackage.yml +++ b/.github/workflows/pythonpackage.yml @@ -16,7 +16,21 @@ jobs: strategy: matrix: python-version: [3.7, 3.8] - TESTING_DB: [sqlite3, postgresql, mysql] + TESTING_DB: [sqlite3, postgresql, mysql] + services: + # Label used to access the service container + postgres: + # Docker Hub image + image: postgres + # Provide the password for postgres + env: + POSTGRES_PASSWORD: postgres + # Set health checks to wait until postgres has started + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 5 steps: - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }}