This project contains source code and supporting files for a serverless application that you can deploy with the SAM CLI. It includes the following files and folders.
lambda-flask-proxy
- Code for the application's Lambda function and Project Dockerfile.events
- Invocation events that you can use to invoke the function.tests
- Unit tests for the application code.template.yaml
- A template that defines the application's AWS resources.
The application uses several AWS resources. These resources are defined in the template.yaml
file in this project. You can update the template to add AWS resources through the same deployment process that updates your application code.
The Serverless Application Model Command Line Interface (SAM CLI) is an extension of the AWS CLI that adds functionality for building and testing Lambda applications. It uses Docker to run your functions in an Amazon Linux environment that matches Lambda. It can also emulate your application's build environment and API.
To use the SAM CLI, you need the following tools.
- SAM CLI - Install the SAM CLI
- Docker - Install Docker community edition
You may need the following for local testing.
To build and deploy your application for the first time, run the following in your shell:
sam build -u
sam deploy -g