Difference between revisions of "Terraform resource: aws s3 bucket"

From wikieduonline
Jump to navigation Jump to search
Line 2: Line 2:
  
 
== Arguments ==
 
== Arguments ==
* <code>[[versioning]]</code>: <code>[[aws_s3_versioning]]</code> https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/s3_bucket_versioning
+
* <code>[[versioning]]</code> (deprecated), use Terraform resource <code>[[aws_s3_versioning]]</code> https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/s3_bucket_versioning
 
* <code>[[logging]]</code>
 
* <code>[[logging]]</code>
 
* [[AWS S3 lifecycle|Lifecycle]]: <code>[[lifecycle_rule]]</code>. Resource: <code>[[aws_s3_bucket_lifecycle_configuration]]</code>
 
* [[AWS S3 lifecycle|Lifecycle]]: <code>[[lifecycle_rule]]</code>. Resource: <code>[[aws_s3_bucket_lifecycle_configuration]]</code>

Revision as of 09:39, 3 September 2023

Arguments

Examples

resource "aws_s3_bucket" "my-resource-bucket" {
  bucket = "my-tf-test-bucket" 

  tags = {
    Name        = "My bucket"
    Environment = "Dev"
  }
}


Messages

Error: creating Amazon S3 (Simple Storage) Bucket (yourbucketname): bucket already exists
# aws_s3_bucket.your_bucket has moved to aws_s3_bucket.your_bucket[0]
Error: validating S3 Bucket (your_wrong_name) name: only lowercase alphanumeric characters and hyphens allowed in "your_wrong_name"


Error: creating Amazon S3 (Simple Storage) Bucket (your-bucket-name): BucketAlreadyExists: The requested bucket name is not available. The bucket namespace is shared by all users of the system. Please select a different name and try again.
Error: putting S3 policy: AccessDenied: Access Denied

Related

See also

Advertising: