Merge branch 'openstack_inventory_support' into upstream_master

* openstack_inventory_support:
  Use inventory_source source_vars to control what address we use for ansible_ssh_host
  Some small changes to tower openstack work
This commit is contained in:
Matthew Jones
2015-04-23 11:09:41 -04:00
4 changed files with 22 additions and 5 deletions

View File

@@ -938,7 +938,8 @@ class RunInventoryUpdate(BaseTask):
username=credential.username,
password=decrypt_field(credential, "password"),
project_name=credential.project)
openstack_data = {"clouds": {"devstack": {"auth": openstack_auth}}}
private_state = str(inventory_update.source_vars_dict.get("private", "true"))
openstack_data = {"clouds": {"devstack": {"private": private_state, "auth": openstack_auth}}}
return yaml.safe_dump(openstack_data, default_flow_style=False, allow_unicode=True)
cp = ConfigParser.ConfigParser()