What is the difference between save and export in Docker?

前端 未结 6 1573
既然无缘
既然无缘 2021-01-29 17:52

I am playing around with Docker for a couple of days and I already made some images (which was really fun!). Now I want to persist my work and came to the save and

6条回答
  •  旧时难觅i
    2021-01-29 18:33

    export: container (filesystem)->image tar.
    import: exported image tar-> image. Only one layer.

    save: image-> image tar.
    load: saved image tar->image. All layers will be recovered.

    From Docker in Action, Second Edition p190.

    Layered images maintain the history of the image, container-creation metadata, and old files that might have been deleted or overridden.

    Flattened images contain only the current set of files on the filesystem.

提交回复
热议问题