Download File via SCP in Ruby

To download a file vie SCP under Ruby, you can just use the NET::SCP class included in ruby like that: require “net/scp” =begin Downloads a single file or a folder via scp Parameters: – +host:: +string+ remote IP or domain to get the file / folder from – +ort+:: +string+ remote port – +use+r:: +string+ remote user […]

Download or upload a file over SSH

#Copy something from this system to some other system: $> scp /path/to/local/file username@hostname:/path/to/remote/file   #Copy something from some system to some other system: $> scp username1@hostname1:/path/to/file username2@hostname2:/path/to/other/file   #Copy something from another system to this system: $> scp username@hostname:/path/to/remote/file /path/to/local/file You can add a port with the -P param You can do it recursive with […]