We only build Gitaly's UBI images with Go 1.18, but Gitaly is about to
start supporting Go 1.19. Build images for both versions so that Gitaly
can upgrade their CI jobs to test with both versions.
Update the Git version to v2.36.0. While Gitaly doesn't rely on the Git
version at all anymore, it feels like the right thing to do to update it
to something more current than v2.33.0.
We're currently building Gitaly images with three different Postgres
versions. Ultimately though, Gitaly doesn't need Postgres installed in
its images at all: the Postgres server is tied in as a service, and the
only CI job that uses the the Postgres client is using a different image
anyway. One part that had been using the Postgres client in the past was
the logic to wait for Postgres to come up. But this has been migrated to
instead rely on the health-checking logic provided by CI services in
f89ffa3dc (ci: Stop waiting for Postgres manually, 2022-06-14)
Stop installing Postgres in Gitaly images to reduce the number of images
built.
Gitaly is using PgBouncer in its CI pipelines to verify that Praefect
works alright with this proxy for Postgres. While it was initially using
the PgBouncer binary directly, the project has since migrate to set up
PgBouncer as a service via a separate image in 0e5953177 (ci: Tie in
PgBouncer as a service, 2021-12-03). Since then the PgBouncer executable
is not needed anymore in the image used by Gitaly.
Stop installing PgBouncer and remove the architecture we have to build
and install it.
Currently the Gitaly images install the PostgreSQL version available
to the Debian repository. The support scripts in Praefect currently
depend on specific versions of `psql`, so let's be explicit about the
versions used in the image and install PostgreSQL from the PGDG
repository.
This refactors our custom image building to utilize GitLab parallel jobs
with a matrix.
This makes it easier to parse what kind of matrix we are going to build
in our docker images. Furthermore instead of splitting the image name,
we can simply pull the versions of the tools from the environment
variables.
The ultimative reason: Dogfooding