Class: Backup::RemoteArchive::DSL
- Inherits:
-
Object
- Object
- Backup::RemoteArchive::DSL
- Defined in:
- lib/backup/remote_archive.rb
Overview
DSL for RemoteArchive
Instance Method Summary collapse
- #add(path) ⇒ Object
- #exclude(path) ⇒ Object
-
#initialize(options) ⇒ DSL
constructor
A new instance of DSL.
- #root(path) ⇒ Object
-
#server_host=(val = true) ⇒ Object
remote server.
- #server_ssh_key=(val = true) ⇒ Object
- #server_ssh_password=(val = true) ⇒ Object
- #server_ssh_port=(val = true) ⇒ Object
- #server_ssh_user=(val = true) ⇒ Object
- #tar_options(opts) ⇒ Object
- #use_sudo(val = true) ⇒ Object
Constructor Details
#initialize(options) ⇒ DSL
Returns a new instance of DSL.
227 228 229 |
# File 'lib/backup/remote_archive.rb', line 227 def initialize() @options = end |
Instance Method Details
#add(path) ⇒ Object
260 261 262 |
# File 'lib/backup/remote_archive.rb', line 260 def add(path) @options[:paths] << path end |
#exclude(path) ⇒ Object
264 265 266 |
# File 'lib/backup/remote_archive.rb', line 264 def exclude(path) @options[:excludes] << path end |
#root(path) ⇒ Object
256 257 258 |
# File 'lib/backup/remote_archive.rb', line 256 def root(path) @options[:root] = path end |
#server_host=(val = true) ⇒ Object
remote server
233 234 235 |
# File 'lib/backup/remote_archive.rb', line 233 def server_host=(val = true) @options[:server_host] = val end |
#server_ssh_key=(val = true) ⇒ Object
247 248 249 |
# File 'lib/backup/remote_archive.rb', line 247 def server_ssh_key=(val = true) @options[:server_ssh_key] = val end |
#server_ssh_password=(val = true) ⇒ Object
244 245 246 |
# File 'lib/backup/remote_archive.rb', line 244 def server_ssh_password=(val = true) @options[:server_ssh_password] = val end |
#server_ssh_port=(val = true) ⇒ Object
237 238 239 |
# File 'lib/backup/remote_archive.rb', line 237 def server_ssh_port=(val = true) @options[:server_ssh_port] = val end |
#server_ssh_user=(val = true) ⇒ Object
241 242 243 |
# File 'lib/backup/remote_archive.rb', line 241 def server_ssh_user=(val = true) @options[:server_ssh_user] = val end |
#tar_options(opts) ⇒ Object
268 269 270 |
# File 'lib/backup/remote_archive.rb', line 268 def (opts) @options[:tar_options] = opts end |
#use_sudo(val = true) ⇒ Object
252 253 254 |
# File 'lib/backup/remote_archive.rb', line 252 def use_sudo(val = true) @options[:sudo] = val end |