(context, resource_list)
return outputs
Returns list of outputs generated by this module.
Returns list of outputs generated by this module.
Returns list of outputs generated by this module .
def GenerateOutputList(context, resource_list):
  """Returns list of outputs generated by this module."""
  vm_res = resource_list[0]
  outputs = [{
      'name': 'internalIP',
      'value': '$(ref.%s.networkInterfaces[0].networkIP)' % vm_res['name'],
  }]
  has_external_ip = context.properties.get(HAS_EXTERNAL_IP,
                                           DEFAULT_HAS_EXTERNAL_IP)
  if has_external_ip:
    outputs.append({
        'name': 'ip',
        'value': ('$(ref.%s.networkInterfaces[0].accessConfigs[0].natIP)' %
                  vm_res['name']),
    })
  return outputs
def GenerateOutputList ( context , resource_list ) : vm_res = resource_list [ 0 ] outputs = [ { 'name' : 'internalIP' , 'value' : '$(ref.%s.networkInterfaces[0].networkIP)' % vm_res [ 'name' ] , } ] has_external_ip = context . properties . get ( HAS_EXTERNAL_IP , DEFAULT_HAS_EXTERNAL_IP ) if has_external_ip : outputs . append ( { 'name' : 'ip' , 'value' : ( '$(ref.%s.networkInterfaces[0].accessConfigs[0].natIP)' % vm_res [ 'name' ] ) , } ) return outputs