From 208749d01e46a78f593484f00bf912f6f34006fd Mon Sep 17 00:00:00 2001 From: Stefan Reimer Date: Thu, 12 Sep 2024 06:17:31 +0000 Subject: [PATCH] feat: upgrade Alpine to 3.20, libexecinfo fixes, make tests work --- Dockerfile | 9 +++------ run_tests.sh | 1 + 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index 1b589d9..ee329e4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,6 @@ -# https://aws.amazon.com/blogs/aws/new-for-aws-lambda-container-image-support/ -# libexec is missing from >=3.17 - # Stage 1 - bundle base image + runtime -FROM python:3.12-alpine3.19 AS python-alpine -ARG ALPINE="v3.19" +FROM python:3.12-alpine3.20 AS python-alpine +ARG ALPINE="v3.20" # Install GCC (Alpine uses musl but we compile and link dependencies with GCC) RUN echo "@kubezero https://cdn.zero-downtime.net/alpine/${ALPINE}/kubezero" >> /etc/apk/repositories && \ @@ -29,7 +26,7 @@ RUN apk --no-cache add \ libcurl \ libffi-dev \ openssl-dev \ - libexecinfo-dev@kubezero + elfutils-dev # cargo # Install requirements diff --git a/run_tests.sh b/run_tests.sh index fb40eca..f6ff820 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -9,6 +9,7 @@ buildah copy $ctr dev-requirements.txt .flake8 . buildah copy $ctr aws-lambda-rie buildah copy $ctr tests/ tests/ +buildah run $ctr apk add zstd-libs buildah run $ctr pip install -r dev-requirements.txt --target . buildah run $ctr python -m flake8 app.py