Add conditional for overlay network settings
A conditional has been added to the ``_local_ip`` settings used in the ``neutron_local_ip`` which removes the hard requirement for an overlay network to be set within a deployment. If no overlay network is set within the deployment the ``local_ip`` will be set to the value of ``ansible_ssh_host``. Change-Id: I954a46443b5434b589226c4999e71bd6ba6a5c0b Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
This commit is contained in:
parent
8ef3b5db42
commit
b8802f5ce1
@ -170,22 +170,23 @@
|
||||
|
||||
- name: set local_ip fact (is_metal)
|
||||
set_fact:
|
||||
_local_ip: "{{ hostvars[inventory_hostname]['ansible_' + _overlay_network.bridge|replace('-', '_')]['ipv4']['address'] }}"
|
||||
when: is_metal | bool
|
||||
_local_ip: "{{ hostvars[inventory_hostname]['ansible_' + _overlay_network.bridge|default('br-mgmt')|replace('-', '_')]['ipv4']['address']|default(ansible_ssh_host) }}"
|
||||
when:
|
||||
- is_metal | bool
|
||||
tags:
|
||||
- neutron-config
|
||||
|
||||
- name: set local_ip fact (container)
|
||||
set_fact:
|
||||
_local_ip: "{{ _overlay_network.address|default(ansible_ssh_host) }}"
|
||||
when: not is_metal | bool
|
||||
when:
|
||||
- not is_metal | bool
|
||||
tags:
|
||||
- neutron-config
|
||||
roles:
|
||||
- role: "os_neutron"
|
||||
neutron_venv_tag: "{{ openstack_release }}"
|
||||
neutron_venv_download_url: "{{ openstack_repo_url }}/venvs/{{ openstack_release }}/{{ ansible_distribution | lower }}/neutron-{{ openstack_release }}.tgz"
|
||||
neutron_local_ip: "{{ _local_ip }}"
|
||||
neutron_overlay_network: "{{ _overlay_network }}"
|
||||
neutron_provider_networks: "{{ _provider_networks }}"
|
||||
pip_lock_to_internal_repo: "{{ (pip_links | length) >= 1 }}"
|
||||
@ -211,6 +212,7 @@
|
||||
neutron_galera_user: neutron
|
||||
neutron_galera_database: neutron
|
||||
neutron_galera_address: "{{ galera_address }}"
|
||||
neutron_local_ip: "{{ _local_ip|default('127.0.0.1') }}"
|
||||
bind_prefix: "{{ provider_network_bind_prefix|default('') }}"
|
||||
neutron_rabbitmq_userid: neutron
|
||||
neutron_rabbitmq_vhost: /neutron
|
||||
|
@ -0,0 +1,7 @@
|
||||
---
|
||||
features:
|
||||
- A conditional has been added to the ``_local_ip`` settings used in
|
||||
the ``neutron_local_ip`` which removes the hard requirement for an
|
||||
overlay network to be set within a deployment. If no overlay network
|
||||
is set within the deployment the ``local_ip`` will be set to the value
|
||||
of "ansible_ssh_host".
|
Loading…
Reference in New Issue
Block a user