Image puller: fix user and location in gate.

This PS fixes the location of the image pull command in the gate
and also moves the position it is run at to after docker is
installed.

Change-Id: I45573ae18147a44e99698bfac208fe1f2dcf6128
This commit is contained in:
intlabs 2017-11-01 13:44:31 -05:00 committed by Pete Birley
parent 5df00a4d78
commit 4d0492a9fc
3 changed files with 7 additions and 4 deletions

View File

@ -80,8 +80,10 @@ function kubeadm_aio_reqs_install {
sudo yum install -y \
epel-release
sudo yum install -y \
docker-latest \
jq
docker-latest
# We need JQ 1.5 which is not currently in the CentOS or EPEL repos
sudo curl -L -o /usr/bin/jq https://github.com/stedolan/jq/releases/download/jq-1.5/jq-linux64
sudo chmod +x /usr/bin/jq
sudo cp -f /usr/lib/systemd/system/docker-latest.service /etc/systemd/system/docker.service
sudo sed -i "s|/var/lib/docker-latest|/var/lib/docker|g" /etc/systemd/system/docker.service
sudo sed -i 's/^OPTIONS/#OPTIONS/g' /etc/sysconfig/docker-latest

View File

@ -60,7 +60,6 @@ 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
@ -68,6 +67,8 @@ else
bash ${WORK_DIR}/tools/gate/kubeadm_aio.sh
bash ${WORK_DIR}/tools/gate/setup_gate_worker_nodes.sh
fi
# Pull all required images
cd ${WORK_DIR}; make pull-all-images
if [ "x$LOOPBACK_CREATE" == "xtrue" ]; then
loopback_dev_info_collect
kube_label_node_block_devs

View File

@ -3,7 +3,7 @@ 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
sudo docker inspect $IMAGE >/dev/null|| sudo docker pull $IMAGE
done
fi
done