Class: Backzilla::Store::SSH
- Inherits:
-
Backzilla::Store
- Object
- Backzilla::Store
- Backzilla::Store::SSH
- Defined in:
- lib/backzilla/store/ssh.rb
Instance Attribute Summary
Attributes inherited from Backzilla::Store
Instance Method Summary collapse
-
#initialize(name, options) ⇒ SSH
constructor
A new instance of SSH.
- #put(source_path, project_name, entity_name) ⇒ Object
Methods inherited from Backzilla::Store
#delete, #get, gnugpg_passphrase=
Methods included from Executor
Methods included from LoggerHelper
Constructor Details
#initialize(name, options) ⇒ SSH
Returns a new instance of SSH.
4 5 6 7 8 9 |
# File 'lib/backzilla/store/ssh.rb', line 4 def initialize(name, ) super(name) @path = ['path'] @host = ['host'] @user = ['user'] end |
Instance Method Details
#put(source_path, project_name, entity_name) ⇒ Object
11 12 13 14 15 16 |
# File 'lib/backzilla/store/ssh.rb', line 11 def put(source_path, project_name, entity_name) Net::SSH.start(@host, @user ) do |ssh| ssh.exec "mkdir -p " + @path.to_s + "/#{project_name}/#{entity_name}" end super end |