AWS::VpcLattice::Rule
Creates a listener rule. Each listener has a default rule for checking connection requests, but you can define additional rules. Each rule consists of a priority, one or more actions, and one or more conditions. For more information, see Listener rules in the Amazon VPC Lattice User Guide.
Syntax
To declare this entity in your AWS CloudFormation template, use the following syntax:
JSON
{ "Type" : "AWS::VpcLattice::Rule", "Properties" : { "Action" :
Action
, "ListenerIdentifier" :String
, "Match" :Match
, "Name" :String
, "Priority" :Integer
, "ServiceIdentifier" :String
, "Tags" :[ Tag, ... ]
} }
YAML
Type: AWS::VpcLattice::Rule Properties: Action:
Action
ListenerIdentifier:String
Match:Match
Name:String
Priority:Integer
ServiceIdentifier:String
Tags:- Tag
Properties
Action
-
Describes the action for a rule.
Required: Yes
Type: Action
Update requires: No interruption
ListenerIdentifier
-
The ID or Amazon Resource Name (ARN) of the listener.
Required: No
Type: String
Pattern:
^((listener-[0-9a-z]{17})|(arn(:[a-z0-9]+([.-][a-z0-9]+)*){2}(:([a-z0-9]+([.-][a-z0-9]+)*)?){2}:service/svc-[0-9a-z]{17}/listener/listener-[0-9a-z]{17}))$
Minimum:
20
Maximum:
2048
Update requires: Replacement
Match
-
The rule match.
Required: Yes
Type: Match
Update requires: No interruption
Name
-
The name of the rule. The name must be unique within the listener. The valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
If you don't specify a name, CloudFormation generates one. However, if you specify a name, and later want to replace the resource, you must specify a new name.
Required: No
Type: String
Pattern:
^(?!rule-)(?![-])(?!.*[-]$)(?!.*[-]{2})[a-z0-9-]+$
Minimum:
3
Maximum:
63
Update requires: Replacement
Priority
-
The priority assigned to the rule. Each rule for a specific listener must have a unique priority. The lower the priority number the higher the priority.
Required: Yes
Type: Integer
Minimum:
1
Maximum:
100
Update requires: No interruption
ServiceIdentifier
-
The ID or Amazon Resource Name (ARN) of the service.
Required: No
Type: String
Pattern:
^((svc-[0-9a-z]{17})|(arn(:[a-z0-9]+([.-][a-z0-9]+)*){2}(:([a-z0-9]+([.-][a-z0-9]+)*)?){2}:service/svc-[0-9a-z]{17}))$
Minimum:
20
Maximum:
2048
Update requires: Replacement
-
The tags for the rule.
Required: No
Type: Array of Tag
Minimum:
0
Maximum:
50
Update requires: No interruption
Return values
Ref
When you pass the logical ID of this resource to the intrinsic Ref
function, Ref
returns the Amazon Resource Name (ARN) of the rule.
For more information about using the Ref
function, see Ref
.
Fn::GetAtt
The Fn::GetAtt
intrinsic function returns a value for a specified attribute of this type. The following are the available attributes and sample return values.
For more information about using the Fn::GetAtt
intrinsic function, see Fn::GetAtt
.
Arn
-
The Amazon Resource Name (ARN) of the rule.
Id
-
The ID of the listener.