Testing AWS Lambda runtime

To reproduce AWS Lambda environments, use Amazon's official lambda images in your tasks.

AWS Lambda-Mimicking Task - Python

jobs:
- name: test-amazon-lambda
plan:
- task: get-boto3-version
config:
platform: linux
image_resource:
type: docker-image
source:
repository: amazon/aws-lambda-python
params:
PYTHONPATH: /var/runtime
run:
path: python3
args:
- -c
- |
import boto3
print(f"Latest Amazon's aws-lambda-python boto3 version is {boto3.__version__}")

The task run produces the following output:

Latest Amazon's aws-lambda-python boto3 version is 1.18.55