Skip to content

Commit

Permalink
complete Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
tschaffter committed Dec 5, 2024
1 parent e971c89 commit a03970d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion apps/sandbox/lambda-python/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
FROM python:3.13.0-slim-bullseye AS builder

# Install the same version of Poetry as inside the dev container
RUN pip install --no-cache-dir poetry==1.8.3

WORKDIR /app
COPY pyproject.toml poetry.lock ./
RUN poetry export --without-hashes --format=requirements.txt > requirements.txt

FROM public.ecr.aws/lambda/python:3.13

COPY hello_world/app.py requirements.txt ${LAMBDA_TASK_ROOT}/
COPY --from=builder /app/requirements.txt ${LAMBDA_TASK_ROOT}/
COPY sandbox_lambda_python/app.py ${LAMBDA_TASK_ROOT}/

RUN python3.13 -m pip install --no-cache-dir -r requirements.txt -t .

Expand Down

0 comments on commit a03970d

Please sign in to comment.