File tree Expand file tree Collapse file tree 1 file changed +20
-7
lines changed
Expand file tree Collapse file tree 1 file changed +20
-7
lines changed Original file line number Diff line number Diff line change @@ -18,11 +18,20 @@ jobs:
1818 fail-fast : false
1919 runs-on : ubuntu-latest
2020 container :
21- image : postgres:${{ matrix.pg_version }}
21+ image : ubuntu:22.04 # main job container
2222 options : --user root
23- env :
24- PGDATA : $HOME/data
25- PG_BRANCH : ${{ format('REL_{0}_STABLE', matrix.pg_version) }}
23+ services :
24+ postgres :
25+ image : postgres:${{ matrix.pg_version }}
26+ env :
27+ POSTGRES_PASSWORD : postgres
28+ ports :
29+ - 5432:5432
30+ options : >-
31+ --health-cmd "pg_isready -U postgres"
32+ --health-interval 5s
33+ --health-timeout 5s
34+ --health-retries 5
2635
2736 steps :
2837 # Checkout shared_ispell
@@ -59,14 +68,18 @@ jobs:
5968 # Create extension
6069 - name : Create extension
6170 run : |
62- createdb test
63- psql -d test -c "CREATE EXTENSION shared_ispell;"
71+ export PGUSER=postgres
72+ export PGPASSWORD=postgres
73+ createdb -h localhost -p 5432 test
74+ psql -h localhost -p 5432 -U postgres -d test -c "CREATE EXTENSION shared_ispell;"
6475
6576 # Run SQL tests
6677 - name : Run SQL tests
6778 run : |
79+ export PGUSER=postgres
80+ export PGPASSWORD=postgres
6881 for f in sql/*.sql; do
6982 echo "Running $f"
70- psql -d test -f "$f"
83+ psql -h localhost -p 5432 -U postgres - d test -f "$f"
7184 done
7285
You can’t perform that action at this time.
0 commit comments