Is there any vulnerability or security issues in Chiseled images build with multistage docker file. #5641
-
I am confused about the security issues or vulnerabilities in the custom chiseled images built with the multistage docker file. As a security purpose, chiseled images removed all the commands like curl, wget, rm, apt, apt-get etc. And it builds a non-interactive image container. So I choose the approach where I build a custom base image(docker file is attached below) in which, in first stage I used So the question is, Is there any security issue or vulnerability in the created custom base image? Also, the created custom base image can be considered as Dockerfile of custom base image with newrelic dotnet agent installed.
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 7 replies
-
There are no images that are immune from security vulnerabilities. You are correct that chiseled images are good because they have fewer components so are subject to fewer CVEs.
I can see that this is coming from newrelic docs. In your Dockerfile, this line doesn't seem to be doing anything useful since those packages are not preserved across the stages. |
Beta Was this translation helpful? Give feedback.
I responded at dotnet/sdk-container-builds#325.
I hope you understand @Amit-limbasiya that creating a base image is not a one-time thing. It would need to be updated very frequently (since security seems to be a primary concern). We officially update our images once/month with new .NET patches. We also update out images every time there is a base image update (like of Debian). That can happen multiple times per month. The only way to stay as secure as what you want is to use images that are updated at the same cadence as the official .NET images.