Class: Aws::EC2InstanceConnect::Client
- Inherits:
-
Seahorse::Client::Base
- Object
- Seahorse::Client::Base
- Aws::EC2InstanceConnect::Client
- Includes:
- ClientStubs
- Defined in:
- lib/aws-sdk-ec2instanceconnect/client.rb
Overview
An API client for EC2InstanceConnect. To construct a client, you need to configure a ‘:region` and `:credentials`.
client = Aws::EC2InstanceConnect::Client.new(
region: region_name,
credentials: credentials,
# ...
)
For details on configuring region and credentials see the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html).
See #initialize for a full list of supported configuration options.
Class Attribute Summary collapse
- .identifier ⇒ Object readonly private
API Operations collapse
-
#send_serial_console_ssh_public_key(params = {}) ⇒ Types::SendSerialConsoleSSHPublicKeyResponse
Pushes an SSH public key to the specified EC2 instance.
-
#send_ssh_public_key(params = {}) ⇒ Types::SendSSHPublicKeyResponse
Pushes an SSH public key to the specified EC2 instance for use by the specified user.
Class Method Summary collapse
- .errors_module ⇒ Object private
Instance Method Summary collapse
- #build_request(operation_name, params = {}) ⇒ Object private
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
- #waiter_names ⇒ Object deprecated private Deprecated.
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
429 430 431 |
# File 'lib/aws-sdk-ec2instanceconnect/client.rb', line 429 def initialize(*args) super end |
Class Attribute Details
.identifier ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
587 588 589 |
# File 'lib/aws-sdk-ec2instanceconnect/client.rb', line 587 def identifier @identifier end |
Class Method Details
.errors_module ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
590 591 592 |
# File 'lib/aws-sdk-ec2instanceconnect/client.rb', line 590 def errors_module Errors end |
Instance Method Details
#build_request(operation_name, params = {}) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
565 566 567 568 569 570 571 572 573 574 575 576 |
# File 'lib/aws-sdk-ec2instanceconnect/client.rb', line 565 def build_request(operation_name, params = {}) handlers = @handlers.for(operation_name) context = Seahorse::Client::RequestContext.new( operation_name: operation_name, operation: config.api.operation(operation_name), client: self, params: params, config: config) context[:gem_name] = 'aws-sdk-ec2instanceconnect' context[:gem_version] = '1.45.0' Seahorse::Client::Request.new(handlers, context) end |
#send_serial_console_ssh_public_key(params = {}) ⇒ Types::SendSerialConsoleSSHPublicKeyResponse
Pushes an SSH public key to the specified EC2 instance. The key remains for 60 seconds, which gives you 60 seconds to establish a serial console connection to the instance using SSH. For more information, see [EC2 Serial Console] in the *Amazon EC2 User Guide*.
[1]: docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-serial-console.html
556 557 558 559 |
# File 'lib/aws-sdk-ec2instanceconnect/client.rb', line 556 def send_serial_console_ssh_public_key(params = {}, = {}) req = build_request(:send_serial_console_ssh_public_key, params) req.send_request() end |
#send_ssh_public_key(params = {}) ⇒ Types::SendSSHPublicKeyResponse
Pushes an SSH public key to the specified EC2 instance for use by the specified user. The key remains for 60 seconds. For more information, see [Connect to your Linux instance using EC2 Instance Connect] in the *Amazon EC2 User Guide*.
[1]: docs.aws.amazon.com/AWSEC2/latest/UserGuide/Connect-using-EC2-Instance-Connect.html
500 501 502 503 |
# File 'lib/aws-sdk-ec2instanceconnect/client.rb', line 500 def send_ssh_public_key(params = {}, = {}) req = build_request(:send_ssh_public_key, params) req.send_request() end |
#waiter_names ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
580 581 582 |
# File 'lib/aws-sdk-ec2instanceconnect/client.rb', line 580 def waiter_names [] end |