Skip to content

Commit 5fbb3a1

Browse files
committed
fix: arm images need a special base tag
1 parent 2581f6a commit 5fbb3a1

4 files changed

Lines changed: 4 additions & 5 deletions

File tree

.github/workflows/build-release.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ jobs:
6464
unzip docbox-upload-completion-lambda.zip -d /tmp/processing-lambda
6565
unzip poppler-lambda-layer.zip -d /tmp/processing-lambda
6666
zip -r docbox-upload-completion-lambda-amd64.zip /tmp/processing-lambda
67-
mv /tmp/docbox-upload-completion-lambda-amd64.zip
6867
shell: bash
6968

7069
# Upload the built artifacts
@@ -136,7 +135,6 @@ jobs:
136135
unzip docbox-upload-completion-lambda.zip -d /tmp/processing-lambda
137136
unzip poppler-lambda-layer.zip -d /tmp/processing-lambda
138137
zip -r docbox-upload-completion-lambda-arm64.zip /tmp/processing-lambda
139-
mv /tmp/docbox-upload-completion-lambda-arm64.zip
140138
shell: bash
141139

142140
# Upload the built artifacts

layers/make-poppler-layer-amd64.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
set -euo pipefail
33

44
# Build the container
5-
docker buildx build --platform linux/amd64 -f ./layers/poppler.Dockerfile -t poppler-lambda-layer-amd64 ./layers
5+
docker buildx build --build-arg BASE_IMAGE=public.ecr.aws/lambda/provided:al2023 --platform linux/amd64 -f ./layers/poppler.Dockerfile -t poppler-lambda-layer-amd64 ./layers
66

77
# Run a container and copy out the zip then delete it
88
CONTAINER_ID=$(docker create --platform linux/amd64 poppler-lambda-layer-amd64)

layers/make-poppler-layer-arm64.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
set -euo pipefail
33

44
# Build the container
5-
docker buildx build --platform linux/arm64 -f ./layers/poppler.Dockerfile -t poppler-lambda-layer-arm64 ./layers
5+
docker buildx build --build-arg BASE_IMAGE=public.ecr.aws/lambda/provided:al2023-arm64 --platform linux/arm64 -f ./layers/poppler.Dockerfile -t poppler-lambda-layer-arm64 ./layers
66

77
# Run a container and copy out the zip then delete it
88
CONTAINER_ID=$(docker create --platform linux/arm64 poppler-lambda-layer-arm64)

layers/poppler.Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# Docker for building the layer for poppler support in AWS lambda
2-
FROM public.ecr.aws/lambda/provided:al2023 AS builder
2+
ARG BASE_IMAGE=public.ecr.aws/lambda/provided:al2023
3+
FROM ${BASE_IMAGE} AS builder
34

45
# Install required dependencies
56
RUN dnf -y update && \

0 commit comments

Comments
 (0)