diff --git a/awx/main/tasks.py b/awx/main/tasks.py index f1d28938f5..06a5288d6e 100644 --- a/awx/main/tasks.py +++ b/awx/main/tasks.py @@ -1361,9 +1361,9 @@ class RunInventoryUpdate(BaseTask): vmware_opts = dict(inventory_update.source_vars_dict.items()) 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: - 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(): cp.set(section, k, unicode(v)) diff --git a/awx/settings/defaults.py b/awx/settings/defaults.py index 35911f4c71..b283387350 100644 --- a/awx/settings/defaults.py +++ b/awx/settings/defaults.py @@ -663,8 +663,8 @@ VMWARE_REGIONS_BLACKLIST = [] # Inventory variable name/values for determining whether a host is # active in vSphere. -VMWARE_ENABLED_VAR = 'vmware_powerState' -VMWARE_ENABLED_VALUE = 'poweredOn' +VMWARE_ENABLED_VAR = 'guest.gueststate' +VMWARE_ENABLED_VALUE = 'running' # Inventory variable name containing the unique instance ID. VMWARE_INSTANCE_ID_VAR = 'vmware_uuid'