Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regress fixes for PG13 - PG16 and simplification #251

Merged
merged 2 commits into from
May 18, 2023
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
25 changes: 19 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,31 @@ jobs:
- { PGVER: 13 }
- { PGVER: 14 }
- { PGVER: 15 }
# - { PGVER: 16 }
- { PGVER: 16 }

runs-on: ubuntu-latest
steps:

- name: 'Check Out'
uses: actions/checkout@v3

- name: 'Force apt.postgresql.org to have higher priority'
run: |
cat << EOF >> ./pgdg.pref
Package: *
Pin: release o=apt.postgresql.org
Pin-Priority: 600
EOF
sudo cp ./pgdg.pref /etc/apt/preferences.d/
sudo apt update

- name: 'Install GDAL'
run: |
sudo add-apt-repository ppa:ubuntugis/ppa
sudo apt-get update
sudo apt-get install libgdal-dev

- name: 'Install PostgreSQL'
run: |
sudo apt-get purge postgresql-*
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg-snapshot main ${{ matrix.ci.PGVER }}" > /etc/apt/sources.list.d/pgdg.list'
curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/apt.postgresql.org.gpg >/dev/null
sudo apt-get update
Expand All @@ -45,16 +54,20 @@ jobs:
export PGDATA=/var/lib/postgresql/${{ matrix.ci.PGVER }}/main
export PGETC=/etc/postgresql/${{ matrix.ci.PGVER }}/main
export PGBIN=/usr/lib/postgresql/${{ matrix.ci.PGVER }}/bin
export RUNNER_USER=`whoami`
sudo chmod -R 755 /home/${RUNNER_USER}
# sudo su postgres -c "$PGBIN/pg_ctl --pgdata $PGDATA stop"
# sudo $PGBIN/pg_ctlcluster ${{ matrix.ci.PGVER }} main stop
sudo cp ./ci/pg_hba.conf $PGETC/pg_hba.conf
sudo su postgres -c "$PGBIN/pg_ctl --pgdata $PGDATA start -o '-c config_file=$PGETC/postgresql.conf -p 5432'"
sudo systemctl stop postgresql
sudo pg_ctlcluster ${{ matrix.ci.PGVER }} main start
sudo pg_lsclusters
#sudo systemctl restart postgresql
#sudo su postgres -c "$PGBIN/pg_ctl --pgdata $PGDATA start -o '-c config_file=$PGETC/postgresql.conf -p 5432'"

- name: 'Build & Test'
run: |
export PATH=/usr/lib/postgresql/${{ matrix.ci.PGVER }}/bin/:$PATH
PG_CFLAGS=-Werror make
sudo make install
PGUSER=postgres make installcheck || (cat regression.diffs && /bin/false)