Class: Kitchen::Transport::Ssh::Connection
- Inherits:
-
Object
- Object
- Kitchen::Transport::Ssh::Connection
- Defined in:
- lib/kitchen/provisioner/chef_zero_nodes.rb
Instance Method Summary collapse
-
#download(remote, local) ⇒ Object
Download JSON node file from instance to node_path over SCP.
Instance Method Details
#download(remote, local) ⇒ Object
Download JSON node file from instance to node_path over SCP
78 79 80 81 82 83 84 |
# File 'lib/kitchen/provisioner/chef_zero_nodes.rb', line 78 def download(remote, local) FileUtils.mkdir_p(File.dirname(local)) session.scp.download!(remote, local, {}) logger.debug("Downloaded #{remote} to #{local}") rescue Net::SSH::Exception => ex raise SshFailed, "SCP download failed (#{ex.})" end |