BucketAttributes Struct
A reference to a bucket outside this stack.
Example
// Deploy an imported S3 bucket from a different account
declare const stage: codepipeline.IStage;
declare const input: codepipeline.Artifact;
stage.addAction(new codepipeline_actions.S3DeployAction({
bucket: s3.Bucket.fromBucketAttributes(this, 'Bucket', {
account: '123456789012',
// ...
}),
input: input,
actionName: 's3-deploy-action',
// ...
}));
Properties
Default: it's assumed the bucket belongs to the same account as the scope it's being imported into
At least one of bucketArn or bucketName must be defined in order to initialize a bucket ref.
bucketDomainNamestringbucket_domain_namestrbucketDomainNameStringBucketDomainNamestringBucketDomainName*string#Default: Inferred from bucket name
bucketDualStackDomainNamestringbucket_dual_stack_domain_namestrbucketDualStackDomainNameStringBucketDualStackDomainNamestringBucketDualStackDomainName*string#If the underlying value of ARN is a string, the name will be parsed from the ARN. Otherwise, the name is optional, but some features that require the bucket name such as auto-creating a bucket policy, won't work.
bucketRegionalDomainNamestringbucket_regional_domain_namestrbucketRegionalDomainNameStringBucketRegionalDomainNamestringBucketRegionalDomainName*string#bucketWebsiteNewUrlFormatbooleanbucket_website_new_url_formatboolbucketWebsiteNewUrlFormatBooleanBucketWebsiteNewUrlFormatboolBucketWebsiteNewUrlFormat*booldeprecated#Default: inferred from available region information, false otherwise
This should be true for regions launched since 2014.
bucketWebsiteUrlstringbucket_website_urlstrbucketWebsiteUrlStringBucketWebsiteUrlstringBucketWebsiteUrl*string#Default: Inferred from bucket name and region
Default: no encryption key
notificationsHandlerRoleIRolenotifications_handler_roleIRolenotificationsHandlerRoleIRoleNotificationsHandlerRoleIRoleNotificationsHandlerRoleIRole#Default: a new role will be created.
Default: it's assumed the bucket is in the same region as the scope it's being imported into
Features that require the region (e.g. bucketWebsiteUrl) won't fully work if the region cannot be correctly inferred.