Skip to content

Commit 247bc07

Browse files
committed
Updated bucket region, globally unique bucket name, and added bucket domain name argument
1 parent e61d671 commit 247bc07

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

main.tf

+7-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
provider "aws" {
2-
region = "us-east-1" # Update this to the Region closest to you
2+
region = "us-west-1" # Update this to the Region closest to you
33
}
44

55
resource "aws_s3_bucket" "my_bucket" {
6-
bucket = "nextwork-unique-bucket-[your_name]-[random_number]" # Ensure this bucket name is globally unique
6+
bucket = "nextwork-unique-bucket-joeyacosta-963831" # Ensure this bucket name is globally unique
77
}
88

99
resource "aws_s3_bucket_public_access_block" "my_bucket_public_access_block" {
@@ -14,3 +14,8 @@ resource "aws_s3_bucket_public_access_block" "my_bucket_public_access_block" {
1414
block_public_policy = true
1515
restrict_public_buckets = true
1616
}
17+
18+
# Access the bucket's domain name (useful for website hosting or DNS)
19+
output "bucket_domain_name" {
20+
value = aws_s3_bucket.my_bucket.bucket_domain_name
21+
}

0 commit comments

Comments
 (0)