goharbor / harbor-scanner-clair

Use Clair as a plug-in vulnerability scanner in the Harbor registry
https://goharbor.io/
Apache License 2.0
34 stars 26 forks source link

Full Scan with external Clair scanner. #23

Open ila-001 opened 3 years ago

ila-001 commented 3 years ago

I have configured an external Clair scanner(2.1.7). which is configured to harbor Version v1.10.6. Performed a manual Full scan. Checked in the harbor db it shows as finished, 27 | IMAGE_SCAN_ALL | Generic | {"type":"Manual","cron":""} | finished | 1cd8df1d50ce805a10c2737d | 2021-06-09 09 :29:29 | 2021-06-09 09:38:19.373139 | f | 1623230969 | 3 (8 rows)

However in the console its showing as still running. Is there any way i can stop the scanning.

heww commented 3 years ago

I think you check in the wrong place.

Please check the scan_report to ensure the status of the records are success or error (failed).

ila-001 commented 3 years ago

@heww Scan_report table hold the scan status of individual images. Most of the records shows success. There are some 40000+ records in there. I wanted to stop the Full scan job(IMAGE_SCAN_ALL) which is started manually from admin user. follow up questions: If the scan still running why the job- IMAGE_SCAN_ALL should be marked a finished under admin_job table.

ila-001 commented 3 years ago

As soon as the scheduled full scan for 40000 objects is completed, scan report shows the correct data, However after a while the scan report changes to something like this which is incorrect. I am not sure from where this data is coming from. image