Map instances to cell_v2 only once.
If nova-manage cell_v2 create_cell returns 2, it's because the cell already exists and all instances are correctly mapped to the cell. The cell_v2 map_instances doesn't need to run. Change-Id: I38002a18dff4dbd44bd3df9e1969c9d50ab12705 Related-Bug: 1729661
This commit is contained in:
parent
783ec21ca7
commit
0f24bb8bd4
@ -141,9 +141,11 @@
|
|||||||
become_user: "{{ nova_system_user_name }}"
|
become_user: "{{ nova_system_user_name }}"
|
||||||
register: cell1_uuid
|
register: cell1_uuid
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
when: "nova_cell1_create.rc == 0"
|
||||||
|
|
||||||
- name: Map instances to new Cell1
|
- name: Map instances to new Cell1
|
||||||
command: "{{ nova_bin }}/nova-manage cell_v2 map_instances --cell_uuid {{ cell1_uuid['stdout'].split()[3] }}"
|
command: "{{ nova_bin }}/nova-manage cell_v2 map_instances --cell_uuid {{ cell1_uuid['stdout'].split()[3] }}"
|
||||||
become: yes
|
become: yes
|
||||||
become_user: "{{ nova_system_user_name }}"
|
become_user: "{{ nova_system_user_name }}"
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
when: "nova_cell1_create.rc == 0"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user