Header menu logo FsCDK

BucketConfig Type

High-level S3 Bucket builder following AWS security best practices. **Default Security Settings:** - BlockPublicAccess = BLOCK_ALL (prevents public access) - ServerSideEncryption = SSE-KMS with AWS managed key (aws/s3) - Versioning = disabled (opt-in via versioned operation) - EnforceSSL = true (requires HTTPS for all requests) **Rationale:** These defaults follow AWS Well-Architected Framework security pillar: - Encryption at rest protects data from unauthorized access - Blocking public access prevents accidental data exposure - SSL/TLS enforcement protects data in transit - KMS provides audit trails and key rotation capabilities **Escape Hatch:** Access the underlying CDK Bucket via the `Bucket` property on the returned resource for advanced scenarios not covered by this builder.

Record fields

Record Field Description

AutoDeleteObjects

Full Usage: AutoDeleteObjects

Field type: bool option
Field type: bool option

BlockPublicAccess

Full Usage: BlockPublicAccess

Field type: BlockPublicAccess option
Field type: BlockPublicAccess option

BucketName

Full Usage: BucketName

Field type: string
Field type: string

ConstructId

Full Usage: ConstructId

Field type: string option
Field type: string option

Cors

Full Usage: Cors

Field type: ICorsRule list
Field type: ICorsRule list

Encryption

Full Usage: Encryption

Field type: BucketEncryption option
Field type: BucketEncryption option

EncryptionKey

Full Usage: EncryptionKey

Field type: IKey option
Field type: IKey option

EnforceSSL

Full Usage: EnforceSSL

Field type: bool option
Field type: bool option

LifecycleRules

Full Usage: LifecycleRules

Field type: ILifecycleRule list
Field type: ILifecycleRule list

Metrics

Full Usage: Metrics

Field type: IBucketMetrics list
Field type: IBucketMetrics list

RemovalPolicy

Full Usage: RemovalPolicy

Field type: RemovalPolicy option
Field type: RemovalPolicy option

ServerAccessLogsBucket

Full Usage: ServerAccessLogsBucket

Field type: IBucket option
Field type: IBucket option

ServerAccessLogsPrefix

Full Usage: ServerAccessLogsPrefix

Field type: string option
Field type: string option

Versioned

Full Usage: Versioned

Field type: bool option
Field type: bool option

WebsiteErrorDocument

Full Usage: WebsiteErrorDocument

Field type: string option
Field type: string option

WebsiteIndexDocument

Full Usage: WebsiteIndexDocument

Field type: string option
Field type: string option

Type something to start searching.