Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

CircularDependencyException - Accessing a property within the resource

Hi all -

I wanted to access a property within the same resource.

extServer:
    type: OS::Nova::Server
    properties:
        image: { get_param: image }
        flavor: { get_param: flavor }
        name:  { get_param: [ vmNames, get_param: index ] }
        networks:         
            repeat:
                for_each:
                    <%port%>: { get_param: allnetworks }
                template:
                    network: <%port%>

      user_data_format: RAW
        user_data_update_policy: IGNORE
        user_data:
            str_replace:
                params:
                    $IPADDRESSES: { get_attr: [extServer, networks] }

I wanted to retrieve the IP address assigned to each network and I am trying to get it via get_attr like above. This throws the circular dependency error.

I know it is possible to get it from the outputs section. But, is there any way to get the networks assigned from within the same resource?

please help

Thank You, Subeesh

CircularDependencyException - Accessing a property within the resource

Hi all -

I wanted to access a property within the same resource.

extServer:
    type: OS::Nova::Server
    properties:
        image: { get_param: image }
        flavor: { get_param: flavor }
        name:  { get_param: [ vmNames, get_param: index ] }
        networks:         
            repeat:
                for_each:
                    <%port%>: { get_param: allnetworks }
                template:
                    network: <%port%>

      user_data_format: RAW
        user_data_update_policy: IGNORE
        user_data:
            str_replace:
                params:
                    $IPADDRESSES: { get_attr: [extServer, networks] }

I wanted to retrieve the IP address assigned to each network and I am trying to get it via get_attr like above. This throws the circular dependency error.

I know it is possible to get it from the outputs section. But, is there any way to get the networks assigned from within the same resource?resource? Will "addresses" property help within the resource/server ? Or I can only access it from outside that resource?

please help

Thank You, Subeesh