This file contains hidden or 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
#!/bin/bash -ex | |
# Wrapper for 'docker save' fixing, | |
# https://github.com/dotcloud/docker/issues/3877 | |
# In addition: this script will always save exactly one image (possibly | |
# multiple tags). | |
IMAGE=$1 | |
TARGET=$2 | |
NAME=`echo $IMAGE | awk -F':' '{print $1}'` | |
ID=`docker inspect $IMAGE | python -c "import sys,json; print json.load(sys.stdin)[0]['id']"` |