Remove swift_repl|storage_address calculation
We have moved the calculation of the swift_repl and storage addresses to the swift role itself, to ensure uniformity: https://review.openstack.org/#/c/375528/ As a result, this PR removes these steps from the playbook as these are now redundant. Change-Id: I65a547603e4b44a4b943b17f6c8969b7c6012922
This commit is contained in:
parent
1186cd7049
commit
b5806d7706
@ -109,7 +109,7 @@
|
||||
- name: os_swift
|
||||
scm: git
|
||||
src: https://git.openstack.org/openstack/openstack-ansible-os_swift
|
||||
version: c6dd7711982551d6bae0a21bf7ab223e31284c6e
|
||||
version: 3840b3807ef6feea30a9768de21c0c943d3171fe
|
||||
- name: os_tempest
|
||||
scm: git
|
||||
src: https://git.openstack.org/openstack/openstack-ansible-os_tempest
|
||||
|
@ -29,94 +29,6 @@
|
||||
group: "syslog"
|
||||
- include: common-tasks/package-cache-proxy.yml
|
||||
|
||||
- name: Set swift storage bridge (is_metal)
|
||||
set_fact:
|
||||
storage_bridge: "{{ 'ansible_' + swift.storage_network | replace('-', '_') }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- swift.storage_network is defined
|
||||
- is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift storage address (is_metal)
|
||||
set_fact:
|
||||
storage_address: "{{ hostvars[inventory_hostname][storage_bridge]['ipv4']['address'] }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- swift.storage_network is defined
|
||||
- is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift storage address (is_metal no storage network)
|
||||
set_fact:
|
||||
storage_address: "{{ ansible_ssh_host }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- swift.storage_network is undefined
|
||||
- is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift storage address (container)
|
||||
set_fact:
|
||||
storage_address: "{{ hostvars[inventory_hostname]['container_networks']['storage_address']['address'] }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- hostvars[inventory_hostname]['container_networks']['storage_address']['address'] is defined
|
||||
- not is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift storage address (container no storage network)
|
||||
set_fact:
|
||||
storage_address: "{{ ansible_ssh_host }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- hostvars[inventory_hostname]['container_networks']['storage_address']['address'] is undefined
|
||||
- not is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift replication bridge (is_metal)
|
||||
set_fact:
|
||||
replication_bridge: "{{ 'ansible_' + swift.replication_network | replace('-', '_') }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- swift.replication_network is defined
|
||||
- is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift replication address (is_metal)
|
||||
set_fact:
|
||||
replication_address: "{{ hostvars[inventory_hostname][replication_bridge]['ipv4']['address'] }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- swift.replication_network is defined
|
||||
- is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift replication address (is_metal no replication network)
|
||||
set_fact:
|
||||
replication_address: "{{ storage_address }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- swift.replication_network is undefined
|
||||
- is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift replication address (container)
|
||||
set_fact:
|
||||
replication_address: "{{ hostvars[inventory_hostname]['container_networks']['replication_address']['address'] }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- hostvars[inventory_hostname]['container_networks']['replication_address']['address'] is defined
|
||||
- not is_metal | bool
|
||||
tags:
|
||||
- always
|
||||
- name: Set swift replication address (container no replication network)
|
||||
set_fact:
|
||||
replication_address: "{{ storage_address }}"
|
||||
when:
|
||||
- inventory_hostname in groups['swift_all']
|
||||
- hostvars[inventory_hostname]['container_networks']['replication_address']['address'] is undefined
|
||||
- not is_metal | bool
|
||||
# If we're using ceilometer then swift needs a rabbitmq/vhost & usera
|
||||
- include: common-tasks/rabbitmq-vhost-user.yml
|
||||
static: no
|
||||
@ -134,8 +46,6 @@
|
||||
- role: "os_swift"
|
||||
swift_venv_tag: "{{ openstack_release }}"
|
||||
swift_venv_download_url: "{{ openstack_repo_url }}/venvs/{{ openstack_release }}/{{ ansible_distribution | lower }}/swift-{{ openstack_release }}-{{ ansible_architecture | lower }}.tgz"
|
||||
swift_storage_address: "{{ storage_address }}"
|
||||
swift_replication_address: "{{ replication_address }}"
|
||||
swift_do_setup: True
|
||||
swift_do_sync: True
|
||||
vars:
|
||||
|
Loading…
Reference in New Issue
Block a user