Forked from lsauer/Docker: save_load_compressed_container.bash
Created
March 21, 2022 22:08
-
-
Save caputomarcos/349c7bf706fa4bc07a07a1b2b7740bed to your computer and use it in GitHub Desktop.
Docker: save/load container using tgz file (tar.gz)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#for an image ("not running container") use save: | |
docker save <dockernameortag> | gzip > mycontainer.tgz | |
#for running or paused docker, use export: | |
docker export <dockernameortag> | gzip > mycontainer.tgz | |
#load | |
gunzip -c mycontainer.tgz | docker load |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment