Skip to main content

connect_peers

Creates, updates, deletes, gets or lists a connect_peers resource.

Overview

Nameconnect_peers
TypeResource
Idaws.networkmanager.connect_peers

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
configurationobjectThe configuration of the Connect peer.
connect_attachment_idstringThe ID of the attachment to connect. (pattern: <code>^attachment-([0-9a-f]{8,17})$</code>)
connect_peer_idstringThe ID of the Connect peer. (pattern: <code>^connect-peer-([0-9a-f]{8,17})$</code>)
core_network_idstringThe ID of a core network. (pattern: <code>^core-network-([0-9a-f]{8,17})$</code>)
created_atstring (date-time)The timestamp when the Connect peer was created.
edge_locationstringThe Connect peer Regions where edges are located. (pattern: <code>[\s\S]*</code>)
last_modification_errorsarrayDescribes the error associated with the attachment request.
statestringThe state of the Connect peer. (CREATING, FAILED, AVAILABLE, DELETING)
subnet_arnstringThe subnet ARN for the Connect peer. This only applies only when the protocol is NO_ENCAP. (pattern: <code>^arn:[^:]{1,63}:ec2:[^:]{0,63}:[^:]{0,63}:subnet/subnet-[0-9a-f]{8,17}$|^$</code>)
tagsarrayThe list of key-value tags associated with the Connect peer.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_connect_peerselectconnect_peer_id, regionReturns information about a core network Connect peer.
list_connect_peersselectregioncoreNetworkId, connectAttachmentId, maxResults, nextTokenReturns a list of core network Connect peers.
create_connect_peerinsertregion, ConnectAttachmentId, PeerAddressCreates a core network Connect peer for a specified core network connect attachment between a core network and an appliance. The peer address and transit gateway address must be the same IP address family (IPv4 or IPv6).
associate_connect_peerupdateglobal_network_id, region, ConnectPeerId, DeviceIdAssociates a core network Connect peer with a device and optionally, with a link. If you specify a link, it must be associated with the specified device. You can only associate core network Connect peers that have been created on a core network Connect attachment on a core network.
associate_transit_gateway_connect_peerupdateglobal_network_id, region, TransitGatewayConnectPeerArn, DeviceIdAssociates a transit gateway Connect peer with a device, and optionally, with a link. If you specify a link, it must be associated with the specified device. You can only associate transit gateway Connect peers that have been created on a transit gateway that's registered in your global network. You cannot associate a transit gateway Connect peer with more than one device and link.
disassociate_connect_peerupdateglobal_network_id, connect_peer_id, regionDisassociates a core network Connect peer from a device and a link.
disassociate_transit_gateway_connect_peerupdateglobal_network_id, transit_gateway_connect_peer_arn, regionDisassociates a transit gateway Connect peer from a device and link.
delete_connect_peerdeleteconnect_peer_id, regionDeletes a Connect peer.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
connect_peer_idstringThe ID of the deleted Connect peer.
global_network_idstringThe ID of the global network.
regionstringAWS region (default: us-east-1)
transit_gateway_connect_peer_arnstringThe Amazon Resource Name (ARN) of the transit gateway Connect peer.
connectAttachmentIdstringThe ID of the attachment.
coreNetworkIdstringThe ID of a core network.
maxResultsintegerThe maximum number of results to return.
nextTokenstringThe token for the next page of results.

SELECT examples

Returns information about a core network Connect peer.

SELECT
configuration,
connect_attachment_id,
connect_peer_id,
core_network_id,
created_at,
edge_location,
last_modification_errors,
state,
subnet_arn,
tags
FROM aws.networkmanager.connect_peers
WHERE connect_peer_id = '{{ connect_peer_id }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Creates a core network Connect peer for a specified core network connect attachment between a core network and an appliance. The peer address and transit gateway address must be the same IP address family (IPv4 or IPv6).

INSERT INTO aws.networkmanager.connect_peers (
ConnectAttachmentId,
CoreNetworkAddress,
PeerAddress,
BgpOptions,
InsideCidrBlocks,
Tags,
ClientToken,
SubnetArn,
region
)
SELECT
'{{ ConnectAttachmentId }}' /* required */,
'{{ CoreNetworkAddress }}',
'{{ PeerAddress }}' /* required */,
'{{ BgpOptions }}',
'{{ InsideCidrBlocks }}',
'{{ Tags }}',
'{{ ClientToken }}',
'{{ SubnetArn }}',
'{{ region }}'
RETURNING
connect_peer
;

UPDATE examples

Associates a core network Connect peer with a device and optionally, with a link. If you specify a link, it must be associated with the specified device. You can only associate core network Connect peers that have been created on a core network Connect attachment on a core network.

UPDATE aws.networkmanager.connect_peers
SET
ConnectPeerId = '{{ ConnectPeerId }}',
DeviceId = '{{ DeviceId }}',
LinkId = '{{ LinkId }}'
WHERE
global_network_id = '{{ global_network_id }}' --required
AND region = '{{ region }}' --required
AND ConnectPeerId = '{{ ConnectPeerId }}' --required
AND DeviceId = '{{ DeviceId }}' --required
RETURNING
connect_peer_association;

DELETE examples

Deletes a Connect peer.

DELETE FROM aws.networkmanager.connect_peers
WHERE connect_peer_id = '{{ connect_peer_id }}' --required
AND region = '{{ region }}' --required
;