site_to_site_vpn_attachments
Creates, updates, deletes or gets a site_to_site_vpn_attachment resource or lists site_to_site_vpn_attachments in a region
Overview
| Name | site_to_site_vpn_attachments |
| Type | Resource |
| Description | AWS::NetworkManager::SiteToSiteVpnAttachment Resource Type definition. |
| Id | awscc.networkmanager.site_to_site_vpn_attachments |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
core_network_id | string | The ID of a core network where you're creating a site-to-site VPN attachment. |
core_network_arn | string | The ARN of a core network for the VPC attachment. |
attachment_id | string | The ID of the attachment. |
owner_account_id | string | Owner account of the attachment. |
attachment_type | string | The type of attachment. |
state | string | The state of the attachment. |
edge_location | string | The Region where the edge is located. |
resource_arn | string | The ARN of the Resource. |
attachment_policy_rule_number | integer | The policy rule number associated with the attachment. |
segment_name | string | The name of the segment that attachment is in. |
proposed_segment_change | object | The attachment to move from one segment to another. |
network_function_group_name | string | The name of the network function group attachment. |
proposed_network_function_group_change | object | The attachment to move from one network function group to another. |
tags | array | Tags for the attachment. |
created_at | string | Creation time of the attachment. |
updated_at | string | Last update time of the attachment. |
vpn_connection_arn | string | The ARN of the site-to-site VPN attachment. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
attachment_id | string | The ID of the attachment. |
region | string | AWS region. |
For more information, see AWS::NetworkManager::SiteToSiteVpnAttachment.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | site_to_site_vpn_attachments | INSERT | CoreNetworkId, VpnConnectionArn, region |
delete_resource | site_to_site_vpn_attachments | DELETE | Identifier, region |
update_resource | site_to_site_vpn_attachments | UPDATE | Identifier, PatchDocument, region |
list_resources | site_to_site_vpn_attachments_list_only | SELECT | region |
get_resource | site_to_site_vpn_attachments | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual site_to_site_vpn_attachment.
SELECT
region,
core_network_id,
core_network_arn,
attachment_id,
owner_account_id,
attachment_type,
state,
edge_location,
resource_arn,
attachment_policy_rule_number,
segment_name,
proposed_segment_change,
network_function_group_name,
proposed_network_function_group_change,
tags,
created_at,
updated_at,
vpn_connection_arn
FROM awscc.networkmanager.site_to_site_vpn_attachments
WHERE
region = '{{ region }}' AND
Identifier = '{{ attachment_id }}';
Lists all site_to_site_vpn_attachments in a region.
SELECT
region,
attachment_id
FROM awscc.networkmanager.site_to_site_vpn_attachments_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new site_to_site_vpn_attachment resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.networkmanager.site_to_site_vpn_attachments (
CoreNetworkId,
VpnConnectionArn,
region
)
SELECT
'{{ core_network_id }}',
'{{ vpn_connection_arn }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.networkmanager.site_to_site_vpn_attachments (
CoreNetworkId,
ProposedSegmentChange,
NetworkFunctionGroupName,
ProposedNetworkFunctionGroupChange,
Tags,
VpnConnectionArn,
region
)
SELECT
'{{ core_network_id }}',
'{{ proposed_segment_change }}',
'{{ network_function_group_name }}',
'{{ proposed_network_function_group_change }}',
'{{ tags }}',
'{{ vpn_connection_arn }}',
'{{ 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: site_to_site_vpn_attachment
props:
- name: core_network_id
value: '{{ core_network_id }}'
- name: proposed_segment_change
value:
tags:
- key: '{{ key }}'
value: '{{ value }}'
attachment_policy_rule_number: '{{ attachment_policy_rule_number }}'
segment_name: '{{ segment_name }}'
- name: network_function_group_name
value: '{{ network_function_group_name }}'
- name: proposed_network_function_group_change
value:
tags:
- null
attachment_policy_rule_number: '{{ attachment_policy_rule_number }}'
network_function_group_name: '{{ network_function_group_name }}'
- name: tags
value:
- null
- name: vpn_connection_arn
value: '{{ vpn_connection_arn }}'
UPDATE example
Use the following StackQL query and manifest file to update a site_to_site_vpn_attachment resource, using stack-deploy.
/*+ update */
UPDATE awscc.networkmanager.site_to_site_vpn_attachments
SET PatchDocument = string('{{ {
"ProposedSegmentChange": proposed_segment_change,
"NetworkFunctionGroupName": network_function_group_name,
"ProposedNetworkFunctionGroupChange": proposed_network_function_group_change,
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ attachment_id }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.networkmanager.site_to_site_vpn_attachments
WHERE
Identifier = '{{ attachment_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 site_to_site_vpn_attachments resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
networkmanager:GetSiteToSiteVpnAttachment,
networkmanager:CreateSiteToSiteVpnAttachment,
ec2:DescribeRegions,
networkmanager:TagResource
networkmanager:GetSiteToSiteVpnAttachment
networkmanager:GetSiteToSiteVpnAttachment,
networkmanager:ListTagsForResource,
networkmanager:TagResource,
networkmanager:UntagResource,
ec2:DescribeRegions
networkmanager:GetSiteToSiteVpnAttachment,
networkmanager:DeleteAttachment,
ec2:DescribeRegions
networkmanager:ListAttachments