Merge "Fix update/upgrade or config change for ODL"
This commit is contained in:
commit
39939708b7
@ -145,6 +145,10 @@ outputs:
|
||||
metadata_settings:
|
||||
get_attr: [OpenDaylightBase, role_data, metadata_settings]
|
||||
host_prep_tasks:
|
||||
- name: Delete cache folder
|
||||
file:
|
||||
path: /var/lib/opendaylight/data/cache
|
||||
state: absent
|
||||
- name: create persistent directories
|
||||
file:
|
||||
path: "{{ item }}"
|
||||
@ -181,8 +185,12 @@ outputs:
|
||||
# Containerized deployment upgrade steps
|
||||
- name: ODL container L2 update and upgrade tasks
|
||||
block: &odl_container_upgrade_tasks
|
||||
- name: remove data, journal and snapshots
|
||||
- name: stop previous ODL container
|
||||
docker_container:
|
||||
name: opendaylight_api
|
||||
state: stopped
|
||||
when: step|int == 0
|
||||
- name: remove data, journal and snapshots
|
||||
file:
|
||||
path: /var/lib/opendaylight/{{item}}
|
||||
state: absent
|
||||
@ -190,6 +198,7 @@ outputs:
|
||||
- snapshots
|
||||
- journal
|
||||
- data
|
||||
when: step|int == 0
|
||||
- name: Set ODL upgrade flag to True
|
||||
copy:
|
||||
dest: /var/lib/config-data/puppet-generated/opendaylight/opt/opendaylight/etc/opendaylight/datastore/initial/config/genius-mdsalutil-config.xml
|
||||
@ -231,6 +240,19 @@ outputs:
|
||||
- name: store update level to update_level variable
|
||||
set_fact:
|
||||
odl_update_level: {get_param: ODLUpdateLevel}
|
||||
- name: Stop ODL container and remove cache
|
||||
block:
|
||||
- name: Stop previous ODL container
|
||||
docker_container:
|
||||
name: opendaylight_api
|
||||
state: stopped
|
||||
- name: Delete cache folder
|
||||
file:
|
||||
path: /var/lib/opendaylight/data/cache
|
||||
state: absent
|
||||
when:
|
||||
- step|int == 0
|
||||
- odl_update_level == 1
|
||||
- name: Run L2 update tasks that are similar to upgrade_tasks when update level is 2
|
||||
block: *odl_container_upgrade_tasks
|
||||
when: odl_update_level == 2
|
||||
|
@ -0,0 +1,6 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
Fixes update and upgrade along with modifying configuration for
|
||||
OpenDaylight deployments. See
|
||||
https://bugs.launchpad.net/tripleo/+bug/1775919
|
Loading…
x
Reference in New Issue
Block a user