Skip to content

Commit

Permalink
fix: ajusta poetry no dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
nathansouzaa3 committed Oct 8, 2024
1 parent 145395f commit e6e6160
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions deployment/docker/Dockerfile.lambda
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
# Usar a imagem base do AWS Lambda com Python
FROM public.ecr.aws/lambda/python:3.10

# Instala o Poetry via pip
RUN pip install poetry

# Copia o arquivo pyproject.toml e poetry.lock (se existir) para instalar dependências
COPY pyproject.toml poetry.lock* ./

# Instala as dependências com o Poetry
RUN poetry config virtualenvs.create false && poetry install --no-dev
# Configurar o Poetry para não criar virtualenv
RUN poetry config virtualenvs.create false

# Verificar configuração do Poetry
RUN poetry config --list

RUN poetry install --no-dev

# Copiar o código da função Lambda e a pasta src
COPY artifacts/ artifacts/
COPY deployment/lambda/app/lambda_function.py ./
COPY src/ src/
COPY config/ config/

# Comando que será executado quando a função Lambda for invocada
CMD ["lambda_function.lambda_handler"]

0 comments on commit e6e6160

Please sign in to comment.