Sha256: 3bb846834ff485fb33853d944d09100dd3935e4e2c8374bb4e763e1d46cd7e5d
Contents?: true
Size: 540 Bytes
Versions: 2
Compression:
Stored size: 540 Bytes
Contents
require "rye" @hostname = "onetimesecret.com" ## Don't prompt for password if "publickey" is the only :auth_method box = Rye::Box.new( @hostname, :auth_methods => ["publickey"] ) begin box.connect rescue Net::SSH::AuthenticationFailed => ex ex.class end #=> Net::SSH::AuthenticationFailed ## Never prompt for password if :no_password_prompt option is true box = Rye::Box.new(@hostname, :password_prompt => false) begin box.connect rescue Net::SSH::AuthenticationFailed => ex ex.class end #=> Net::SSH::AuthenticationFailed
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rye-0.9.13 | try/14_auth_methods_tryouts.rb |
rye-0.9.12 | try/14_auth_methods_tryouts.rb |