Add --skip-ipa-cleanup to overcloud delete
The IPA cleanup bits may fail if the stack is in a bad state or IPA wasn't used. We need to add the flag to allow a user to skip this action. Change-Id: Idf77ea052c783cfdbd74c8b6e4b3064c4b94b968
This commit is contained in:
parent
7977e21a2a
commit
e510b61b0b
|
@ -22,6 +22,7 @@ Role Variables
|
|||
* `tripleo_overcloud_delete_os_cloud`: (String) (String) OS_CLOUD value to use when running the command. If `tripleo_os_cloud` is defined, it will be the default. Otherwise the default is ''. This variable takes precedence over `tripleo_overcloud_delete_rc_file`.
|
||||
* `tripleo_overcloud_delete_poll`: (Integer) Number of seconds to wait between each checks to see if the command has completed. Default: 10
|
||||
* `tripleo_overcloud_delete_rc_file`: (String) (String) Path to the credential file to use. If `tripleo_rc_file` is defined, it will be the default. Default: "{{ ansible_env.HOME }}/stackrc"
|
||||
* `tripleo_overcloud_delete_skip_ipa_cleanup`: (Boolean) Skip IPA cleanup actions during overcloud removal. Default: false
|
||||
* `tripleo_overcloud_delete_timeout`: (Integer) Number in seconds to wait for the ansible execution of the command to finish. Default: 3600
|
||||
* `tripleo_overcloud_delete_yes`: (Boolean) Flag to indicate if we should prompt for yes/no. Default: false
|
||||
|
||||
|
|
|
@ -12,5 +12,6 @@ tripleo_overcloud_delete_name:
|
|||
tripleo_overcloud_delete_os_cloud: "{{ tripleo_os_cloud | default('') }}"
|
||||
tripleo_overcloud_delete_poll: 10
|
||||
tripleo_overcloud_delete_rc_file: "{{ tripleo_rc_file | default(ansible_env.HOME ~ '/stackrc') }}"
|
||||
tripleo_overcloud_delete_skip_ipa_cleanup: false
|
||||
tripleo_overcloud_delete_timeout: 3600
|
||||
tripleo_overcloud_delete_yes: true
|
||||
|
|
|
@ -42,3 +42,14 @@
|
|||
assert:
|
||||
that:
|
||||
- tripleo_overcloud_delete_output == "overcloud delete --yes"
|
||||
|
||||
- name: Validate "tripleo_overcloud_delete_skip_ipa_cleanup"
|
||||
include_role:
|
||||
name: "tripleo_overcloud_delete"
|
||||
vars:
|
||||
tripleo_overcloud_delete_skip_ipa_cleanup: true
|
||||
|
||||
- name: Assert tripleo_overcloud_delete_skip_ipa_cleanup
|
||||
assert:
|
||||
that:
|
||||
- tripleo_overcloud_delete_output == "overcloud delete --skip-ipa-cleanup"
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
{{ tripleo_overcloud_delete_os_cloud | ternary('', "source " ~ tripleo_overcloud_delete_rc_file ~ "; ") }}
|
||||
{{ openstack_bin }} overcloud delete
|
||||
{{ tripleo_overcloud_delete_yes | ternary('--yes', '') }}
|
||||
{{ tripleo_overcloud_delete_skip_ipa_cleanup | ternary('--skip-ipa-cleanup', '') }}
|
||||
{{ tripleo_overcloud_delete_name }}
|
||||
{{ tripleo_overcloud_delete_log_output | ternary((">" ~ tripleo_overcloud_delete_log), '') }}
|
||||
{{ tripleo_overcloud_delete_log_combine | ternary("2>&1", '') }}
|
||||
|
|
Loading…
Reference in New Issue