[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [atomic-devel] Atomic Scan - pass image details to scanner

On 07/18/2016 04:31 AM, Dharmit Shah wrote:

I'm creating a custom scanner based on atomic scan and am kind of stuck
at passing/fetching the details of image under scan to/in the scanner.

While going through atomic source code, I figured that under
`Atomic/scan.py` we access the image by `self.args.scan_targets`.
However, I don't quite understand how it passes the details to custom
scanner so that one can access image name in the scanner.

I'd like to spin a container from the image and run some checks on the
live container.


I believe it will just mount up the containers image onto a rootfs and expose the rootfs to the scanner. The rootfs mount point will container the containerid as the directory name and the output will be generated in a containerid name. The scanner does not know if the rootfs came from a container
image, base image, vm's image or even the hosts "/".

atomic scan --rootfs /random/path

Will hand the scanner any directory.

One other interesting thing you can do is mount the container images content live.

atomic mount --live CONTAINERID /mnt

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]