New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
slim build
doesn't generate optimized Dockerfile
#589
Comments
@anferico this is because the build engine parameter to create the minified image now defaults to the "internal" build engine that doesn't use Docker. The Dockerfile for the output image is present only then the output build engine needs it. You can verify it by looking at the "image_build_engine" field in the "slim.report.json" file, which should say "internal". The next release will remove that console message to avoid the confusion. Thanks for reporting this! |
@kcq Thanks for your reply 👍 I didn't understand whether it's possible to obtain an optimized Dockerfile or not though. Did I miss some important flags in the commands I ran? In fact, am I running the correct commands? |
@anferico you can still get the Dockerfile for the output/optimized image if you use the 'docker' build engine. You can use the |
Expected Behavior
In addition to a minified Docker image, get an optimized Dockerfile that you can reuse to build new images.
Actual Behavior
The minified Docker image is created, but the optimized Dockerfile isn't. These are the only artifacts coming out of
slim build
:my_docker_image-apparmor-profile
my_docker_image-seccomp.json
Dockerfile.fat
creport.json
files.tar
However, the optimized Dockerfile appears in
slim build
's logs:Steps to Reproduce the Problem
slim xray
on a Docker image to get areport.json
fileslim build
passingreport.json
and targeting the Docker image you want to minify/optimizeSpecifications
linux|Transformer|1.40.4|d310b07567dc90763f5f27f94c618f057295b55d|2023-08-26_01:39:22AM
The text was updated successfully, but these errors were encountered: