Correct erroneous upgrade tasks.

After merging [0], the step for each upgrade_task
is now handled in a 'when' condition. This patch
corrects some templates which where not following
that logic or had some syntax error.

[0] https://review.openstack.org/#/c/510902/

Change-Id: I5e42fa6b3d84ad6e0163900ee8146fd224fb5103
This commit is contained in:
Jose Luis Franco Arza 2018-01-17 11:14:48 +01:00
parent 5147c8fda2
commit cc0c466044
5 changed files with 10 additions and 11 deletions

View File

@ -57,7 +57,8 @@ outputs:
service_name: ceph_osd
upgrade_tasks:
- name: Check legacy Ceph hieradata
tags: step0,validation
tags: validation
when: step|int == 0
shell: test "nil" == "$(hiera -c /etc/puppet/hiera.yaml ceph::profile::params::osds)"
puppet_config:
config_image: ''

View File

@ -171,7 +171,7 @@ outputs:
/var/log/containers/ironic-inspector.
ignore_errors: true
upgrade_tasks:
- when: step|int ==2
- when: step|int == 2
block:
- name: Stop and disable ironic_inspector service
service: name=openstack-ironic-inspector state=stopped enabled=no

View File

@ -146,9 +146,8 @@ outputs:
register: networking_ovn_metadata_agent_enabled
- name: "PreUpgrade step0,validation: Check service networking-ovn-metadata-agent is running"
command: systemctl is-active --quiet networking-ovn-metadata-agent
when: networking_ovn_metadata_agent_enabled.rc == 0
tags: step0,validation
when: (networking_ovn_metadata_agent_enabled.rc == 0) and (step|int == 0)
tags: validation
- name: Stop and disable networking_ovn_metadata service
tags: step2
when: networking_ovn_metadata_agent_enabled.rc == 0
when: (networking_ovn_metadata_agent_enabled.rc == 0) and (step|int == 2)
service: name=networking-ovn-metadata-agent state=stopped enabled=no

View File

@ -45,5 +45,5 @@ outputs:
include ::tripleo::profile::base::docker_registry
upgrade_tasks:
- name: Install docker packages on upgrade if missing
tags: step3
when: step|int == 3
yum: name=docker-distribution state=latest

View File

@ -115,9 +115,8 @@ outputs:
register: networking_ovn_metadata_agent_enabled
- name: "PreUpgrade step0,validation: Check service networking-ovn-metadata-agent is running"
shell: /usr/bin/systemctl show 'networking-ovn-metadata-agent' --property ActiveState | grep '\bactive\b'
when: networking_ovn_metadata_agent_enabled.rc == 0
tags: step0,validation
when: (networking_ovn_metadata_agent_enabled.rc == 0) and (step|int == 0)
tags: validation
- name: Stop networking_ovn_metadata service
tags: step1
when: neutron_metadata_agent_enabled.rc == 0
when: (neutron_metadata_agent_enabled.rc == 0) and (step|int == 1)
service: name=networking-ovn-metadata-agent state=stopped