Difference between revisions of "Terraform resource: aws s3 bucket logging"
Jump to navigation
Jump to search
Line 17: | Line 17: | ||
== Related == | == Related == | ||
− | * [[aws_s3_bucket_server_side_encryption_configuration]] | + | * <code>[[aws_s3_bucket_server_side_encryption_configuration]]</code> |
* [[Logging options for Amazon S3]] | * [[Logging options for Amazon S3]] | ||
Revision as of 04:10, 17 June 2024
resource "aws_s3_bucket_logging" "example" { bucket = aws_s3_bucket.example.id target_bucket = aws_s3_bucket.log_bucket.id target_prefix = "log/" }
Required Arguments
bucket
: Name of the S3 bucket you want to enable logging for.target_bucket
: Name of the bucket where you want to store the log data. This bucket needs to have appropriate permissions set to allow logging.target_prefix
: Prefix that will be added to the beginning of every log object key.
Related
See also
- Terraform S3 resources:
aws_s3_bucket, aws_s3_object, aws_s3_bucket_policy, aws_s3_bucket_acl, aws_s3_bucket_website_configuration, aws_s3_bucket cors_configuration, aws_s3_account_public_access_block
, Terraform module: s3-bucket,aws_s3_bucket_versioning, aws_s3_bucket_server_side_encryption_configuration, aws_s3_bucket_logging
Advertising: