Created
April 2, 2018 07:46
-
-
Save hjue/5f9892ed063ce1236f2b4f6ec97394df to your computer and use it in GitHub Desktop.
pull heapster image
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/sh | |
images=( | |
gcr.io/google_containers/heapster-amd64:v1.5.2 | |
gcr.io/google_containers/heapster-influxdb-amd64:v1.3.3 | |
gcr.io/google_containers/heapster-grafana-amd64:v4.4.3 | |
) | |
pullImage(){ | |
if [ x$1 != x ] | |
then | |
image=$1 | |
fullname=$(basename $image) | |
path=$(dirname $image) | |
docker pull registry-internal.cn-hangzhou.aliyuncs.com/gionee/$fullname | |
docker tag registry-internal.cn-hangzhou.aliyuncs.com/gionee/$fullname $image | |
docker rmi registry-internal.cn-hangzhou.aliyuncs.com/gionee/$fullname | |
fi | |
} | |
for imageName in ${images[@]} ; do | |
pullImage $imageName | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment