Control Neutron migrations

Since [1] and [2] merged, K-A has to control Neutron migrations
to migrate all required projects.

This patch additionally fixes the other observed issue.

[1] https://review.opendev.org/750075
[2] https://review.opendev.org/753543

Change-Id: I09e1b421e9066890b50bd82331a3050de252464f
Closes-Bug: #1894380
Depends-On: https://review.opendev.org/755346
This commit is contained in:
Radosław Piliszek 2020-09-30 17:37:57 +02:00
parent 29b2d4284a
commit 8d2d37064e
4 changed files with 25 additions and 32 deletions

View File

@ -383,6 +383,17 @@ neutron_l3_agent_host_ipv6_neigh_gc_thresh1: "{{ neutron_l3_agent_host_ipv4_neig
neutron_l3_agent_host_ipv6_neigh_gc_thresh2: "{{ neutron_l3_agent_host_ipv4_neigh_gc_thresh2 }}"
neutron_l3_agent_host_ipv6_neigh_gc_thresh3: "{{ neutron_l3_agent_host_ipv4_neigh_gc_thresh3 }}"
####################
# Subprojects
####################
neutron_subprojects:
- name: "networking-sfc"
enabled: "{{ enable_neutron_sfc | bool }}"
- name: "neutron-dynamic-routing"
enabled: "{{ enable_neutron_bgp_dragent | bool }}"
- name: "neutron-vpnaas"
enabled: "{{ enable_neutron_vpnaas | bool }}"
####################
# Mechanism drivers
####################
@ -419,11 +430,16 @@ extension_drivers:
neutron_extension_drivers: "{{ extension_drivers | selectattr('enabled', 'equalto', true) | list }}"
####################
# Neutron bootstrap
####################
neutron_bootstrap_services: "{{ neutron_subprojects | selectattr('enabled') | map(attribute='name') | list }}"
####################
# Neutron upgrade
####################
neutron_enable_rolling_upgrade: "yes"
neutron_rolling_upgrade_services: ["neutron", "neutron-vpnaas"]
neutron_rolling_upgrade_services: "{{ neutron_subprojects | selectattr('enabled') | map(attribute='name') | list }}"
####################
# Service Plugins

View File

@ -10,6 +10,7 @@
environment:
KOLLA_BOOTSTRAP:
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
NEUTRON_BOOTSTRAP_SERVICES: "{{ neutron_bootstrap_services | join(' ') }}"
image: "{{ neutron_server.image }}"
labels:
BOOTSTRAP:
@ -18,29 +19,3 @@
volumes: "{{ neutron_server.volumes }}"
run_once: True
delegate_to: "{{ groups[neutron_server.group][0] }}"
when: (kolla_action == "deploy")
or (not neutron_enable_rolling_upgrade | bool)
- name: Running Neutron sfc bootstrap container
vars:
neutron_server: "{{ neutron_services['neutron-server'] }}"
become: true
kolla_docker:
action: "start_container"
common_options: "{{ docker_common_options }}"
detach: False
environment:
NEUTRON_SFC_BOOTSTRAP:
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
image: "{{ neutron_server.image }}"
labels:
BOOTSTRAP:
name: "bootstrap_neutron_sfc"
restart_policy: no
volumes: "{{ neutron_server.volumes }}"
when:
- enable_neutron_sfc | bool
- neutron_server.enabled | bool
- neutron_server.host_in_groups | bool
run_once: True
delegate_to: "{{ groups[neutron_server.group][0] }}"

View File

@ -30,11 +30,6 @@
run_once: True
delegate_to: "{{ groups['neutron-server'][0] }}"
- include_tasks: bootstrap_service.yml
vars:
neutron_server: "{{ neutron_services['neutron-server'] }}"
when: (enable_neutron_sfc | bool and neutron_server.enabled | bool)
- name: Flush Handlers
meta: flush_handlers

View File

@ -0,0 +1,7 @@
---
fixes:
- |
Fixes some Neutron subprojects not using the rolling upgrade scheme.
SFC forcibly used the legacy scheme and dynamic routing was not migrated
at all.
`LP#1894380 <https://launchpad.net/bugs/1894380>`__