# terraform-aws-serverless-webapp **Repository Path**: mirrors_apparentlymart/terraform-aws-serverless-webapp ## Basic Information - **Project Name**: terraform-aws-serverless-webapp - **Description**: Terraform module for deploying "serverless" applications to AWS Lambda and Amazon API Gateway - **Primary Language**: Unknown - **License**: MPL-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-09-24 - **Last Updated**: 2026-01-04 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Terraform AWS Lambda Serverless Application Module This repository contains an opinionated Terraform module for deploying "serverless" web applications to AWS Lambda and exposing them publicly using AWS API Gateway running in its proxy mode. The main "opinion" of this module is that the AWS Lambda versioning and API Gateway "stage" concepts are not important when you are using Terraform, since your Terraform configuration ought to be under version control and so you can easily recover older versions and apply them. This module expects that you will upload code packages to S3 and treat them as immutable once uploaded, and thus the S3 object key will change for each new version to be deployed. A less significant "opinion" is that if you use a custom domain name then you will use ACM for its TLS certificate. ## Usage The following example deploys a NodeJS-based Lambda function and creates a public-facing API Gateway proxy in front of it. ```hcl provider "aws" { region = "us-east-1" } module "app" { source = "apparentlymart/serverless-webapp/aws" lambda_function_name = "TerraformServerlessExample" lambda_execution_role = "${aws_iam_role.lambda_exec.arn}" lambda_runtime = "nodejs4.3" lambda_handler = "main.handler" api_gateway_name = "TerraformServerlessExample" artifact_s3_bucket = "terraform-serverless-example" artifact_s3_object_key = "v1.0.0/example.zip" } resource "aws_iam_role" "lambda_exec" { name = "serverless_example_lambda" assume_role_policy = <