diff --git a/Dockerfile b/Dockerfile index 13469f7..9d5487d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,14 +1,16 @@ -FROM public.ecr.aws/lambda/python:3.8 +FROM public.ecr.aws/lambda/python:3.10 -# Copy function code -COPY custom_connector_example ${LAMBDA_TASK_ROOT} -COPY custom_connector_sdk ${LAMBDA_TASK_ROOT} -COPY custom_connector_queryfilter ${LAMBDA_TASK_ROOT} +# Install git for pip dependencies +RUN yum install -y git && yum clean all # Install the function's dependencies using file requirements.txt -# from your project folder. COPY requirements.txt . RUN pip3 install -r ./requirements.txt --target "${LAMBDA_TASK_ROOT}" -# Set the CMD to your handler (could also be done as a parameter override outside of the Dockerfile) -CMD [ "custom_connector_example.handlers.lambda_handler.salesforce_lambda_handler" ] \ No newline at end of file +# Copy function code with proper package structure +COPY custom_connector_example ${LAMBDA_TASK_ROOT}/custom_connector_example +COPY custom_connector_sdk ${LAMBDA_TASK_ROOT}/custom_connector_sdk +COPY custom_connector_queryfilter ${LAMBDA_TASK_ROOT}/custom_connector_queryfilter + +# Set the CMD to your handler +CMD [ "custom_connector_example.handlers.lambda_handler.salesforce_lambda_handler" ] diff --git a/requirements.txt b/requirements.txt index 09bbb91..a9b7370 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,8 +1,6 @@ +-e git+https://github.com/boto/botocore.git@develop#egg=botocore antlr4-python3-runtime==4.9.2 python-dateutil==2.8.2 six==1.16.0 -urllib3==1.26.6 -awslambdaric==1.2.2 setuptools~=65.6.3 -boto3~=1.20.47 jsonschema==4.1.2