resolver_rule_associations
Creates, updates, deletes or gets a resolver_rule_association resource or lists resolver_rule_associations in a region
Overview
| Name | resolver_rule_associations |
| Type | Resource |
| Description | In the response to an [AssociateResolverRule](https://docs.aws.amazon.com/Route53/latest/APIReference/API_route53resolver_AssociateResolverRule.html), [DisassociateResolverRule](https://docs.aws.amazon.com/Route53/latest/APIReference/API_route53resolver_DisassociateResolverRule.html), or [ListResolverRuleAssociations](https://docs.aws.amazon.com/Route53/latest/APIReference/API_route53resolver_ListResolverRuleAssociations.html) request, provides information about an association between a resolver rule and a VPC. The association determines which DNS queries that originate in the VPC are forwarded to your network. |
| Id | aws.route53resolver.resolver_rule_associations |
Fields
| Name | Datatype | Description |
|---|---|---|
vpc_id | string | The ID of the VPC that you associated the Resolver rule with. |
resolver_rule_id | string | The ID of the Resolver rule that you associated with the VPC that is specified by VPCId. |
resolver_rule_association_id | string | |
name | string | The name of an association between a Resolver rule and a VPC. |
region | string | AWS region. |
For more information, see AWS::Route53Resolver::ResolverRuleAssociation.
Methods
| Name | Accessible by | Required Params |
|---|---|---|
create_resource | INSERT | VPCId, ResolverRuleId, region |
delete_resource | DELETE | data__Identifier, region |
list_resources | SELECT | region |
get_resource | SELECT | data__Identifier, region |
SELECT examples
Gets all resolver_rule_associations in a region.
SELECT
region,
vpc_id,
resolver_rule_id,
resolver_rule_association_id,
name
FROM aws.route53resolver.resolver_rule_associations
WHERE region = 'us-east-1';
Gets all properties from an individual resolver_rule_association.
SELECT
region,
vpc_id,
resolver_rule_id,
resolver_rule_association_id,
name
FROM aws.route53resolver.resolver_rule_associations
WHERE region = 'us-east-1' AND data__Identifier = '<ResolverRuleAssociationId>';
INSERT example
Use the following StackQL query and manifest file to create a new resolver_rule_association resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.route53resolver.resolver_rule_associations (
VPCId,
ResolverRuleId,
region
)
SELECT
'{{ VPCId }}',
'{{ ResolverRuleId }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.route53resolver.resolver_rule_associations (
VPCId,
ResolverRuleId,
Name,
region
)
SELECT
'{{ VPCId }}',
'{{ ResolverRuleId }}',
'{{ Name }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: resolver_rule_association
props:
- name: VPCId
value: '{{ VPCId }}'
- name: ResolverRuleId
value: '{{ ResolverRuleId }}'
- name: Name
value: '{{ Name }}'
DELETE example
/*+ delete */
DELETE FROM aws.route53resolver.resolver_rule_associations
WHERE data__Identifier = '<ResolverRuleAssociationId>'
AND region = 'us-east-1';
Permissions
To operate on the resolver_rule_associations resource, the following permissions are required:
Create
route53resolver:AssociateResolverRule,
route53resolver:GetResolverRuleAssociation,
ec2:DescribeVpcs
Read
route53resolver:GetResolverRuleAssociation
Delete
route53resolver:DisassociateResolverRule,
route53resolver:GetResolverRuleAssociation
List
route53resolver:ListResolverRuleAssociations