Save an image to an archive

Exports an image to move it into an air-gapped network

docker save img:tag | gzip > img.tar.gz

tool
docker46 commands
tags
docker

More docker commands

  • docker build --build-arg VERSION=1.2.3 --build-arg ENV=prod -t img:tag .

    Passes build-time variables to ARG instructions in the Dockerfile

  • trivy image --exit-code 1 --severity HIGH,CRITICAL img:tag

    Fails the pipeline if HIGH or CRITICAL CVEs are found

  • docker sbom img:tag

    Generates a Software Bill of Materials for an image (Docker Desktop)

  • docker inspect <container> | jq '.[0].NetworkSettings.Networks'

    Shows the network settings of a running container

  • docker compose up -d --build

    Builds and starts all services in the background

all 46 docker commands