-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hpilo_boot: fix module failing when trying to power on an already powered-on server #9646
base: main
Are you sure you want to change the base?
Conversation
…ady powered-on server For this module to be idempotent, it should be successful when trying to reach a power state which is already there. It was already the case for "poweroff", however when running the module with "boot_once" state, it was failing if the server was already powered_on, which is not an idempotent behavior
The test
The test
The test
The test
|
pass | ||
elif power_status == 'ON': |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ryanb74 Thanks for your contribution!
Please beware this is a breaking change - people might have code out there that expects it to fail. We need to take the long route on this one - add the new behaviour with a feature flag, deprecate the "old" behaviour, and later on remove the "old" behaviour entirely (along with the feature flag).
@ryanb74 ping needs_info |
SUMMARY
For this module to be idempotent, it should be successful when trying to reach a power state which is already there.
It was already the case for "poweroff", however when running the module with "boot_once" state, it was failing if the server was already powered_on, which is not an idempotent behavior
ISSUE TYPE
COMPONENT NAME
hpilo_boot.py
ADDITIONAL INFORMATION
Before change, when running the module with state = "boot_once", the module fails :
After change, when running the module with state = "boot_once", the module is successful and doesn't change anything :