All Modules
AWSState

Terraform Backend

S3 + DynamoDB for Terraform state management and locking

Usage

module "terraform_backend" {
  source = "github.com/fencepencil/fencepencil-aws-modules//terraform-backend"

  bucket_name = "<bucket_name>"
  lock_table_name = "<lock_table_name>"

  tags = var.tags
}

Inputs (5)

NameTypeDescriptionDefaultRequired
bucket_namestringS3 bucket name for stateyes
lock_table_namestringDynamoDB table name for lockingyes
force_destroyboolAllow bucket to be destroyed with objectsfalseno
kms_key_arnstringOptional KMS key ARN for encryptionnullno
tagsmap(string)Tags to apply to all resources{}no

Outputs (4)

NameDescription
bucket_nameState S3 bucket name
bucket_arnState S3 bucket ARN
lock_table_nameDynamoDB lock table name
lock_table_arnDynamoDB lock table ARN

More AWS Modules

Browse our full library of AWS infrastructure modules.

View all AWS modules