ci: Move specialized tests away from Ubuntu 20.04 and Debian 11.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
This commit is contained in:
Anders Kaseorg 2024-03-25 14:17:18 -07:00
parent e535c96e40
commit ce075fec6c
3 changed files with 30 additions and 30 deletions

View File

@ -39,13 +39,13 @@ jobs:
production_build:
# This job builds a release tarball from the current commit, which
# will be used for all of the following install/upgrade tests.
name: Ubuntu 20.04 production build
name: Ubuntu 22.04 production build
runs-on: ubuntu-latest
# Docker images are built from 'tools/ci/Dockerfile'; the comments at
# the top explain how to build and upload these images.
# Ubuntu 20.04 ships with Python 3.8.10.
container: zulip/ci:focal
# Ubuntu 22.04 ships with Python 3.10.12.
container: zulip/ci:jammy
steps:
- name: Add required permissions
@ -76,21 +76,21 @@ jobs:
uses: actions/cache@v4
with:
path: /__w/.pnpm-store
key: v1-pnpm-store-focal-${{ hashFiles('pnpm-lock.yaml') }}
key: v1-pnpm-store-jammy-${{ hashFiles('pnpm-lock.yaml') }}
- name: Restore python cache
uses: actions/cache@v4
with:
path: /srv/zulip-venv-cache
key: v1-venv-focal-${{ hashFiles('requirements/dev.txt') }}
restore-keys: v1-venv-focal
key: v1-venv-jammy-${{ hashFiles('requirements/dev.txt') }}
restore-keys: v1-venv-jammy
- name: Restore emoji cache
uses: actions/cache@v4
with:
path: /srv/zulip-emoji-cache
key: v1-emoji-focal-${{ hashFiles('tools/setup/emoji/emoji_map.json') }}-${{ hashFiles('tools/setup/emoji/build_emoji') }}-${{ hashFiles('tools/setup/emoji/emoji_setup_utils.py') }}-${{ hashFiles('tools/setup/emoji/emoji_names.py') }}-${{ hashFiles('package.json') }}
restore-keys: v1-emoji-focal
key: v1-emoji-jammy-${{ hashFiles('tools/setup/emoji/emoji_map.json') }}-${{ hashFiles('tools/setup/emoji/build_emoji') }}-${{ hashFiles('tools/setup/emoji/emoji_setup_utils.py') }}-${{ hashFiles('tools/setup/emoji/emoji_names.py') }}-${{ hashFiles('package.json') }}
restore-keys: v1-emoji-jammy
- name: Build production tarball
run: ./tools/ci/production-build
@ -136,12 +136,12 @@ jobs:
# Docker images are built from 'tools/ci/Dockerfile'; the comments at
# the top explain how to build and upload these images.
- docker_image: zulip/ci:focal
name: Ubuntu 20.04 production install and PostgreSQL upgrade with pgroonga
name: Ubuntu 20.04 production install
os: focal
extra-args: ""
- docker_image: zulip/ci:jammy
name: Ubuntu 22.04 production install
name: Ubuntu 22.04 production install and PostgreSQL upgrade with pgroonga
os: jammy
extra-args: ""
@ -151,14 +151,14 @@ jobs:
extra-args: ""
- docker_image: zulip/ci:bullseye
name: Debian 11 production install with custom db name and user
name: Debian 11 production install
os: bullseye
extra-args: --test-custom-db
extra-args: ""
- docker_image: zulip/ci:bookworm
name: Debian 12 production install
name: Debian 12 production install with custom db name and user
os: bookworm
extra-args: ""
extra-args: --test-custom-db
name: ${{ matrix.name }}
container:
@ -202,19 +202,19 @@ jobs:
run: sudo /tmp/production-verify ${{ matrix.extra-args }}
- name: Install pgroonga
if: ${{ matrix.os == 'focal' }}
if: ${{ matrix.os == 'jammy' }}
run: sudo /tmp/production-pgroonga
- name: Verify install after installing pgroonga
if: ${{ matrix.os == 'focal' }}
if: ${{ matrix.os == 'jammy' }}
run: sudo /tmp/production-verify ${{ matrix.extra-args }}
- name: Upgrade postgresql
if: ${{ matrix.os == 'focal' }}
if: ${{ matrix.os == 'jammy' }}
run: sudo /tmp/production-upgrade-pg
- name: Verify install after upgrading postgresql
if: ${{ matrix.os == 'focal' }}
if: ${{ matrix.os == 'jammy' }}
run: sudo /tmp/production-verify ${{ matrix.extra-args }}
- name: Generate failure report string

View File

@ -32,27 +32,27 @@ jobs:
# The comments at the top explain how to build and upload these images.
# Ubuntu 20.04 ships with Python 3.8.10.
- docker_image: zulip/ci:focal
name: Ubuntu 20.04 (Python 3.8, backend + frontend)
name: Ubuntu 20.04 (Python 3.8, backend)
os: focal
include_documentation_tests: false
include_frontend_tests: true
include_frontend_tests: false
# Debian 11 ships with Python 3.9.2.
- docker_image: zulip/ci:bullseye
name: Debian 11 (Python 3.9, backend + documentation)
name: Debian 11 (Python 3.9, backend)
os: bullseye
include_documentation_tests: true
include_documentation_tests: false
include_frontend_tests: false
# Ubuntu 22.04 ships with Python 3.10.4.
# Ubuntu 22.04 ships with Python 3.10.12.
- docker_image: zulip/ci:jammy
name: Ubuntu 22.04 (Python 3.10, backend)
name: Ubuntu 22.04 (Python 3.10, backend + frontend)
os: jammy
include_documentation_tests: false
include_frontend_tests: false
include_frontend_tests: true
# Debian 12 ships with Python 3.11.2.
- docker_image: zulip/ci:bookworm
name: Debian 12 (Python 3.11, backend)
name: Debian 12 (Python 3.11, backend + documentation)
os: bookworm
include_documentation_tests: false
include_documentation_tests: true
include_frontend_tests: false
# Ubuntu 24.04 ships with Python 3.12.2.
- docker_image: zulip/ci:noble

View File

@ -61,9 +61,9 @@ os_info="$(
read -r os_version_id
} <<<"$os_info"
# Pin PostgreSQL on Ubuntu 20.04, so we can test upgrading it
if [ "$os_id $os_version_id" = 'ubuntu 20.04' ]; then
export POSTGRESQL_VERSION=12
# Pin PostgreSQL on Ubuntu 22.04, so we can test upgrading it
if [ "$os_id $os_version_id" = 'ubuntu 22.04' ]; then
export POSTGRESQL_VERSION=14
fi
# Install