Skip to content

Instantly share code, notes, and snippets.

@TvL2386
Created September 5, 2013 09:15
Show Gist options
  • Save TvL2386/6447834 to your computer and use it in GitHub Desktop.
Save TvL2386/6447834 to your computer and use it in GitHub Desktop.
Net::SCP keeps failing...
require 'net/scp'
# using:
#* net-scp (1.1.2)
#* net-ssh (2.6.8)
# Both fail
Net::SCP.download!('localhost', 'me','/tmp/bla.rb','/tmp/bla2.rb', password: 'mypass')
Net::SCP.download!('localhost', 'me','/tmp/bla.rb','/tmp/bla2.rb', password: 'mypass', ssh: {auth_methods: %w(password)})
# output:
#/usr/local/rvm/gems/ruby-2.0.0-p0/gems/net-ssh-2.6.8/lib/net/ssh.rb:207:in `start': tom (Net::SSH::AuthenticationFailed)
# from /usr/local/rvm/gems/ruby-2.0.0-p0/gems/net-scp-1.1.2/lib/net/scp.rb:197:in `start'
# from /usr/local/rvm/gems/ruby-2.0.0-p0/gems/net-scp-1.1.2/lib/net/scp.rb:235:in `download!'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment