Mercurial > public > ssdt-docker
comparison scripts/updates-pull.sh @ 51:40e10b1d32f7
add script to apply image updates to compose projects
author | Dave smith <smith@nwoca.org> |
---|---|
date | Mon, 22 Feb 2016 17:32:57 -0500 |
parents | scripts/pull-updates.sh@757f89c5a19c |
children | 334d65dac778 |
comparison
equal
deleted
inserted
replaced
50:c1f38cbf1294 | 51:40e10b1d32f7 |
---|---|
1 # | |
2 # Pulls updates from upstream repository for images matching filter. The | |
3 # default filter pulls all ssdt application images. | |
4 # | |
5 # Usage: | |
6 # pull-updates.sh [application] [filter] | |
7 # | |
8 # defaults: | |
9 # application=all applications | |
10 # filter=label=io.ssdt.app[=application] | |
11 # | |
12 # Note: if filter is provided, the first argument is ignored. A complete filter must be supplied. | |
13 # | |
14 APP=${1:+=$1} | |
15 FILTER=${2:-label=io.ssdt.app$APP} | |
16 while read -a line | |
17 do | |
18 repo=${line[0]} | |
19 tag=${line[1]} | |
20 if [[ $repo == docker.ssdt.io* ]] | |
21 then | |
22 echo "docker pull ${repo}:${tag}" | |
23 docker pull ${repo}:${tag} | |
24 fi | |
25 done < <(docker images --filter "$FILTER") |