You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using VOLUME Dockerfile instruction, Kaniko creates a new layer, which contains only the directories specified in VOLUME instruction. Docker does not create those directories in the image at all.
The text was updated successfully, but these errors were encountered:
This issue was interesting to me so I had a quick look at Kaniko's code and it looks like a snapshot of the file system is taken with each layer it builds. If the snapshot contains data it adds a layer. The VOLUME command is creating directories and so the layer has "content."
If Docker doesn't add a layer with the VOLUME command, where does that info get stored in the final container image? Presumably it's written to the image somewhere and the directories are created when the container starts.
When using
VOLUME
Dockerfile instruction, Kaniko creates a new layer, which contains only the directories specified inVOLUME
instruction. Docker does not create those directories in the image at all.The text was updated successfully, but these errors were encountered: