DistributionGrants

class aws_cdk.aws_cloudfront.DistributionGrants(*args: Any, **kwargs)

Bases: object

Collection of grant methods for a IDistributionRef.

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 import aws_cloudfront as cloudfront
from aws_cdk.interfaces import aws_cloudfront as interfaces_aws_cloudfront

# distribution_ref: interfaces_aws_cloudfront.IDistributionRef

distribution_grants = cloudfront.DistributionGrants.from_distribution(distribution_ref)

Methods

create_invalidation(grantee)

Grant to create invalidations for this bucket to an IAM principal (Role/Group/User).

Parameters:

grantee (IGrantable)

Return type:

Grant

Static Methods

classmethod from_distribution(resource)

Creates grants for DistributionGrants.

Parameters:

resource (IDistributionRef)

Return type:

DistributionGrants