This did not work for me at all.
I have a heat template that I can stack and the output attributes populate appropriately referencing OS::Neutron::Ports and OS::Nova::Server attributes after they are created. Here is a partial list of outputs from the template I want to nest:
heat output-show --all ve_ha_test_3_nic
[
{
"output_value": "ve_ha_test_3_nic-ve_instance-opfcdup6vonr",
"description": "Name of the instance",
"output_key": "ve_instance_name"
},
{
"output_value": "da494d97-a9c9-4470-8f6c-e89b749403b9",
"description": "The mgmt port id of f5 VE instance",
"output_key": "mgmt_port"
},
{
"output_value": "172.13.1.188",
"description": "The mgmt IP address of f5 ve instance",
"output_key": "mgmt_ip"
},
.....
]
So you can see I get values for output keys:
ve_instance_name
mgmt_port
mgmt_ip
When I try to launch the same template as a nested template and try to access the way you suggested
heat_template_version: 2014-10-16
resources:
f5_ve_instance_1:
type: https://.../ve_cluster_member_3_nic.yaml
properties:
ve_image: 6f4ae76b-7a9d-4417-9fdb-397af130067f
ve_flavor: 9d416522-7eaa-420a-abc7-17b2c578d5af
use_config_drive: True
ssh_key: stack_key
admin_password: openstack
root_password: openstack
http_proxy_host: None
http_proxy_port: 8080
http_proxy_script_url: https://.../license_http_proxy
license_activation_host: None
license_activation_port: 443
mgmt_network: 1c20a693-3fdc-4fc7-b9ea-19dbcd6c6e6b
ha_network: 5cec0196-00e2-4347-b510-045225f6e720
default_gateway: None
network_1: 9bbfc10f-8374-4d83-b360-eee96ca89eac
network_1_name: TRUSTED
license: 12345678890
outputs:
f5_ve_instance_name_1:
value: { get_attr: f5_ve_instance_1, ve_instance_name }
f5_ve_mgmt_ip_1:
value: { get_attr: f5_ve_instance_1, mgmt_ip }
f5_ve_mgmt_port_1:
value: { get_attr: f5_ve_instance_1, mgmt_port }
What I get when I query the top level template for the outputs defined which point to referenced output of the nested template, I don't get values I get 'null' for everything.
heat output-show --all f5_ve_ha_1_0_1
[
{
"output_value": {
"get_attr": "f5_ve_instance_1",
"ve_instance_name": null
},
"description": "No description given",
"output_key": "f5_ve_instance_name_1"
},
{
"output_value": {
"get_attr": "f5_ve_instance_1",
"mgmt_ip": null
},
"description": "No description given",
"output_key": "f5_ve_mgmt_ip_1"
},
{
"output_value": {
"get_attr": "f5_ve_instance_1",
"mgmt_port": null
},
"description": "No description given",
"output_key": "f5_ve_mgmt_port_1"
}
]
Maybe the top level template is looking for those attributes before the nested template can populate them? How do I specify that my template 'wait' for a value?
John