Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

Example of blue/green deployment of a S3 packaged function

Creates a S3 packaged AWS Lambda function deployed using AWS CodePipeline and CodeDeploy.

usage

terraform init
terraform plan

Note that this example may create resources which cost money. Run terraform destroy to destroy those resources.

deploy

Upload a new zip package to S3 to start the deployment pipeline:

aws s3api put-object --bucket example-ci-{account_id}-{region} --key s3-deployment/package/lambda.zip --body lambda.zip

Requirements

Name Version
terraform >= 1.3
aws >= 5.82.2

Providers

Name Version
aws >= 5.82.2

Modules

Name Source Version
deployment ../../../modules/deployment n/a
fixtures ../../fixtures n/a
lambda ../../../ n/a

Resources

Name Type
aws_lambda_alias.this resource
aws_s3_bucket.source resource
aws_s3_bucket_notification.source resource
aws_s3_bucket_public_access_block.source resource
aws_s3_bucket_versioning.source resource
aws_s3_object.initial resource
aws_caller_identity.current data source
aws_region.current data source

Inputs

Name Description Type Default Required
region n/a string "eu-west-1" no

Outputs

No outputs.