class FirewallRuleGroup (construct)
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.Route53Resolver.FirewallRuleGroup |
![]() | software.amazon.awscdk.services.route53resolver.FirewallRuleGroup |
![]() | aws_cdk.aws_route53resolver.FirewallRuleGroup |
![]() | @aws-cdk/aws-route53resolver ยป FirewallRuleGroup |
Implements
IConstruct
, IConstruct
, IDependable
, IResource
, IFirewall
A Firewall Rule Group.
Example
declare const myBlockList: route53resolver.FirewallDomainList;
new route53resolver.FirewallRuleGroup(this, 'RuleGroup', {
rules: [
{
priority: 10,
firewallDomainList: myBlockList,
// block and reply with NODATA
action: route53resolver.FirewallRuleAction.block(),
},
],
});
Initializer
new FirewallRuleGroup(scope: Construct, id: string, props?: FirewallRuleGroupProps)
Parameters
- scope
Construct
- id
string
- props
Firewall
Rule Group Props
Construct Props
Name | Type | Description |
---|---|---|
name? | string | The name of the rule group. |
rules? | Firewall [] | A list of rules for this group. |
name?
Type:
string
(optional, default: a CloudFormation generated name)
The name of the rule group.
rules?
Type:
Firewall
[]
(optional, default: no rules)
A list of rules for this group.
Properties
Name | Type | Description |
---|---|---|
env | Resource | The environment this resource belongs to. |
firewall | string | The ARN (Amazon Resource Name) of the rule group. |
firewall | string | The date and time that the rule group was created. |
firewall | string | The creator request ID. |
firewall | string | The ID of the rule group. |
firewall | string | The date and time that the rule group was last modified. |
firewall | string | The AWS account ID for the account that created the rule group. |
firewall | number | The number of rules in the rule group. |
firewall | string | Whether the rule group is shared with other AWS accounts, or was shared with the current account by another AWS account. |
firewall | string | The status of the rule group. |
firewall | string | Additional information about the status of the rule group. |
node | Construct | The construct tree node associated with this construct. |
stack | Stack | The stack in which this resource is defined. |
env
Type:
Resource
The environment this resource belongs to.
For resources that are created and managed by the CDK (generally, those created by creating new class instances like Role, Bucket, etc.), this is always the same as the environment of the stack they belong to; however, for imported resources (those obtained from static methods like fromRoleArn, fromBucketName, etc.), that might be different than the stack they were imported into.
firewallRuleGroupArn
Type:
string
The ARN (Amazon Resource Name) of the rule group.
firewallRuleGroupCreationTime
Type:
string
The date and time that the rule group was created.
firewallRuleGroupCreatorRequestId
Type:
string
The creator request ID.
firewallRuleGroupId
Type:
string
The ID of the rule group.
firewallRuleGroupModificationTime
Type:
string
The date and time that the rule group was last modified.
firewallRuleGroupOwnerId
Type:
string
The AWS account ID for the account that created the rule group.
firewallRuleGroupRuleCount
Type:
number
The number of rules in the rule group.
firewallRuleGroupShareStatus
Type:
string
Whether the rule group is shared with other AWS accounts, or was shared with the current account by another AWS account.
firewallRuleGroupStatus
Type:
string
The status of the rule group.
firewallRuleGroupStatusMessage
Type:
string
Additional information about the status of the rule group.
node
Type:
Construct
The construct tree node associated with this construct.
stack
Type:
Stack
The stack in which this resource is defined.
Methods
Name | Description |
---|---|
add | Adds a rule to this group. |
apply | Apply the given removal policy to this resource. |
associate(id, props) | Associates this Firewall Rule Group with a VPC. |
to | Returns a string representation of this construct. |
static from | Import an existing Firewall Rule Group. |
addRule(rule)
public addRule(rule: FirewallRule): FirewallRuleGroup
Parameters
- rule
Firewall
Rule
Returns
Adds a rule to this group.
applyRemovalPolicy(policy)
public applyRemovalPolicy(policy: RemovalPolicy): void
Parameters
- policy
Removal
Policy
Apply the given removal policy to this resource.
The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you've removed it from the CDK application or because you've made a change that requires the resource to be replaced.
The resource can be deleted (RemovalPolicy.DESTROY
), or left in your AWS
account for data recovery and cleanup later (RemovalPolicy.RETAIN
).
associate(id, props)
public associate(id: string, props: FirewallRuleGroupAssociationOptions): FirewallRuleGroupAssociation
Parameters
- id
string
- props
Firewall
Rule Group Association Options
Returns
Associates this Firewall Rule Group with a VPC.
toString()
public toString(): string
Returns
string
Returns a string representation of this construct.
static fromFirewallRuleGroupId(scope, id, firewallRuleGroupId)
public static fromFirewallRuleGroupId(scope: Construct, id: string, firewallRuleGroupId: string): IFirewallRuleGroup
Parameters
- scope
Construct
- id
string
- firewallRuleGroupId
string
Returns
Import an existing Firewall Rule Group.