]> review.fuel-infra Code Review - tools/sustaining.git/commitdiff
Add wait condition for stack 03/40503/1
authorVladimir Khlyunev <vkhlyunev@mirantis.com>
Wed, 13 Feb 2019 12:05:47 +0000 (16:05 +0400)
committerVladimir Khlyunev <vkhlyunev@mirantis.com>
Wed, 13 Feb 2019 12:05:47 +0000 (16:05 +0400)
Change-Id: Id6b8251cf59d3648374185789032bd8224aa40a3

maintenance-ci/common/data/base_heat.yml

index 380a1858b979bfa8a3c76ff0da0e3363af277202..17872baed02b216ca0a5dd6645430e3627570dfb 100644 (file)
@@ -33,6 +33,16 @@ parameters:
 
 resources:
 
+  wait_condition:
+    type: OS::Heat::WaitCondition
+    properties:
+      handle: {get_resource: wait_handle}
+      count: 1
+      timeout: 300
+
+  wait_handle:
+    type: OS::Heat::WaitConditionHandle
+
   public_port:
     type: OS::Neutron::Port
     properties:
@@ -48,7 +58,7 @@ resources:
       floating_network_id: { get_param: public_net }
       port_id: { get_resource: public_port }
 
-  jenkins-slave:
+  node:
     type: OS::Nova::Server
     properties:
       image: { get_param: image }
@@ -63,9 +73,12 @@ resources:
             mkdir -p /etc/jenkins-agent/
             echo "$FLAVOR $LABELS" > /etc/jenkins-agent/labels
             echo "127.0.0.1 $(hostname)" >> /etc/hosts
+            wc_notify --data-binary '{"status": "SUCCESS"}'
           params:
            $FLAVOR: {get_param: flavor}
            $LABELS: {get_param: jenkins_labels}
+           wc_notify: { get_attr: [wait_handle, curl_cli] }
+
 
 outputs:
   floating_ip: