Use outputs section for getting ip addresses
Instead of direct call in test we may also test attributes and show good
example of how to use get_attr functions.
Change-Id: I4c2e78fe6c1fc8808f0180592b60c091613a3af9
diff --git a/scenario/templates/test_neutron_loadbalancer.yaml b/scenario/templates/test_neutron_loadbalancer.yaml
index fad7db8..a7e9f9c 100644
--- a/scenario/templates/test_neutron_loadbalancer.yaml
+++ b/scenario/templates/test_neutron_loadbalancer.yaml
@@ -32,7 +32,7 @@
- remote_ip_prefix: 0.0.0.0/0
protocol: icmp
- server1 :
+ server1:
type: OS::Nova::Server
properties:
name: Server1
@@ -52,7 +52,7 @@
- 'python -m SimpleHTTPServer '
- { get_param: port }
- server2 :
+ server2:
type: OS::Nova::Server
properties:
name: Server2
@@ -106,3 +106,12 @@
members:
- { get_resource: server1 }
+outputs:
+ serv1_ip:
+ value: {get_attr: [server1, networks, private, 0]}
+ serv2_ip:
+ value: {get_attr: [server2, networks, private, 0]}
+ vip:
+ value: {get_attr: [test_pool, vip, address]}
+ fip:
+ value: {get_attr: [floating_ip, floating_ip_address]}