Skip to content

Commit 8bcaa39

Browse files
committed
added dockerfile and base image processing
1 parent 64e0f08 commit 8bcaa39

File tree

1 file changed

+17
-5
lines changed

1 file changed

+17
-5
lines changed

examples/scan_docker_image_lite.py

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,17 +33,29 @@
3333
3434
Layers are numbered in chronological order
3535
36+
If a dockerfile or a base image spec is available, grouping could be done based on the
37+
information gathered from those sources.
38+
39+
layers that are present in the base image will be grouped as *_base_*
40+
layers that are not present in the base image will be grouped as *_addon_*
41+
42+
43+
3644
Usage:
3745
38-
scan_docker_image_slim.py [-h] imagespec [--grouping=group_end:group_name,group_end:group_name]
46+
scan_docker_image_slim.py [-h] imagespec [--grouping=group_end:group_name,group_end:group_name] | [--dockerfile=Dockerfile | --base-image=baseimagespec]
3947
4048
positional arguments:
41-
imagespec Container image tag, e.g. repository/imagename:version
49+
imagespec Container image tag, e.g. repository/imagename:version
4250
4351
optional arguments:
44-
-h, --help show this help message and exit
45-
46-
--grouping=group_end:group_name,group_end:group_name specify layer grouping
52+
-h, --help show this help message and exit
53+
--grouping GROUPING Group layers into user defined provect versions (can't be used with --base-image)
54+
--base-image BASE_IMAGE
55+
Use base image spec to determine base image/layers (can't be used with --grouping or
56+
--dockerfile)
57+
--dockerfile DOCKERFILE
58+
Use Dockerfile to determine base image/layers (can't be used with --grouping or ---base-image)
4759
4860
'''
4961

0 commit comments

Comments
 (0)