Carina

Resource

aws.s3.BucketPublicAccessBlock

Example

let bucket = aws.s3.Bucket {
  bucket = 'carina-example-private-bucket'

  tags = {
    Environment = 'example'
  }
}

aws.s3.BucketPublicAccessBlock {
  bucket = bucket.bucket

  block_public_acls       = true
  block_public_policy     = true
  ignore_public_acls      = true
  restrict_public_buckets = true
}

Argument Reference

bucket

The name of the Amazon S3 bucket whose PublicAccessBlock configuration you want to set.

block_public_acls

Block public ACLs on the bucket and its objects.

ignore_public_acls

Ignore any public ACLs on the bucket and its objects.

block_public_policy

Block public bucket policies for the bucket.

restrict_public_buckets

Restrict access to the bucket to AWS service principals and authorized users when a public policy is set.