CfnBucketProps Struct
Properties for defining a CfnBucket.
| Source |
|---|
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_s3outposts as s3outposts } from 'aws-cdk-lib';
declare const filter: any;
const cfnBucketProps: s3outposts.CfnBucketProps = {
bucketName: 'bucketName',
outpostId: 'outpostId',
// the properties below are optional
lifecycleConfiguration: {
rules: [{
status: 'status',
// the properties below are optional
abortIncompleteMultipartUpload: {
daysAfterInitiation: 123,
},
expirationDate: 'expirationDate',
expirationInDays: 123,
filter: filter,
id: 'id',
}],
},
tags: [{
key: 'key',
value: 'value',
}],
};
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_s3outposts as s3outposts
# filter: Any
cfn_bucket_props = s3outposts.CfnBucketProps(
bucket_name="bucketName",
outpost_id="outpostId",
# the properties below are optional
lifecycle_configuration=s3outposts.CfnBucket.LifecycleConfigurationProperty(
rules=[s3outposts.CfnBucket.RuleProperty(
status="status",
# the properties below are optional
abort_incomplete_multipart_upload=s3outposts.CfnBucket.AbortIncompleteMultipartUploadProperty(
days_after_initiation=123
),
expiration_date="expirationDate",
expiration_in_days=123,
filter=filter,
id="id"
)]
),
tags=[CfnTag(
key="key",
value="value"
)]
)
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.s3outposts.*;
Object filter;
CfnBucketProps cfnBucketProps = CfnBucketProps.builder()
.bucketName("bucketName")
.outpostId("outpostId")
// the properties below are optional
.lifecycleConfiguration(LifecycleConfigurationProperty.builder()
.rules(List.of(RuleProperty.builder()
.status("status")
// the properties below are optional
.abortIncompleteMultipartUpload(AbortIncompleteMultipartUploadProperty.builder()
.daysAfterInitiation(123)
.build())
.expirationDate("expirationDate")
.expirationInDays(123)
.filter(filter)
.id("id")
.build()))
.build())
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.S3Outposts;
var filter;
var cfnBucketProps = new CfnBucketProps {
BucketName = "bucketName",
OutpostId = "outpostId",
// the properties below are optional
LifecycleConfiguration = new LifecycleConfigurationProperty {
Rules = new [] { new RuleProperty {
Status = "status",
// the properties below are optional
AbortIncompleteMultipartUpload = new AbortIncompleteMultipartUploadProperty {
DaysAfterInitiation = 123
},
ExpirationDate = "expirationDate",
ExpirationInDays = 123,
Filter = filter,
Id = "id"
} }
},
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
};
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
var filter interface{}
cfnBucketProps := &CfnBucketProps{
BucketName: jsii.String("bucketName"),
OutpostId: jsii.String("outpostId"),
// the properties below are optional
LifecycleConfiguration: &LifecycleConfigurationProperty{
Rules: []interface{}{
&RuleProperty{
Status: jsii.String("status"),
// the properties below are optional
AbortIncompleteMultipartUpload: &AbortIncompleteMultipartUploadProperty{
DaysAfterInitiation: jsii.Number(123),
},
ExpirationDate: jsii.String("expirationDate"),
ExpirationInDays: jsii.Number(123),
Filter: filter,
Id: jsii.String("id"),
},
},
},
Tags: []CfnTag{
&CfnTag{
Key: jsii.String("key"),
Value: jsii.String("value"),
},
},
}
Properties
notes
If you don't specify a name, AWS CloudFormation generates a unique ID and uses that ID for the bucket name. The bucket name must contain only lowercase letters, numbers, periods (.), and dashes (-) and must follow Amazon S3 bucket restrictions and limitations . For more information, see Bucket naming rules .
If you specify a name, you can't perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you need to replace the resource, specify a new name.
lifecycleConfigurationoptionalIResolvable | CfnBucket.lifecycle_configurationoptionaltyping.Union[IResolvable, LifecycleConfigurationProperty]lifecycleConfigurationoptionalIResolvableLifecycleConfigurationoptionalIResolvableLifecycleConfigurationoptionalinterface{} #Outposts buckets only support lifecycle configurations that delete/expire objects after a certain period of time and abort incomplete multipart uploads.
tagsoptionalCfnTag[]tagsoptionaltyping.List[CfnTag]tagsoptionalList<CfnTag>TagsoptionalCfnTag[]Tagsoptional*[]CfnTag #notes
Use tags to organize your AWS bill to reflect your own cost structure. To do this, sign up to get your AWS account bill with tag key values included. Then, to see the cost of combined resources, organize your billing information according to resources with the same tag key values. For example, you can tag several resources with a specific application name, and then organize your billing information to see the total cost of that application across several services. For more information, see Cost allocation and tags .
Within a bucket, if you add a tag that has the same key as an existing tag, the new value overwrites the old value. For more information, see Using cost allocation and bucket tags .
To use this resource, you must have permissions to perform the s3-outposts:PutBucketTagging . The S3 on Outposts bucket owner has this permission by default and can grant this permission to others. For more information about permissions, see Permissions Related to Bucket Subresource Operations and Managing access permissions to your Amazon S3 resources .