summaryrefslogtreecommitdiffstats
path: root/ci/02-deploybundle.sh
diff options
context:
space:
mode:
Diffstat (limited to 'ci/02-deploybundle.sh')
-rwxr-xr-xci/02-deploybundle.sh34
1 files changed, 27 insertions, 7 deletions
diff --git a/ci/02-deploybundle.sh b/ci/02-deploybundle.sh
index 647d18b0..974d65ac 100755
--- a/ci/02-deploybundle.sh
+++ b/ci/02-deploybundle.sh
@@ -25,18 +25,23 @@ fi
#check whether charms are still executing the code even juju-deployer says installed.
check_status() {
+ waitstatus=$1
retval=0
timeoutiter=0
+
+ echo -n "executing the reltionship within charms ."
while [ $retval -eq 0 ]; do
- sleep 30
- juju status > status.txt
- if [ "$(grep -c "waiting" status.txt )" -ge 2 ]; then
- echo " still waiting for machines ..."
+ if juju status | grep -q $waitstatus; then
+ echo -n '.'
if [ $timeoutiter -ge 240 ]; then
+ echo 'timed out'
retval=1
+ else
+ sleep 30
fi
timeoutiter=$((timeoutiter+1))
else
+ echo 'done'
retval=1
fi
done
@@ -113,7 +118,7 @@ case "$opnfvlab" in
;;
esac
-# lets put the if seperateor as "," as this will save me from world.
+# lets put the if separator as "," as this will save me from world.
fea=""
IFS=","
for feature in $opnfvfeature; do
@@ -128,7 +133,7 @@ if [[ "$opnfvmodel" = "openstack" ]]; then
#update source if trusty is target distribution
var=os-$opnfvsdn-$fea-$opnfvtype"-"$opnfvdistro"_"$openstack
- if [ "$osdomname" != "None" ]; then
+ if ([ $osdomname ] && [ $osdomname != "null" ] && [ $osdomname != "None"]); then
var=$var"_"publicapi
fi
else
@@ -164,7 +169,7 @@ else
# with JUJU 2.0 bundles has to be deployed only once.
juju deploy bundles.yaml --debug
sleep 120
- check_status
+ check_status allocating
# seeing issue related to number of open files.
count=`juju status nodes --format=short | grep nodes | wc -l`
c=0
@@ -177,5 +182,20 @@ else
done
fi
+if [ "$opnfvsdn" = "ocl" ]
+then
+ ROLES="contrail-controller contrail-analytics contrail-analyticsdb"
+ TAG="ubuntu16.04-4.0.0.0-20.tar.gz"
+
+ for ROLE in $ROLES
+ do
+ FILE="${ROLE}-${TAG}"
+ if [ ! -f $FILE ]
+ then
+ curl -o $FILE http://artifacts.opnfv.org/ovno/containers/$FILE
+ fi
+ juju attach $ROLE ${ROLE}="./$FILE"
+done
+fi
#lets gather the status of deployment once juju-deployer completed.
juju status --format=tabular