Method: Toolshed::ServerAdministration::SSH#initialize
- Defined in:
- lib/toolshed/server_administration/ssh.rb
#initialize(options = nil) ⇒ SSH
rubocop:disable AbcSize, CyclomaticComplexity, PerceivedComplexity, LineLength
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/toolshed/server_administration/ssh.rb', line 16 def initialize( = nil) # rubocop:disable AbcSize, CyclomaticComplexity, PerceivedComplexity, LineLength ||= {} @password = [:password] || '' @sudo_password = [:sudo_password] || '' @keys = [:keys] || '' @host = [:host] || '' @user = [:user] || '' @ssh_options = [:ssh_options] || {} @commands = [:commands] || '' @password = [:password] || '' @data = [] @silent = [:silent] || false timeout_period = [:timeout_period].to_i || 30 @timeout = Toolshed::Timeout.new(timeout_period: timeout_period) end |