From dd58ce348ff7f6cb405005f918ac722c4432fdd6 Mon Sep 17 00:00:00 2001 From: Zhijiang Hu Date: Mon, 21 Aug 2017 07:58:07 -0400 Subject: [PATCH] Test installing docker-engine result yum.dockerproject.org is slow in China, Daisy should be more sensitive to errors occured when using that URL. Change-Id: I4484a1090f0ad9a88b8c9a5bb948a32d9d0e0101 Signed-off-by: Zhijiang Hu --- backend/kolla/prepare.sh | 1 + tools/setup/install/install_func.sh | 3 +++ 2 files changed, 4 insertions(+) diff --git a/backend/kolla/prepare.sh b/backend/kolla/prepare.sh index b0144674..eac658d4 100755 --- a/backend/kolla/prepare.sh +++ b/backend/kolla/prepare.sh @@ -13,6 +13,7 @@ yum -y install epel-release #curl -sSL https://get.docker.io | bash yum remove -y docker-engine yum install -y https://yum.dockerproject.org/repo/main/centos/7/Packages/docker-engine-17.05.0.ce-1.el7.centos.x86_64.rpm +[ "$?" -ne 0 ] && { exit 1; } mkdir -p /etc/systemd/system/docker.service.d config_path=/etc/systemd/system/docker.service.d/kolla.conf touch /etc/sysconfig/docker diff --git a/tools/setup/install/install_func.sh b/tools/setup/install/install_func.sh index eedb1d3e..2be2be58 100755 --- a/tools/setup/install/install_func.sh +++ b/tools/setup/install/install_func.sh @@ -62,6 +62,7 @@ function ip_to_cidr() function kolla_install { write_install_log "Begin install kolla depends..." + check_installed "docker-engine" if [[ "$has_installed" == "yes" ]];then echo "docker-engine has been already installed" @@ -70,6 +71,8 @@ function kolla_install yum remove -y docker-engine yum install -y https://yum.dockerproject.org/repo/main/centos/7/Packages/docker-engine-17.05.0.ce-1.el7.centos.x86_64.rpm fi + [ "$?" -ne 0 ] && { write_install_log "Install docker-engine failed"; exit 1; } + mkdir -p /etc/systemd/system/docker.service.d config_path=/etc/systemd/system/docker.service.d/kolla.conf echo -e "[Service]\nMountFlags=shared" > $config_path