Skip to content

Commit 0d489f1

Browse files
committed
fix: correct Amazon Linux build stages for the prebuilt dependency
Install full gnupg2 on Amazon Linux 2023: The AL2023 base image ships gnupg2-minimal, which provides gpg but no gpg-agent. gpg 2.3 needs the agent even to import a public key, so the release-artifact verification failed in the Build Docker image step. Pull full gnupg2 with --allowerasing to replace the minimal variant. Restore /usr/local lib path in Amazon Linux build stages: Removing the modern-CMake install block also dropped its PATH and LD_LIBRARY_PATH env vars, which the stage-1 Python (built --enable-shared into /usr/local) needs to load libpython at build time. Restore them in the AL2 and AL2023 build-image stages.
1 parent 371fc8a commit 0d489f1

2 files changed

Lines changed: 11 additions & 3 deletions

File tree

‎tests/integration/docker/Dockerfile.echo.amazonlinux2‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,11 @@ RUN yum install -y \
6767
gnupg2 \
6868
wget
6969

70+
# The stage-1 Python is built with --enable-shared into /usr/local, so the
71+
# loader needs /usr/local/lib to run it.
72+
ENV PATH=/usr/local/bin:$PATH
73+
ENV LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
74+
7075

7176
# Include global args in this stage of the build
7277
ARG RIC_BUILD_DIR="/home/build/"

‎tests/integration/docker/Dockerfile.echo.amazonlinux2023‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,7 @@ FROM python-amazonlinux-builder AS build-image
5353
ARG RUNTIME_VERSION
5454
ARG ARCHITECTURE
5555

56-
# Install build dependencies (curl built from source; prebuilt aws-lambda-cpp
57-
# fetched with wget and GPG-verified with gnupg2)
58-
RUN dnf install -y \
56+
RUN dnf install -y --allowerasing \
5957
tar \
6058
gzip \
6159
make \
@@ -68,6 +66,11 @@ RUN dnf install -y \
6866
wget \
6967
sqlite-devel
7068

69+
# The stage-1 Python is built with --enable-shared into /usr/local, so the
70+
# loader needs /usr/local/lib to run it.
71+
ENV PATH=/usr/local/bin:$PATH
72+
ENV LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
73+
7174

7275
# Include global args in this stage of the build
7376
ARG RIC_BUILD_DIR="/home/build/"

0 commit comments

Comments
 (0)