Class: BackupClient::Components::Ftp::Commands::Upload
- Inherits:
-
Object
- Object
- BackupClient::Components::Ftp::Commands::Upload
- Includes:
- Helpers::FtpHelper, Helpers::LogHelper
- Defined in:
- lib/backup_client/components/ftp/commands/upload.rb
Constant Summary collapse
- FTP_PORT =
21
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(provider, source_paths, timestamp:, use_timestamp: false) ⇒ Upload
constructor
A new instance of Upload.
Methods included from Helpers::FtpHelper
#ftp_chdir, #ftp_dir_exists?, #ftp_mkdir, #ftp_mkdir_p, #root_chdir, #to_unix_path, #upload_dir_ftp, #upload_file_ftp
Methods included from Helpers::LogHelper
Constructor Details
#initialize(provider, source_paths, timestamp:, use_timestamp: false) ⇒ Upload
Returns a new instance of Upload.
13 14 15 16 17 18 |
# File 'lib/backup_client/components/ftp/commands/upload.rb', line 13 def initialize(provider, source_paths, timestamp:, use_timestamp: false) @provider = provider @source_paths = source_paths = = end |
Instance Method Details
#call ⇒ Object
20 21 22 23 24 25 26 |
# File 'lib/backup_client/components/ftp/commands/upload.rb', line 20 def call ftp_mkdir_p(destination_path) ftp_processing ftp_client.close end |