Class: Phase::CLI::SSH
- Includes:
- Mixins::Loggable
- Defined in:
- lib/phase/cli/ssh.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#instance ⇒ Object
writeonly
Sets the attribute instance.
-
#username ⇒ Object
writeonly
Sets the attribute username.
Attributes inherited from Command
Instance Method Summary collapse
Methods included from Mixins::Loggable
Methods inherited from Command
Constructor Details
This class inherits a constructor from Phase::CLI::Command
Instance Attribute Details
#instance=(value) ⇒ Object
Sets the attribute instance
22 23 24 |
# File 'lib/phase/cli/ssh.rb', line 22 def instance=(value) @instance = value end |
#username=(value) ⇒ Object
Sets the attribute username
22 23 24 |
# File 'lib/phase/cli/ssh.rb', line 22 def username=(value) @username = value end |
Instance Method Details
#run ⇒ Object
24 25 26 27 28 |
# File 'lib/phase/cli/ssh.rb', line 24 def run parse_connection_string log "connecting to instance #{ instance.resource.id }..." exec "#{ options.conn } #{ username }@#{ instance.resource.dns_name }" end |