Ask Your Question

Revision history [back]

I think you're thinking that get_resource returns the resource itself, from which you can then get attributes. This is not correct: get_resource returns the UUID of the port. That's why db_ports gives the output it does.

You've actually already defined an output for the IP address, so in the parent template you just have to use it:

db_ips:
  description: IP addreses of DB server instances
  value: {get_attr: [dbport_cluster, dbportip]}