lb-s3-bucket

cloudposse/lb-s3-bucket/aws

Terraform Module HCL AWS

Terraform module to provision an S3 bucket with built in IAM policy to allow AWS Load Balancers to ship access logs

Install
module "lb-s3-bucket" {
source = "cloudposse/lb-s3-bucket/aws"
version = "0.20.0"
}
⭐ Source on GitHub 📦 Registry page
README

Terraform module to provision an S3 bucket with built in IAM policy to allow AWS Load Balancers to ship access logs. > [!TIP] > #### 👽 Use Atmos with Terraform > Cloud Posse uses atmos to easily orchestrate multiple environments using Terraform. > Works with Github Actions, Atlantis, or Spacelift. > > > Watch demo of using Atmos with Terraform > > Example of running atmos to manage infrastructure from our Quick Start tutorial. > Usage For a complete example, see examples/complete. For automated tests of the complete example using bats and Terratest (which tests and deploys the example on AWS), see test. ``hcl module "s3_bucket" { source = "cloudposse/lb-s3-bucket/aws" # Cloud Posse recommends pinning every module to a specific version # version = "x.x.x" namespace = "eg" stage = "test" nam

Inputs (35)
NameTypeDescriptionDefault
force_destroyboolWhen `true`, permits a non-empty S3 bucket to be deleted by first deleting all ofalse
attributeslist(string)ID element. Additional attributes (e.g. `workers` or `cluster`) to add to `id`, []
tagsmap(string)Additional tags (e.g. `{'BusinessUnit': 'XYZ'}`). Neither the tag keys nor the t{}
standard_transition_daysnumber(Deprecated, use `lifecycle_configuration_rules` instead) Number of days to pers30
allow_ssl_requests_onlyboolRequire requests to use Secure Socket Layer (HTTPS/SSL).true
environmentstringID element. Usually used for region e.g. 'uw2', 'us-west-2', OR role 'prod', 'stnull
lifecycle_prefixstring(Deprecated, use `lifecycle_configuration_rules` instead) Prefix filter. Used to""
bucket_namestringBucket name. If provided, the bucket will be created with this name instead of gnull
contextanySingle object for setting entire context at once. See description of individual { "additional_tag_map": {}, "attribu
stagestringID element. Usually used to indicate role, e.g. 'prod', 'staging', 'source', 'bunull
enable_glacier_transitionbool(Deprecated, use `lifecycle_configuration_rules` instead) Enables the transitiontrue
expiration_daysnumber(Deprecated, use `lifecycle_configuration_rules` instead) Number of days after w90
lifecycle_configuration_ruleslist(object({ enabled = boA list of S3 bucket v2 lifecycle rules, as specified in [terraform-aws-s3-bucket[]
tenantstringID element _(Rarely used, not included by default)_. A customer identifier, indinull
label_key_casestringControls the letter case of the `tags` keys (label names) for tags generated by null
lifecycle_rule_enabledboolDEPRECATED: Defaults to `false`, use `lifecycle_configuration_rules` instead. Whfalse
id_length_limitnumberLimit `id` to this many characters (minimum 6). Set to `0` for unlimited length.null
descriptor_formatsanyDescribe additional descriptors to be output in the `descriptors` output map. Ma{}
access_log_bucket_namestringName of the S3 bucket where S3 access logs will be sent to""
s3_object_ownershipstringSpecifies the S3 object ownership control. Valid values are `ObjectWriter`, `Buc"BucketOwnerPreferred"
Outputs (5)
bucket_domain_name — S3 bucket domain name
bucket_id — S3 bucket ID
bucket_arn — S3 bucket ARN
bucket_prefix — S3 bucket prefix
enabled — Is module enabled
Details
FrameworkTerraform Module
LanguageHCL
Version0.20.0
Cloud AWS
★ Stars45
Forks34
Total downloads4.7M
Inputs35
Outputs5
Examples1
LicenseApache-2.0
Namespacecloudposse
Updated