AwsS3BucketArgs
interface AwsS3BucketArgs extends Omit<awsNative.s3.BucketArgs, 'accessControl' | 'bucketEncryption' | 'bucketName' | 'corsConfiguration' | 'intelligentTieringConfigurations' | 'lifecycleConfiguration' | 'metricsConfigurations' | 'notificationConfiguration' | 'ownershipControls' | 'publicAccessBlockConfiguration' | 'tags' | 'versioningConfiguration' | 'websiteConfiguration'> {
abacStatus?: Input<BucketAbacStatus | undefined>;
accelerateConfiguration?: Input<BucketAccelerateConfigurationArgs | undefined>;
acl?: AwsS3BucketAclValue;
analyticsConfigurations?: Input<Input<BucketAnalyticsConfigurationArgs>[] | undefined>;
bucketName: string;
bucketNamePrefix?: Input<string | undefined>;
bucketNamespace?: Input<BucketNamespace | undefined>;
corsRules?: AwsS3BucketCorsRuleArgs[];
enforceSecureTransport?: true;
intelligentTiering?: boolean;
intelligentTieringArchive?: AwsS3BucketIntelligentTieringArchiveArgs;
inventoryConfigurations?: Input<Input<BucketInventoryConfigurationArgs>[] | undefined>;
lifecycleRules?: AwsS3BucketLifecycleRuleArgs[];
loggingConfiguration?: Input<BucketLoggingConfigurationArgs | undefined>;
metadataConfiguration?: Input<BucketMetadataConfigurationArgs | undefined>;
metadataTableConfiguration?: Input<BucketMetadataTableConfigurationArgs | undefined>;
metricsConfiguration?: AwsS3BucketMetricsConfigurationArgs;
notifications?: AwsS3BucketNotificationConfigurationArgs;
objectLockConfiguration?: Input<BucketObjectLockConfigurationArgs | undefined>;
objectLockEnabled?: Input<boolean | undefined>;
ownershipControls?: AwsS3BucketOwnershipControlsArgs;
policy?: AwsS3BucketPolicyDocumentTemplate;
publicAccessBlock?: AwsS3BucketPublicAccessBlockArgs;
replicationConfiguration?: Input<BucketReplicationConfigurationArgs | undefined>;
serverSideEncryption?: AwsS3BucketServerSideEncryptionArgs;
tags?: Input<Record<string, Input<string>>>;
versioning?: AwsS3BucketVersioningArgs;
website?: AwsS3BucketWebsiteConfigurationArgs;
}Input arguments for AwsS3Bucket.
Remarks
The component always creates a base awsNative.s3.Bucket and targets aws-native S3 resources for bucket orchestration. The intelligent tiering lifecycle default is enabled unless explicitly disabled via intelligentTiering. Optional child outputs remain available where relevant (for example bucketAcl, bucketPolicy, and lambdaInvokePermissions).
All other capabilities are opt-in and rely on AWS defaults when omitted.
Example
const args: AwsS3BucketArgs = {
bucketName: 'applicationAssetsProd',
publicAccessBlock: {
blockPublicAcls: true,
blockPublicPolicy: true,
ignorePublicAcls: true,
restrictPublicBuckets: true,
},
serverSideEncryption: {
sseAlgorithm: 'AES256',
},
notifications: {
lambda: [
{
eventTypes: ['s3:ObjectCreated:*'],
functionArn: processAsset.arn,
createInvokePermission: false,
},
],
},
};Hierarchy
BucketArgs, "accessControl" | "bucketEncryption" | "bucketName" | "corsConfiguration" | "intelligentTieringConfigurations" | "lifecycleConfiguration" | "metricsConfigurations" | "notificationConfiguration" | "ownershipControls" | "publicAccessBlockConfiguration" | "tags" | "versioningConfiguration" | "websiteConfiguration">AwsS3BucketArgs
Properties
abacStatus: Input<BucketAbacStatus | undefined>
Inherited from abacStatus
The ABAC status of the general purpose bucket. When ABAC is enabled for the general purpose bucket, you can use tags to manage access to the general purpose buckets as well as for cost tracking purposes. When ABAC is disabled for the general purpose buckets, you can only use tags for cost tracking purposes. For more information, see Using tags with S3 general purpose buckets.
accelerateConfiguration: Input<BucketAccelerateConfigurationArgs | undefined>
Inherited from accelerateConfiguration
Configures the transfer acceleration state for an Amazon S3 bucket. For more information, see Amazon S3 Transfer Acceleration in the Amazon S3 User Guide.
acl: AwsS3BucketAclValue
Optional canned ACL configuration.
Cloud Control treats AccessControl as write-only for updates, so this component applies ACL on create and then ignores subsequent accessControl diffs to avoid update failures.
analyticsConfigurations: Input<Input<BucketAnalyticsConfigurationArgs>[] | undefined>
Inherited from analyticsConfigurations
Specifies the configuration and any analyses for the analytics filter of an Amazon S3 bucket.
bucketName: string
Required camelCase alphanumeric bucket purpose used in the AWS naming pattern.
Remarks
Validated as a strict camelCase alphanumeric purpose (letters and digits only, starting with a lowercase letter) and lowercased for the S3 bucket name, which forbids uppercase letters. The purpose is capped at 43 characters so the full ${env}-${projectHash}-${accountHash}-<purpose> name stays within the 63-character S3 limit; an invalid or over-long value is rejected at preview rather than silently coerced. For example mediaStorageProd becomes mediastorageprod.
bucketNamePrefix: Input<string | undefined>
Inherited from bucketNamePrefix
bucketNamespace: Input<BucketNamespace | undefined>
Inherited from bucketNamespace
corsRules: AwsS3BucketCorsRuleArgs[]
Optional CORS capability.
enforceSecureTransport: true
Adds a bucket-policy deny statement for requests that do not use HTTPS.
Remarks
This can only be enabled; callers cannot configure a plaintext transport path. When enabled with policy, the HTTPS-only deny statement is appended to the rendered custom policy.
Default: ```ts Omitted. No transport-enforcement statement is created. ```
intelligentTiering: boolean
Enables the default lifecycle transition to INTELLIGENT_TIERING at day 0.
Default: `true`.
intelligentTieringArchive: AwsS3BucketIntelligentTieringArchiveArgs
Optional intelligent tiering archive capability.
inventoryConfigurations: Input<Input<BucketInventoryConfigurationArgs>[] | undefined>
Inherited from inventoryConfigurations
Specifies the S3 Inventory configuration for an Amazon S3 bucket. For more information, see GET Bucket inventory in the Amazon S3 API Reference.
lifecycleRules: AwsS3BucketLifecycleRuleArgs[]
Optional lifecycle rule capability.
loggingConfiguration: Input<BucketLoggingConfigurationArgs | undefined>
Inherited from loggingConfiguration
Settings that define where logs are stored.
metadataConfiguration: Input<BucketMetadataConfigurationArgs | undefined>
Inherited from metadataConfiguration
The S3 Metadata configuration for a general purpose bucket.
metadataTableConfiguration: Input<BucketMetadataTableConfigurationArgs | undefined>
Inherited from metadataTableConfiguration
The metadata table configuration of an S3 general purpose bucket.
metricsConfiguration: AwsS3BucketMetricsConfigurationArgs
Optional bucket metrics capability.
notifications: AwsS3BucketNotificationConfigurationArgs
Optional notification capability.
objectLockConfiguration: Input<BucketObjectLockConfigurationArgs | undefined>
Inherited from objectLockConfiguration
This operation is not supported for directory buckets. Places an Object Lock configuration on the specified bucket. The rule specified in the Object Lock configuration will be applied by default to every new object placed in the specified bucket. For more information, see Locking Objects.
- The
DefaultRetentionsettings require both a mode and a period. - The
DefaultRetentionperiod can be eitherDaysorYearsbut you must select one. You cannot specifyDaysandYearsat the same time. - You can enable Object Lock for new or existing buckets. For more information, see Configuring Object Lock.
You must URL encode any signed header values that contain spaces. For example, if your header value is my file.txt, containing two spaces after my, you must URL encode this value to my%20%20file.txt.
objectLockEnabled: Input<boolean | undefined>
Inherited from objectLockEnabled
Indicates whether this bucket has an Object Lock configuration enabled. Enable ObjectLockEnabled when you apply ObjectLockConfiguration to a bucket.
ownershipControls: AwsS3BucketOwnershipControlsArgs
Optional ownership controls capability.
policy: AwsS3BucketPolicyDocumentTemplate
Optional bucket policy template input.
Built-in variables available in templates:
bucketArnbucketNamebucketObjectsArn
publicAccessBlock: AwsS3BucketPublicAccessBlockArgs
Optional public access block capability.
replicationConfiguration: Input<BucketReplicationConfigurationArgs | undefined>
Inherited from replicationConfiguration
Configuration for replicating objects in an S3 bucket. To enable replication, you must also enable versioning by using the VersioningConfiguration property. Amazon S3 can store replicated objects in a single destination bucket or multiple destination buckets. The destination bucket or buckets must already exist.
serverSideEncryption: AwsS3BucketServerSideEncryptionArgs
Optional default server-side encryption capability.
tags: Input<Record<string, Input<string>>>
Optional tags merged with repository default tags.
versioning: AwsS3BucketVersioningArgs
Optional bucket versioning capability.
website: AwsS3BucketWebsiteConfigurationArgs
Optional website capability.