1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-01 08:21:15 +03:00

code logic fix and vmware active var updated

This commit is contained in:
Chris Meyers 2016-12-19 17:08:27 -05:00
parent 139d80bcbb
commit 2f9a5409c3
2 changed files with 4 additions and 4 deletions

View File

@ -1361,9 +1361,9 @@ class RunInventoryUpdate(BaseTask):
vmware_opts = dict(inventory_update.source_vars_dict.items()) vmware_opts = dict(inventory_update.source_vars_dict.items())
if inventory_update.instance_filters: if inventory_update.instance_filters:
inventory_update.setdefault('host_filters', inventory_update.instance_filters) vmware_opts.setdefault('host_filters', inventory_update.instance_filters)
if inventory_update.group_by: if inventory_update.group_by:
inventory_update.setdefault('groupby_patterns', inventory_update.groupby_patterns) vmware_opts.setdefault('groupby_patterns', inventory_update.groupby_patterns)
for k,v in vmware_opts.items(): for k,v in vmware_opts.items():
cp.set(section, k, unicode(v)) cp.set(section, k, unicode(v))

View File

@ -663,8 +663,8 @@ VMWARE_REGIONS_BLACKLIST = []
# Inventory variable name/values for determining whether a host is # Inventory variable name/values for determining whether a host is
# active in vSphere. # active in vSphere.
VMWARE_ENABLED_VAR = 'vmware_powerState' VMWARE_ENABLED_VAR = 'guest.gueststate'
VMWARE_ENABLED_VALUE = 'poweredOn' VMWARE_ENABLED_VALUE = 'running'
# Inventory variable name containing the unique instance ID. # Inventory variable name containing the unique instance ID.
VMWARE_INSTANCE_ID_VAR = 'vmware_uuid' VMWARE_INSTANCE_ID_VAR = 'vmware_uuid'