text
Docker Lambda Layer
Open Docker and in the terminal type
Pull the latest Ubuntu image
Create a new container with this image.
Update
Install python and pip
You will be asked some options about location - it’s ok to select anything here.
Check the Python version.
In case you need to install another version of python!
Steps
Install pip
Install aws-cli.
Download the aws-cli installation script.
Run the installer
Step 4: Install required libraries and package the lambda layer.
Create a new directory for the installation.
Install the duck-db library.
Package your lambda layer
Configure the default region, secret key, and secret access key
Key ID:
Secret:
Default region: eu-north-1
Deploy the lambda
aws lambda publish-layer-version --layer-name duckdb1_1_3-3_12-layer --zip-file fileb://duckdb1.1.3-3.12-layer.zip --compatible-runtimes python3.12
Layer name can only include:
- Letters (
a-z
,A-Z
) - Numbers (
0-9
) - Hyphens ()
- Underscores (
_
)