instance_connect_endpoints
Creates, updates, deletes, gets or lists an instance_connect_endpoints resource.
Overview
| Name | instance_connect_endpoints |
| Type | Resource |
| Id | aws.ec2.instance_connect_endpoints |
Fields
The following fields are returned by SELECT queries:
- describe_instance_connect_endpoints
| Name | Datatype | Description |
|---|---|---|
availability_zone | string | The Availability Zone of the EC2 Instance Connect Endpoint. |
availability_zone_id | string | The ID of the Availability Zone of the EC2 Instance Connect Endpoint. |
created_at | string | The date and time that the EC2 Instance Connect Endpoint was created. |
dns_name | string | The DNS name of the EC2 Instance Connect Endpoint. |
fips_dns_name | string | The Federal Information Processing Standards (FIPS) compliant DNS name of the EC2 Instance Connect Endpoint. |
instance_connect_endpoint_arn | string | The Amazon Resource Name (ARN) of the EC2 Instance Connect Endpoint. |
instance_connect_endpoint_id | string | The ID of the EC2 Instance Connect Endpoint. |
ip_address_type | string | The IP address type of the endpoint. |
network_interface_ids | string | The ID of the elastic network interface that Amazon EC2 automatically created when creating the EC2 Instance Connect Endpoint. |
owner_id | string | The ID of the Amazon Web Services account that created the EC2 Instance Connect Endpoint. |
preserve_client_ip | boolean | Indicates whether your client's IP address is preserved as the source when you connect to a resource. The following are the possible values. true - Use the IP address of the client. Your instance must have an IPv4 address. false - Use the IP address of the network interface. Default: false |
public_dns_names | string | The public DNS names of the endpoint. |
security_group_ids | string | The security groups associated with the endpoint. If you didn't specify a security group, the default security group for your VPC is associated with the endpoint. |
state | string | The current state of the EC2 Instance Connect Endpoint. |
state_message | string | The message for the current state of the EC2 Instance Connect Endpoint. Can include a failure message. |
subnet_id | string | The ID of the subnet in which the EC2 Instance Connect Endpoint was created. |
tags | string | The tags assigned to the EC2 Instance Connect Endpoint. |
vpc_id | string | The ID of the VPC in which the EC2 Instance Connect Endpoint was created. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_instance_connect_endpoints | select | region | DryRun, MaxResults, NextToken, Filter, InstanceConnectEndpointId | Describes the specified EC2 Instance Connect Endpoints or all EC2 Instance Connect Endpoints. |
create_instance_connect_endpoint | insert | SubnetId, region | DryRun, SecurityGroupId, PreserveClientIp, ClientToken, TagSpecification, IpAddressType | Creates an EC2 Instance Connect Endpoint. An EC2 Instance Connect Endpoint allows you to connect to an instance, without requiring the instance to have a public IPv4 or public IPv6 address. For more information, see Connect to your instances using EC2 Instance Connect Endpoint in the Amazon EC2 User Guide. |
modify_instance_connect_endpoint | update | InstanceConnectEndpointId, region | DryRun, IpAddressType, SecurityGroupId, PreserveClientIp | Modifies the specified EC2 Instance Connect Endpoint. For more information, see Modify an EC2 Instance Connect Endpoint in the Amazon EC2 User Guide. |
delete_instance_connect_endpoint | delete | InstanceConnectEndpointId, region | DryRun | Deletes the specified EC2 Instance Connect Endpoint. |
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.
| Name | Datatype | Description |
|---|---|---|
InstanceConnectEndpointId | string | The ID of the EC2 Instance Connect Endpoint to delete. |
SubnetId | string | The ID of the subnet in which to create the EC2 Instance Connect Endpoint. |
region | string | AWS region (default: us-east-1) |
ClientToken | string | Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. |
DryRun | boolean | Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation. |
Filter | array | One or more filters. instance-connect-endpoint-id - The ID of the EC2 Instance Connect Endpoint. state - The state of the EC2 Instance Connect Endpoint (create-in-progress | create-complete | create-failed | delete-in-progress | delete-complete | delete-failed). subnet-id - The ID of the subnet in which the EC2 Instance Connect Endpoint was created. tag:<key> - The key/value combination of a tag assigned to the resource. Use the tag key in the filter name and the tag value as the filter value. For example, to find all resources that have a tag with the key Owner and the value TeamA, specify tag:Owner for the filter name and TeamA for the filter value. tag-key - The key of a tag assigned to the resource. Use this filter to find all resources assigned a tag with a specific key, regardless of the tag value. tag-value - The value of a tag assigned to the resource. Use this filter to find all resources that have a tag with a specific value, regardless of tag key. vpc-id - The ID of the VPC in which the EC2 Instance Connect Endpoint was created. |
InstanceConnectEndpointId | array | One or more EC2 Instance Connect Endpoint IDs. |
IpAddressType | string | The new IP address type for the EC2 Instance Connect Endpoint. PreserveClientIp is only supported on IPv4 EC2 Instance Connect Endpoints. To use PreserveClientIp, the value for IpAddressType must be ipv4. |
MaxResults | integer | The maximum number of items to return for this request. To get the next page of items, make another request with the token returned in the output. For more information, see Pagination. |
NextToken | string | The token returned from a previous paginated request. Pagination continues from the end of the items returned by the previous request. |
PreserveClientIp | boolean | Indicates whether the client IP address is preserved as the source when you connect to a resource. The following are the possible values. true - Use the IP address of the client. Your instance must have an IPv4 address. false - Use the IP address of the network interface. |
SecurityGroupId | array | Changes the security groups for the EC2 Instance Connect Endpoint. The new set of groups you specify replaces the current set. You must specify at least one group, even if it's just the default security group in the VPC. You must specify the ID of the security group, not the name. |
TagSpecification | array | The tags to apply to the EC2 Instance Connect Endpoint during creation. |
SELECT examples
- describe_instance_connect_endpoints
Describes the specified EC2 Instance Connect Endpoints or all EC2 Instance Connect Endpoints.
SELECT
availability_zone,
availability_zone_id,
created_at,
dns_name,
fips_dns_name,
instance_connect_endpoint_arn,
instance_connect_endpoint_id,
ip_address_type,
network_interface_ids,
owner_id,
preserve_client_ip,
public_dns_names,
security_group_ids,
state,
state_message,
subnet_id,
tags,
vpc_id
FROM aws.ec2.instance_connect_endpoints
WHERE region = '{{ region }}' -- required
AND DryRun = '{{ DryRun }}'
AND MaxResults = '{{ MaxResults }}'
AND NextToken = '{{ NextToken }}'
AND Filter = '{{ Filter }}'
AND InstanceConnectEndpointId = '{{ InstanceConnectEndpointId }}'
;
INSERT examples
- create_instance_connect_endpoint
- Manifest
Creates an EC2 Instance Connect Endpoint. An EC2 Instance Connect Endpoint allows you to connect to an instance, without requiring the instance to have a public IPv4 or public IPv6 address. For more information, see Connect to your instances using EC2 Instance Connect Endpoint in the Amazon EC2 User Guide.
INSERT INTO aws.ec2.instance_connect_endpoints (
SubnetId,
region,
DryRun,
SecurityGroupId,
PreserveClientIp,
ClientToken,
TagSpecification,
IpAddressType
)
SELECT
'{{ SubnetId }}',
'{{ region }}',
'{{ DryRun }}',
'{{ SecurityGroupId }}',
'{{ PreserveClientIp }}',
'{{ ClientToken }}',
'{{ TagSpecification }}',
'{{ IpAddressType }}'
RETURNING
availability_zone,
availability_zone_id,
created_at,
dns_name,
fips_dns_name,
instance_connect_endpoint_arn,
instance_connect_endpoint_id,
ip_address_type,
network_interface_ids,
owner_id,
preserve_client_ip,
public_dns_names,
security_group_ids,
state,
state_message,
subnet_id,
tags,
vpc_id
;
# Description fields are for documentation purposes
- name: instance_connect_endpoints
props:
- name: SubnetId
value: "{{ SubnetId }}"
description: Required parameter for the instance_connect_endpoints resource.
- name: region
value: "{{ region }}"
description: Required parameter for the instance_connect_endpoints resource.
- name: DryRun
value: {{ DryRun }}
description: Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.
description: Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.
- name: SecurityGroupId
value: "{{ SecurityGroupId }}"
description: One or more security groups to associate with the endpoint. If you don't specify a security group, the default security group for your VPC will be associated with the endpoint.
description: One or more security groups to associate with the endpoint. If you don't specify a security group, the default security group for your VPC will be associated with the endpoint.
- name: PreserveClientIp
value: {{ PreserveClientIp }}
description: Indicates whether the client IP address is preserved as the source. The following are the possible values. true - Use the client IP address as the source. false - Use the network interface IP address as the source. PreserveClientIp is only supported on IPv4 EC2 Instance Connect Endpoints. To use PreserveClientIp, the value for IpAddressType must be ipv4. Default: false
description: Indicates whether the client IP address is preserved as the source. The following are the possible values. true - Use the client IP address as the source. false - Use the network interface IP address as the source. PreserveClientIp is only supported on IPv4 EC2 Instance Connect Endpoints. To use PreserveClientIp, the value for IpAddressType must be ipv4. Default: false
- name: ClientToken
value: "{{ ClientToken }}"
description: Unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
description: Unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
- name: TagSpecification
value: "{{ TagSpecification }}"
description: The tags to apply to the EC2 Instance Connect Endpoint during creation.
description: The tags to apply to the EC2 Instance Connect Endpoint during creation.
- name: IpAddressType
value: "{{ IpAddressType }}"
description: The IP address type of the endpoint. If no value is specified, the default value is determined by the IP address type of the subnet: dualstack - If the subnet has both IPv4 and IPv6 CIDRs ipv4 - If the subnet has only IPv4 CIDRs ipv6 - If the subnet has only IPv6 CIDRs PreserveClientIp is only supported on IPv4 EC2 Instance Connect Endpoints. To use PreserveClientIp, the value for IpAddressType must be ipv4.
description: The IP address type of the endpoint. If no value is specified, the default value is determined by the IP address type of the subnet: dualstack - If the subnet has both IPv4 and IPv6 CIDRs ipv4 - If the subnet has only IPv4 CIDRs ipv6 - If the subnet has only IPv6 CIDRs PreserveClientIp is only supported on IPv4 EC2 Instance Connect Endpoints. To use PreserveClientIp, the value for IpAddressType must be ipv4.
UPDATE examples
- modify_instance_connect_endpoint
Modifies the specified EC2 Instance Connect Endpoint. For more information, see Modify an EC2 Instance Connect Endpoint in the Amazon EC2 User Guide.
UPDATE aws.ec2.instance_connect_endpoints
SET
-- No updatable properties
WHERE
InstanceConnectEndpointId = '{{ InstanceConnectEndpointId }}' --required
AND region = '{{ region }}' --required
AND DryRun = {{ DryRun}}
AND IpAddressType = '{{ IpAddressType}}'
AND SecurityGroupId = '{{ SecurityGroupId}}'
AND PreserveClientIp = {{ PreserveClientIp}}
RETURNING
return;
DELETE examples
- delete_instance_connect_endpoint
Deletes the specified EC2 Instance Connect Endpoint.
DELETE FROM aws.ec2.instance_connect_endpoints
WHERE InstanceConnectEndpointId = '{{ InstanceConnectEndpointId }}' --required
AND region = '{{ region }}' --required
AND DryRun = '{{ DryRun }}'
;