Merge "Unmount NFS shares before launching LEAPP" into stable/train

This commit is contained in:
Zuul 2020-07-13 04:39:50 +00:00 committed by Gerrit Code Review
commit f1ddec305c
1 changed files with 19 additions and 3 deletions

View File

@ -51,6 +51,11 @@ parameters:
echo "and passed the upstream name (rocky, stein, train) of the release as first argument" echo "and passed the upstream name (rocky, stein, train) of the release as first argument"
exit 1 exit 1
type: string type: string
GlanceNodeStagingUri:
default: 'file:///var/lib/glance/staging'
description: >
URI that specifies the staging location to use when importing images
type: string
UpgradeLeappEnabled: UpgradeLeappEnabled:
description: Use Leapp for operating system upgrade description: Use Leapp for operating system upgrade
type: boolean type: boolean
@ -270,19 +275,30 @@ outputs:
- never - never
- system_upgrade - system_upgrade
- system_upgrade_prepare - system_upgrade_prepare
when: step|int == 4 when:
- step|int == 4
- upgrade_leapp_enabled
block: block:
- name: unmount and remove nfs glance entry
mount: path=/var/lib/glance/images state=absent
ignore_errors: true
- name: unmount and remove nfs glance staging entry
vars:
glance_node_staging_uri: {get_param: GlanceNodeStagingUri}
mount: path="{{glance_node_staging_uri[7:]}}" state=absent
ignore_errors: true
- name: unmount and remove nfs nova entry
mount: path=/var/lib/nova/instances state=absent
ignore_errors: true
- name: set leapp options - name: set leapp options
shell: > shell: >
leapp answer --section remove_pam_pkcs11_module_check.confirm=True --add leapp answer --section remove_pam_pkcs11_module_check.confirm=True --add
when: upgrade_leapp_enabled
- name: run leapp upgrade (download packages) - name: run leapp upgrade (download packages)
shell: > shell: >
{% if upgrade_leapp_devel_skip|default(false) %}{{ upgrade_leapp_devel_skip }}{% endif %} {% if upgrade_leapp_devel_skip|default(false) %}{{ upgrade_leapp_devel_skip }}{% endif %}
leapp upgrade leapp upgrade
{% if upgrade_leapp_debug|default(true) %}--debug{% endif %} {% if upgrade_leapp_debug|default(true) %}--debug{% endif %}
{% if upgrade_leapp_command_options|default(false) %}{{ upgrade_leapp_command_options }}{% endif %} {% if upgrade_leapp_command_options|default(false) %}{{ upgrade_leapp_command_options }}{% endif %}
when: upgrade_leapp_enabled
- name: system_upgrade_run step 4 - name: system_upgrade_run step 4
tags: tags: