22
33[ ![ CircleCI] ( https://circleci.com/gh/dtrudg/clair-singularity/tree/master.svg?style=svg )] ( https://circleci.com/gh/dtrudg/clair-singularity/tree/master )
44
5- __ Scan [ SingularityCE ] ( http://sylabs.io/singularity/ ) container images for security vulnerabilities
5+ __ Scan [ Singularity ] ( http://sylabs.io/singularity/ ) container images for security vulnerabilities
66using [ CoreOS Clair] ( https://github.com/coreos/clair ) .__
77
8+ ![ screenshot] ( screenshot.png )
9+
810The [ CoreOS Clair vulnerability scanner] ( https://github.com/coreos/clair ) is a useful tool able to scan docker and other container
911formats for security vulnerabilities. It obtains up-to-date lists of vulnerabilities for various
1012platforms (namespaces) from public databases.
@@ -25,7 +27,7 @@ Based on experiments detailed [in this Gist](https://gist.github.com/dctrud/4797
2527
2628__ IMPORTANT NOTES__
2729
28- CI tests usage with SingularityCE 3.9.7
30+ Funtionality was last tested using SingularityCE 3.9.7.
2931
3032This tool should be considered proof of concept, not heavily tested. Use at your own risk.
3133
@@ -39,7 +41,7 @@ Clair instance, or that only a trusted Clair instance can retrieve images from t
3941To use clair-singularity you will need a _ Linux_ host with:
4042
4143 * Python 3.5 or greater installed
42- * Singularity 3+ installed (tested with 3.8.0 ) and the singularity executable in your ` PATH `
44+ * SingularityCE 3+ installed (tested with 3.9.7 ) and the singularity executable in your ` PATH `
4345 * A Clair instance running somewhere, that is able to access the machine you will run
4446 clair-singularity on. It's easiest to accomplish this using docker to run a local Clair instance as below.
4547
@@ -77,15 +79,10 @@ python setup.py install
7779
7880__ Clair on same machine__
7981
80-
81- If you are running ` clair-singularity ` locally (outside of docker), and clair
82- within docker, you need to tell ` clair-singularity ` to serve images on the main
83- IP of your host, so that dockerized clair can access them.
84-
8582To scan a singularity image, using a clair instance running under local docker, on
8683port 6060:
8784
88- clair-singularity myimage.img
85+ clair-singularity myimage.sif
8986
9087/If your hostname is not resolvable to a non-localhost IP of your machine, accessible to
9188docker containers, you must specify the IP with ` --bind-ip ` /
@@ -105,20 +102,3 @@ By default, clair-singularity gives a simplified text report on STDOUT. To obtai
105102report returned by Clair use the ` --jsoon-output ` option.
106103
107104 clair-singularity --json-output myimage.img
108-
109- ## Development / Testing
110-
111- Tests can are run in 3 different ways:
112-
113- __ Local - no access to Clair__
114-
115- Runs all tests that don't depend on access to a Clair server, using the local Python.
116-
117- $ build_scripts/noclair_local_tests.sh
118-
119- __ Local - dockerized with Clair__
120-
121- Starts a Clair service with local docker, builds clair-singularity into a docker container, with Python 3.5, and
122- runs tests in this docker container.
123-
124- $ build_scripts/docker_local_tests.sh
0 commit comments