CfnAccessGrantsLocationPropsMixin
- class aws_cdk.mixins_preview.aws_s3.mixins.CfnAccessGrantsLocationPropsMixin(props, *, strategy=None)
Bases:
MixinThe
AWS::S3::AccessGrantsLocationresource creates the S3 data location that you would like to register in your S3 Access Grants instance.Your S3 data must be in the same Region as your S3 Access Grants instance. The location can be one of the following:
The default S3 location
s3://A bucket -
S3://<bucket-name>A bucket and prefix -
S3://<bucket-name>/<prefix>
When you register a location, you must include the IAM role that has permission to manage the S3 location that you are registering. Give S3 Access Grants permission to assume this role using a policy . S3 Access Grants assumes this role to manage access to the location and to vend temporary credentials to grantees or client applications.
Permissions - You must have the
s3:CreateAccessGrantsLocationpermission to use this resource.Additional Permissions - You must also have the following permission for the specified IAM role:
iam:PassRole
- See:
- CloudformationResource:
AWS::S3::AccessGrantsLocation
- Mixin:
true
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview import mixins from aws_cdk.mixins_preview.aws_s3 import mixins as s3_mixins cfn_access_grants_location_props_mixin = s3_mixins.CfnAccessGrantsLocationPropsMixin(s3_mixins.CfnAccessGrantsLocationMixinProps( iam_role_arn="iamRoleArn", location_scope="locationScope", tags=[CfnTag( key="key", value="value" )] ), strategy=mixins.PropertyMergeStrategy.OVERRIDE )
Create a mixin to apply properties to
AWS::S3::AccessGrantsLocation.- Parameters:
props (
Union[CfnAccessGrantsLocationMixinProps,Dict[str,Any]]) – L1 properties to apply.strategy (
Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE
Methods
- apply_to(construct)
Apply the mixin properties to the construct.
- Parameters:
construct (
IConstruct)- Return type:
- supports(construct)
Check if this mixin supports the given construct.
- Parameters:
construct (
IConstruct)- Return type:
bool
Attributes
- CFN_PROPERTY_KEYS = ['iamRoleArn', 'locationScope', 'tags']
Static Methods
- classmethod is_mixin(x)
(experimental) Checks if
xis a Mixin.- Parameters:
x (
Any) – Any object.- Return type:
bool- Returns:
true if
xis an object created from a class which extendsMixin.- Stability:
experimental