class VirusScanService::KasperskyRunner::LinuxExecutor
Public Instance Methods
scan(file_path, log_path)
click to toggle source
# File lib/virus_scan_service/kaspersky_runner/linux_executor.rb, line 5 def scan(file_path, log_path) stdout, stderr, status = Open3.capture3( "sudo /opt/kaspersky/kes4lwks/bin/kes4lwks-control --scan-file #{file_path.to_s}" ) File.open(log_path.to_s, 'w') { |file| file.write(stdout) } end