AWS::CloudFront::Distribution FunctionAssociation
A CloudFront function that is associated with a cache behavior in a CloudFront distribution.
Syntax
To declare this entity in your Amazon CloudFormation template, use the following syntax:
JSON
{ "EventType" :String, "FunctionARN" :String}
YAML
EventType:StringFunctionARN:String
Properties
EventType-
The event type of the function, either
viewer-requestorviewer-response. You cannot use origin-facing event types (origin-requestandorigin-response) with a CloudFront function.Required: No
Type: String
Allowed values:
origin-request | origin-response | viewer-request | viewer-responseUpdate requires: No interruption
FunctionARN-
The Amazon Resource Name (ARN) of the function.
Required: No
Type: String
Maximum:
108Pattern:
arn:aws:cloudfront::[0-9]{12}:function\/[a-zA-Z0-9-_]{1,64}$Update requires: No interruption