@@ -122,12 +122,21 @@ jobs:
122122 with :
123123 ruby-version : ${{ matrix.ruby-version }}
124124 bundler-cache : true # runs 'bundle install' and caches installed gems automatically
125+ - name : Install PostgreSQL 17 client
126+ run : |
127+ sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
128+ wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
129+ sudo apt-get update
130+ sudo apt-get install -y postgresql-client-17
125131 - name : Setup gdiff
126132 run : |
127133 sudo ln -s /usr/bin/diff /usr/bin/gdiff || true
128134 - name : Setup database
129135 run : |
130136 PGPASSWORD=postgres psql -h localhost -U postgres -c "CREATE USER arjdbc WITH SUPERUSER CREATEDB LOGIN PASSWORD 'arjdbc';"
137+ echo "Testing connection as arjdbc user..."
138+ PGPASSWORD=arjdbc psql -h localhost -d postgres -U arjdbc -c '\l'
139+ echo "Exit status: $?"
131140 PGPASSWORD=arjdbc psql -h localhost -d postgres -c "create database activerecord_unittest;" -U arjdbc
132141 PGPASSWORD=arjdbc psql -h localhost -d postgres -c "create database activerecord_unittest2;" -U arjdbc
133142 - name : Build
@@ -273,9 +282,20 @@ jobs:
273282 with :
274283 ruby-version : ${{ matrix.ruby-version }}
275284 bundler-cache : true # runs 'bundle install' and caches installed gems automatically
285+ - name : Install PostgreSQL 17 client
286+ run : |
287+ sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
288+ wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
289+ sudo apt-get update
290+ sudo apt-get install -y postgresql-client-17
276291 - name : Setup PostgreSQL user
277292 run : |
278293 PGPASSWORD=postgres psql -h localhost -U postgres -c "CREATE USER arjdbc WITH SUPERUSER CREATEDB LOGIN PASSWORD 'arjdbc';"
294+ - name : Test PostgreSQL connection
295+ run : |
296+ echo "Testing connection as arjdbc user..."
297+ PGPASSWORD=arjdbc psql -h localhost -d postgres -U arjdbc -c '\l'
298+ echo "Exit status: $?"
279299 - name : Build
280300 run : |
281301 rake jar
0 commit comments