Class: Remotus::SshConnection::GatewayConnection
- Inherits:
-
Object
- Object
- Remotus::SshConnection::GatewayConnection
- Extended by:
- Forwardable
- Defined in:
- lib/remotus/ssh_connection.rb
Overview
Internal gateway connection class to allow for the host and metadata to be pulled for the gateway by authentication credentials
Instance Attribute Summary collapse
-
#connection ⇒ Net::SSH::Gateway
Connection gateway connection.
-
#host ⇒ String
readonly
Host gateway hostname.
-
#port ⇒ Integer
readonly
Remote port.
Instance Method Summary collapse
-
#initialize(host, port = REMOTE_PORT, metadata = {}) ⇒ GatewayConnection
constructor
Creates a GatewayConnection.
Constructor Details
#initialize(host, port = REMOTE_PORT, metadata = {}) ⇒ GatewayConnection
Creates a GatewayConnection
64 65 66 67 68 |
# File 'lib/remotus/ssh_connection.rb', line 64 def initialize(host, port = REMOTE_PORT, = {}) @host = host @port = port @metadata = end |
Instance Attribute Details
#connection ⇒ Net::SSH::Gateway
Returns connection gateway connection.
52 53 54 |
# File 'lib/remotus/ssh_connection.rb', line 52 def connection @connection end |
#host ⇒ String (readonly)
Returns host gateway hostname.
46 47 48 |
# File 'lib/remotus/ssh_connection.rb', line 46 def host @host end |
#port ⇒ Integer (readonly)
Returns Remote port.
49 50 51 |
# File 'lib/remotus/ssh_connection.rb', line 49 def port @port end |