Merge "Don't compare current state for reboot_*
actions"
This commit is contained in:
commit
3d7948a4e4
@ -553,7 +553,7 @@
|
||||
assert:
|
||||
that:
|
||||
- servers.servers.0.status == 'ACTIVE'
|
||||
- server is not changed
|
||||
- server is changed
|
||||
|
||||
- name: Reboot server (HARD)
|
||||
openstack.cloud.server_action:
|
||||
@ -573,7 +573,7 @@
|
||||
assert:
|
||||
that:
|
||||
- servers.servers.0.status == 'ACTIVE'
|
||||
- server is not changed
|
||||
- server is changed
|
||||
|
||||
- name: Delete server
|
||||
openstack.cloud.server:
|
||||
|
@ -136,6 +136,9 @@ class ServerActionModule(OpenStackModule):
|
||||
# rebuild does not depend on state
|
||||
will_change = (
|
||||
(action == 'rebuild')
|
||||
# `reboot_*` actions do not change state, servers remain `ACTIVE`
|
||||
or (action == 'reboot_hard')
|
||||
or (action == 'reboot_soft')
|
||||
or (action == 'lock' and not server['is_locked'])
|
||||
or (action == 'unlock' and server['is_locked'])
|
||||
or server.status.lower() not in [a.lower()
|
||||
|
Loading…
x
Reference in New Issue
Block a user