Images: add pull all images to makefile
This PS adds a `pull-all-images` target to the makefile, which requires yq to operate. Change-Id: I58b871b99f48cbd636b3db66db812be3dfc1a204
This commit is contained in:
parent
fe6107cf76
commit
a89ee54171
3
Makefile
3
Makefile
@ -44,4 +44,7 @@ clean:
|
||||
rm -f */requirements.lock
|
||||
-rmdir -p */charts
|
||||
|
||||
pull-all-images:
|
||||
@./tools/pull-images.sh
|
||||
|
||||
.PHONY: $(EXCLUDES) $(CHARTS)
|
||||
|
@ -65,6 +65,7 @@ function base_install {
|
||||
sudo -H pip install --upgrade pip
|
||||
sudo -H pip install --upgrade setuptools
|
||||
sudo -H pip install pyyaml
|
||||
sudo -H pip install yq
|
||||
|
||||
if [ "x$SDN_PLUGIN" == "xlinuxbridge" ]; then
|
||||
sdn_lb_support_install
|
||||
|
@ -60,6 +60,7 @@ if [ "x$INTEGRATION_TYPE" == "xlinter" ]; then
|
||||
helm_plugin_template_install
|
||||
helm_template_run
|
||||
else
|
||||
cd ${WORK_DIR}; make pull-all-images
|
||||
# Setup the K8s Cluster
|
||||
if [ "x$INTEGRATION" == "xaio" ]; then
|
||||
bash ${WORK_DIR}/tools/gate/kubeadm_aio.sh
|
||||
|
9
tools/pull-images.sh
Executable file
9
tools/pull-images.sh
Executable file
@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
set -x
|
||||
for CHART_DIR in ./*/ ; do
|
||||
if [ -e ${CHART_DIR}values.yaml ]; then
|
||||
for IMAGE in $(cat ${CHART_DIR}values.yaml | yq '.images.tags | map(.) | join(" ")' | tr -d '"'); do
|
||||
docker inspect $IMAGE >/dev/null|| docker pull $IMAGE
|
||||
done
|
||||
fi
|
||||
done
|
Loading…
x
Reference in New Issue
Block a user