From 86750f8629e4e9b33542edd92f0c578fe5ffb84a Mon Sep 17 00:00:00 2001 From: Brandon Pitman Date: Fri, 12 May 2023 14:25:55 -0700 Subject: [PATCH] Pin Postgres container to 14.7-alpine. (#1360) * Pin Postgres container to 14.7-alpine. This is a temporary workaround to an issue in the latest version of the Postgres containers, and will be reverted once a fix is available. * Also pin ephemeral datastore container version. --- Dockerfile.interop_aggregator | 3 ++- aggregator_core/src/datastore/test_util.rs | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Dockerfile.interop_aggregator b/Dockerfile.interop_aggregator index d56ac80cb..88bf9edf6 100644 --- a/Dockerfile.interop_aggregator +++ b/Dockerfile.interop_aggregator @@ -33,7 +33,8 @@ RUN --mount=type=cache,target=/usr/local/cargo/registry \ cp /src/target/$PROFILE/aggregation_job_driver /aggregation_job_driver && \ cp /src/target/$PROFILE/collection_job_driver /collection_job_driver -FROM postgres:14-alpine +# TODO(#1359): switch back to postgres:14-alpine once possible +FROM postgres:14.7-alpine RUN mkdir /logs && mkdir /etc/janus RUN apk add --update supervisor && rm -rf /tmp/* /var/cache/apk/* COPY db /etc/janus/migrations diff --git a/aggregator_core/src/datastore/test_util.rs b/aggregator_core/src/datastore/test_util.rs index b6a6f172f..625c7da8d 100644 --- a/aggregator_core/src/datastore/test_util.rs +++ b/aggregator_core/src/datastore/test_util.rs @@ -48,8 +48,9 @@ impl EphemeralDatabase { move || { // Start an instance of Postgres running in a container. let container_client = testcontainers::clients::Cli::default(); + // TODO(#1359): switch back to postgres:14-alpine once possible let db_container = container_client - .run(RunnableImage::from(Postgres::default()).with_tag("14-alpine")); + .run(RunnableImage::from(Postgres::default()).with_tag("14.7-alpine")); const POSTGRES_DEFAULT_PORT: u16 = 5432; let port_number = db_container.get_host_port_ipv4(POSTGRES_DEFAULT_PORT); trace!("Postgres container is up with port {port_number}");