Skip to content

Commit

Permalink
Image scanning: Add image name to task name
Browse files Browse the repository at this point in the history
  • Loading branch information
zakiva committed Aug 29, 2017
1 parent e7128a9 commit 01d2295
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,12 @@ def scan_job_create(entity)

def raw_scan_job_create(target_class, target_id = nil, userid = nil)
target_class, target_id = target_class.class.name, target_class.id if target_class.kind_of?(ContainerImage)
target_name = target_class.constantize.find_by(:id => target_id).name
userid ||= User.current_user.userid
Job.create_job(
"ManageIQ::Providers::Kubernetes::ContainerManager::Scanning::Job",
:userid => userid,
:name => "Container image analysis",
:name => "Container image '#{target_name}' analysis",
:target_class => target_class,
:target_id => target_id,
:zone => my_zone,
Expand Down

0 comments on commit 01d2295

Please sign in to comment.