canonical / canonical/cloud-init
cc_power_state_change should support kexec
- Dominant language
- Python
- Stars
- 3.8k
- Forks
- 1.1k
- Avg merge
- 3d 8h
- Merged PRs (30d)
- 22
Description
This bug was originally filed in Launchpad as [LP: #1964998](https://bugs.launchpad.net/cloud-init/+bug/1964998)
Launchpad details
affected_projects = []
assignee = None
assignee_name = None
date_closed = 2022-03-15T18:55:01.252063+00:00
date_created = 2022-03-15T18:42:50.251110+00:00
date_fix_committed = None
date_fix_released = None
id = 1964998
importance = medium
is_complete = True
lp_url = https://bugs.launchpad.net/cloud-init/+bug/1964998
milestone = None
owner = bgermain1689
owner_name = Brendan Germain
private = False
status = opinion
submitter = bgermain1689
submitter_name = Brendan Germain
tags = ['bitesize']
duplicates = []
_Launchpad user **Brendan Germain(bgermain1689)** wrote on 2022-03-15T18:42:50.251110+00:00_
cc_power_state_change currently supports poweroff, halt, or reboot.
A way to call systemctl kexec or change the power cmd manually via an exposed attribute would be greatly beneficial.
The only workaround Im aware of today is calling systemctl kexec as your final runcmd but this doesn't allow cloud-init to cleanly finish/exit.
Contributor guide
Research direction
Start at the cc_power_state_change implementation and trace how the existing poweroff, halt, and reboot options finish cloud-init. Check how the requested systemctl kexec action would fit the power command handling, then verify that cloud-init can cleanly finish before kexec is invoked. Done means kexec is supported without requiring a final runcmd workaround.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- operating-systems
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100