The way to Extract the Recordsdata in a Docker Picture



Ever wanted to extract the information in a Docker container?

Docker offers the save sub-command.

Exporting Docker information right into a Tar Archive

The examples beneath use a Docker container referred to as: aoms/hellojava

Swap this out with your personal container as required.

docker save aoms/hellojava > hellojava.tar

hellojava.tar now incorporates an inventory of information discovered within the Docker picture.

Taking it one step additional

You may make this a bit higher by extracting it into a brand new listing and untarring mechanically:

mkdir tmpimage && cd $_ && docker save aoms/hellojava > _out.tar && tar -xvf _out.tar && open .