Skip to content
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

feat(vm): always replace Pod on VM restart #3

Merged
merged 1 commit into from
Feb 20, 2024

Conversation

diafour
Copy link
Member

@diafour diafour commented Feb 5, 2024

Description

Make VM's Pod a one-shot Pod. Use runPolicy Manual and restart Pod via KVVMI deletion.

Why do we need it, and what problem does it solve?

Executing sudo reboot inside the VM should be equal to executing virtctl restart/deleting KVVMI in controller.

What is the expected result?

VM after sudo restart should be created with new settings.

  1. Use disruption mode Manual
  2. patch VM
  3. enter VM console, run reboot
  4. check that rebootId is absent, and the recreated VM has new settings.

Checklist

  • The code is covered by unit tests.
  • e2e tests passed.
  • Documentation updated according to the changes.
  • Changes were tested in the Kubernetes cluster manually.

@diafour diafour force-pushed the feat/always_replace_pod_on_restart branch from 7af88dd to 0cd544a Compare February 6, 2024 10:41
@diafour diafour marked this pull request as draft February 7, 2024 11:14
@diafour diafour force-pushed the feat/always_replace_pod_on_restart branch 3 times, most recently from dded084 to f41df76 Compare February 13, 2024 14:53
- Use QMP to set action and monitor events
- Add monitor daemon to catch reset/shutdown reason
- Retrieve reset/shutdown from termination log
- Add watcher for VM's Pods
- Refactor: move power state methods to own package

Signed-off-by: Ivan Mikheykin <[email protected]>
@diafour diafour force-pushed the feat/always_replace_pod_on_restart branch from d639a28 to 717260e Compare February 13, 2024 19:04
@diafour diafour marked this pull request as ready for review February 13, 2024 19:05
@diafour diafour merged commit eeea94a into main Feb 20, 2024
5 checks passed
@diafour diafour deleted the feat/always_replace_pod_on_restart branch May 28, 2024 10:25
fl64 added a commit that referenced this pull request Jul 31, 2024
Signed-off-by: Pavel Tishkov <[email protected]>
fl64 added a commit that referenced this pull request Aug 14, 2024
fl64 added a commit that referenced this pull request Aug 14, 2024
Signed-off-by: Pavel Tishkov <[email protected]>
fl64 added a commit that referenced this pull request Aug 14, 2024
Signed-off-by: Pavel Tishkov <[email protected]>
diafour added a commit that referenced this pull request Sep 23, 2024
Signed-off-by: Ivan Mikheykin <[email protected]>
diafour added a commit that referenced this pull request Sep 24, 2024
Signed-off-by: Ivan Mikheykin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants