diff --git a/.github/workflows/sqlx.yml b/.github/workflows/sqlx.yml index 452dcff5ab..8ba5907189 100644 --- a/.github/workflows/sqlx.yml +++ b/.github/workflows/sqlx.yml @@ -231,6 +231,8 @@ jobs: - run: | docker compose -f tests/docker-compose.yml run -d -p 5432:5432 --name postgres_${{ matrix.postgres }} postgres_${{ matrix.postgres }} + + - run: | docker exec postgres_${{ matrix.postgres }} bash -c "until pg_isready; do sleep 1; done" # Create data dir for offline mode @@ -302,15 +304,31 @@ jobs: # but `PgLTree` should just fall back to text format RUSTFLAGS: --cfg postgres_${{ matrix.postgres }} - # client SSL authentication + postgres-ssl-auth: + name: Postgres SSL Auth + runs-on: ubuntu-24.04 + strategy: + matrix: + postgres: [ 13, 17 ] + runtime: [ async-std, tokio ] + tls: [ native-tls, rustls-aws-lc-rs, rustls-ring ] + needs: check + timeout-minutes: 30 + steps: + - uses: actions/checkout@v4 + + - name: Setup Rust + run: rustup show active-toolchain || rustup toolchain install + + - uses: Swatinem/rust-cache@v2 - run: | - docker stop postgres_${{ matrix.postgres }} docker compose -f tests/docker-compose.yml run -d -p 5432:5432 --name postgres_${{ matrix.postgres }}_client_ssl postgres_${{ matrix.postgres }}_client_ssl + + - run: | docker exec postgres_${{ matrix.postgres }}_client_ssl bash -c "until pg_isready; do sleep 1; done" - - if: matrix.tls != 'none' - run: > + - run: > cargo test --no-default-features --features any,postgres,macros,_unstable-all-types,runtime-${{ matrix.runtime }},tls-${{ matrix.tls }} diff --git a/tests/docker-compose.yml b/tests/docker-compose.yml index 89ca096169..7e2599d997 100644 --- a/tests/docker-compose.yml +++ b/tests/docker-compose.yml @@ -1,5 +1,3 @@ -version: "3" - services: # # MySQL 8.x, 5.7.x