slimtoolkit / slim

Slim(toolkit): Don't change anything in your container image and minify it by up to 30x (and for compiled languages even more) making it secure too! (free and open source)
Apache License 2.0
19.21k stars 716 forks source link

Can DockerSlim support using DockerImage as a target for lint? #473

Open CZJCC opened 1 year ago

CZJCC commented 1 year ago

Expected Behavior

Is it possible to support the result of 【docker history image】 as the input parameters for lint?


Actual Behavior

image


Steps to Reproduce the Problem

1. 1. 1. --- Specifications ================= - Version: - Platform:
kcq commented 1 year ago

You get a reverse engineered Dockerfile when you run the xray and build commands, which can be used as input to the lint command. The lint command will have this capability natively, but it hasn't been a priority recently. Definitely an opportunity to contribute :-) One of the goals for the lint command is to support this use case where you can point at an image and it would lint the instructions used to build it and other interesting things in the container itself.