Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/nox.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,37 @@ jobs:
nox-pytest:
runs-on: ubuntu-latest

services:
postgres:
image: postgres:17-alpine
env:
POSTGRES_HOST_AUTH_METHOD: trust
ports:
- 5432:5432
options: >-
--health-cmd="pg_isready -U postgres"
--health-interval=3s
--health-timeout=3s
--health-retries=15

# Specifying the permissions block sets anything not-specified to `none` so we have have to
# re-specify the default read permission to be able to set the write permission.
permissions:
contents: read # For actions/checkout
id-token: write # For codecov OIDC

steps:
# Install PostgreSQL 17 client tools to match the server version
- name: Install PostgreSQL 17 client
run: |
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
sudo apt-get update
sudo apt-get -y install postgresql-client-17

- uses: level12/coppy/gh-actions/nox-run@main
env:
PGUSER: postgres
with:
nox-session: pytest

Expand Down