diff options
author | Carsten Lund <lund@research.att.com> | 2017-05-10 11:31:46 +0000 |
---|---|---|
committer | Carsten Lund <lund@research.att.com> | 2017-05-10 11:31:46 +0000 |
commit | 0604b47f742f4a4dbe6a3151c962dc05df1a833c (patch) | |
tree | c73d5225970bb5725544095ab2cfc86dba99c70e /dcae-demo-controller/src | |
parent | 6a009033be5748ff22b757fdb673f651748a8085 (diff) |
[DCAE-7] DCAE controller miss flavor in first poll
Change-Id: Ie0f32650fa4ef31ff015b31d8d5cb94378d79cad
Signed-off-by: Carsten Lund <lund@research.att.com>
Diffstat (limited to 'dcae-demo-controller/src')
-rw-r--r-- | dcae-demo-controller/src/main/docker-build/controller-startup.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/dcae-demo-controller/src/main/docker-build/controller-startup.sh b/dcae-demo-controller/src/main/docker-build/controller-startup.sh index e31c72b..9e284bb 100644 --- a/dcae-demo-controller/src/main/docker-build/controller-startup.sh +++ b/dcae-demo-controller/src/main/docker-build/controller-startup.sh @@ -16,6 +16,7 @@ export BASE=$(grep BASE /opt/app/dcae-controller/config.yaml | sed s/BASE:.//) OPENSTACK_KEYNAME=$(grep OPENSTACK-KEYNAME /opt/app/dcae-controller/config.yaml | sed s/OPENSTACK-KEYNAME:.//) NETWORK=$(grep OPENSTACK-PRIVATE-NETWORK /opt/app/dcae-controller/config.yaml | sed s/OPENSTACK-PRIVATE-NETWORK:.//) +FLAVOR=$(grep FLAVOR-LARGE /opt/app/dcae-controller/config.yaml | sed s/FLAVOR-LARGE:.//) echo nameserver 10.0.0.1 >> /etc/resolv.conf @@ -39,6 +40,18 @@ bin/dcae-controller.sh deploy-user -l $ZONE -p OPEN-ECOMP -u $OPENSTACK_KEYNAME NETWORKPATH=/openstack/locations/$ZONE/projects/OPEN-ECOMP/networks/$NETWORK KEYPATH=/openstack/locations/$ZONE/projects/OPEN-ECOMP/keypairs/$OPENSTACK_KEYNAME +FLAVORPATH=/openstack/locations/$ZONE/flavors/$FLAVOR + +## wait for flavor but since flavor name may have spaces which 'wait-for' does not support we do this hack +## wait 11 minutes + +i=0 +until [ $i = "66" ]; do + ((i++)) + if [ -e "data/resources/$FLAVORPATH" ]; then break; fi + echo waiting for data/resources/$FLAVORPATH + sleep 10 +done sleep 1m bin/dcae-controller.sh wait-for --timeout 300 --frequency 5 --path $NETWORKPATH --exists --verbose |