Table of Contents
A low-level client representing AWS EC2 Instance Connect:
import boto3
client = boto3.client('ec2-instance-connect')
These are the available methods:
Check if an operation can be paginated.
Generate a presigned url given a client, its method, and arguments
The presigned url
Create a paginator for an operation.
Returns an object that can wait for some condition.
Pushes an SSH public key to a particular OS user on a given EC2 instance for 60 seconds.
See also: AWS API Documentation
Request Syntax
response = client.send_ssh_public_key(
InstanceId='string',
InstanceOSUser='string',
SSHPublicKey='string',
AvailabilityZone='string'
)
[REQUIRED]
The EC2 instance you wish to publish the SSH key to.
[REQUIRED]
The OS user on the EC2 instance whom the key may be used to authenticate as.
[REQUIRED]
The public key to be published to the instance. To use it after publication you must have the matching private key.
[REQUIRED]
The availability zone the EC2 instance was launched in.
dict
Response Syntax
{
'RequestId': 'string',
'Success': True|False
}
Response Structure
(dict) --
RequestId (string) --
The request ID as logged by EC2 Connect. Please provide this when contacting AWS Support.
Success (boolean) --
Indicates request success.
The available paginators are: