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, DisassociateResolverRule, or ListResolverRuleAssociations 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 | awscc.route53resolver.resolver_rule_associations |
Fields
- get (all properties)
- list (identifiers only)
| 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. |
| Name | Datatype | Description |
|---|---|---|
resolver_rule_association_id | string | |
region | string | AWS region. |
For more information, see AWS::Route53Resolver::ResolverRuleAssociation.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | resolver_rule_associations | INSERT | VPCId, ResolverRuleId, region |
delete_resource | resolver_rule_associations | DELETE | Identifier, region |
list_resources | resolver_rule_associations_list_only | SELECT | region |
get_resource | resolver_rule_associations | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual resolver_rule_association.
SELECT
region,
vpc_id,
resolver_rule_id,
resolver_rule_association_id,
name
FROM awscc.route53resolver.resolver_rule_associations
WHERE
region = '{{ region }}' AND
Identifier = '{{ resolver_rule_association_id }}';
Lists all resolver_rule_associations in a region.
SELECT
region,
resolver_rule_association_id
FROM awscc.route53resolver.resolver_rule_associations_list_only
WHERE
region = '{{ region }}';
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 awscc.route53resolver.resolver_rule_associations (
VPCId,
ResolverRuleId,
region
)
SELECT
'{{ vpc_id }}',
'{{ resolver_rule_id }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.route53resolver.resolver_rule_associations (
VPCId,
ResolverRuleId,
Name,
region
)
SELECT
'{{ vpc_id }}',
'{{ resolver_rule_id }}',
'{{ name }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: resolver_rule_association
props:
- name: vpc_id
value: '{{ vpc_id }}'
- name: resolver_rule_id
value: '{{ resolver_rule_id }}'
- name: name
value: '{{ name }}'
DELETE example
/*+ delete */
DELETE FROM awscc.route53resolver.resolver_rule_associations
WHERE
Identifier = '{{ resolver_rule_association_id }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the resolver_rule_associations resource, the following permissions are required:
- Create
- Read
- Delete
- List
route53resolver:AssociateResolverRule,
route53resolver:GetResolverRuleAssociation,
ec2:DescribeVpcs
route53resolver:GetResolverRuleAssociation
route53resolver:DisassociateResolverRule,
route53resolver:GetResolverRuleAssociation
route53resolver:ListResolverRuleAssociations,
ec2:DescribeVpcs