docker save
#! /usr/bin/env bash myflag=".tar.gz" for srcimage in `cat ./deploy_images/$image_txt` do project=`echo $srcimage | awk -F'/' '{print $NF}'` docker pull $srcimage docker save $srcimage |gzip > $project$myflag done