summary refs log tree commit diff
diff options
context:
space:
mode:
authorSean Quah <8349537+squahtx@users.noreply.github.com>2022-11-09 10:32:52 +0000
committerGitHub <noreply@github.com>2022-11-09 10:32:52 +0000
commit22d46db0eae000830154bba8916d8d53458dc351 (patch)
tree2f69bf7644784ec03724ba95db1a3d7f94d1ecfa
parentRemove support for PostgreSQL 10 (#14392) (diff)
downloadsynapse-22d46db0eae000830154bba8916d8d53458dc351.tar.xz
Test against PostgreSQL 15 in CI (#14394)
Resolves #14170.

Signed-off-by: Sean Quah <seanq@matrix.org>
Diffstat (limited to '')
-rwxr-xr-x.ci/scripts/calculate_jobs.py2
-rw-r--r--.github/workflows/tests.yml11
-rw-r--r--changelog.d/14394.misc1
3 files changed, 12 insertions, 2 deletions
diff --git a/.ci/scripts/calculate_jobs.py b/.ci/scripts/calculate_jobs.py
index b48174bea2..0cdc20e19c 100755
--- a/.ci/scripts/calculate_jobs.py
+++ b/.ci/scripts/calculate_jobs.py
@@ -64,7 +64,7 @@ if not IS_PR:
         {
             "python-version": "3.11",
             "database": "postgres",
-            "postgres-version": "14",
+            "postgres-version": "15",
             "extras": "all",
         }
     )
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index 2bc237a0ba..ec5ab79f9c 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -412,7 +412,7 @@ jobs:
             postgres-version: "11"
 
           - python-version: "3.11"
-            postgres-version: "14"
+            postgres-version: "15"
 
     services:
       postgres:
@@ -430,6 +430,15 @@ jobs:
 
     steps:
       - uses: actions/checkout@v3
+      - name: Add PostgreSQL apt repository
+        # We need a version of pg_dump that can handle the version of
+        # PostgreSQL being tested against. The Ubuntu package repository lags
+        # behind new releases, so we have to use the PostreSQL apt repository.
+        # Steps taken from https://www.postgresql.org/download/linux/ubuntu/
+        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
       - run: sudo apt-get -qq install xmlsec1 postgresql-client
       - uses: matrix-org/setup-python-poetry@v1
         with:
diff --git a/changelog.d/14394.misc b/changelog.d/14394.misc
new file mode 100644
index 0000000000..8b816eb0a3
--- /dev/null
+++ b/changelog.d/14394.misc
@@ -0,0 +1 @@
+Test against PostgreSQL 15 in CI.