* Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Copyright (C) 2019 Amdocs
-* =============================================================================
+* ================================================================================
+* Copyright (C) 2019 Orange
+* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* See the License for the specific language governing permissions and
* limitations under the License.
*
-* ECOMP is a trademark and service mark of AT&T Intellectual Property.
* ============LICENSE_END=========================================================
*/
'''
output_file.write ("\n[%svip]\n" % Type )
if inventory_type == "None":
output_file.write ("%s\n" % (FloatingIP) )
- elif inventory_type == "VNFC":
+ elif inventory_type == "VNFC" or inventory_type == "VM":
output_file.write ("%s ansible_host=%s\n" % (NE_ID_VIP, FloatingIP) )
- elif inventory_type == "VM":
- output_file.write ("%s ansible_host=%s\n" % (NE_ID_VIP[0:13], FloatingIP) )
output_file.write ("\n[%s]\n" % Type )
Site = NodeList['site']
#print ("vm: " + Name + ": " + IpAddr)
if inventory_type == "None":
output_file.write ("%s\n" % (IpAddr) )
- elif inventory_type == "VNFC":
+ elif inventory_type == "VNFC" or inventory_type == "VM":
output_file.write ("%s ansible_host=%s\n" % (Name, IpAddr) )
- elif inventory_type == "VM":
- output_file.write ("%s ansible_host=%s\n" % (Name[0:13], IpAddr) )
# print site list
output_file.write ("\n[%s:children]\n" % Site )