def upload_output_to_s3
      update_status "Uploading output file #{::File.basename @sql_file}"
      dump_path = "#{@s3_path}/#{::File.basename @sql_file}"
      s3.put_object(@bucket, dump_path, File.read(@sql_file))
      upload = s3.directories.get(@bucket).files.get dump_path
      @files = [ {
        name: ::File.basename(@sql_file),
        size: upload.content_length,
        url:  upload.url(Time.now + (3600 * 24 * 30))  # 30 days from now
      } ]
      @log.info "Deleting tmp directory #{File.dirname @sql_file}"
      FileUtils.rm_rf(File.dirname @sql_file)
    end
def upload_output_to_s3
      update_status "Uploading output file #{::File.basename @sql_file}"
      dump_path = "#{@s3_path}/#{::File.basename @sql_file}"
      s3.put_object(@bucket, dump_path, File.read(@sql_file))
      upload = s3.directories.get(@bucket).files.get dump_path
      @files = [ {
        name: ::File.basename(@sql_file),
        size: upload.content_length,
        url:  upload.url(Time.now + (3600 * 24 * 30))  # 30 days from now
      } ]
      @log.info "Deleting tmp directory #{File.dirname @sql_file}"
      FileUtils.rm_rf(File.dirname @sql_file)
    end
Uploads the compressed SQL file to S3