Skip to content

docs: mark spec.running as deprecated in favor of runStrategy - #1040

Merged
kubevirt-prow[bot] merged 1 commit into
kubevirt:mainfrom
fjvbn2003:docs-running-deprecated
Oct 26, 2026
Merged

kubevirt-prow[bot] merged 1 commit into
kubevirt:mainfrom
fjvbn2003:docs-running-deprecated

Conversation

@fjvbn2003

Copy link
Copy Markdown
Contributor

spec.running has been deprecated since KubeVirt v1.4.0 (kubevirt/kubevirt#12578, listed under "Deprecation" in the v1.4.0 release notes of this guide). The Run Strategies page still introduces Running as the setting that controls the VM and never says that it is deprecated, so a reader who lands there keeps writing running: true.

What the API does today (checked on a v1.9.0 cluster):

  • kubectl explain vm.spec.running prints Deprecated: VirtualMachineInstance field "Running" is now deprecated, please use RunStrategy instead.
  • the virtualmachine-validator.kubevirt.io webhook is registered for CREATE and UPDATE of virtualmachines, and its admitter returns the warning spec.running is deprecated, please use spec.runStrategy instead. whenever spec.running is set (vms-admitter.go).

Changes:

  • docs/compute/run_strategies.md: introduce spec.runStrategy first, then add a warning that spec.running is deprecated, how it maps to Always / Halted, and the warning text the API server returns. Also fixes a typo ("ith").
  • docs/architecture/architecture.md: the example VM was switched to runStrategy: Halted in Change spec.running refs to runStrategy #849, but the text around it still says spec.running. This updates that text, fixes virtctl start vm vm-cirros (virtctl start takes exactly one argument, the VM name: start.go), and shows Run Strategy: Always in the kubectl describe output, because virtctl start on a Halted VM sets runStrategy to Always (lifecycle.go).

#923 and #927 covered the same deprecation together with an unrelated tolerations change and were closed as stale before review. This PR only covers the deprecation.

This change was drafted with AI assistance and reviewed by me.

🤖 Generated with Claude Code

spec.running has been deprecated since KubeVirt v1.4.0
(kubevirt/kubevirt#12578): the API field documentation says so, and the
VirtualMachine validating webhook returns a deprecation warning when a
VM that sets it is created or updated. The Run Strategies page still
introduces `Running` as the field that controls the VM and does not
mention the deprecation.

- run_strategies.md: introduce spec.runStrategy first, add a warning
  that spec.running is deprecated, how it maps to Always/Halted, and
  the warning text the API server returns. Fix a typo ("ith").
- architecture.md: the example VM was switched to `runStrategy: Halted`
  in kubevirt#849, but the text around it still talks about spec.running.
  Update the text, fix `virtctl start vm vm-cirros` (virtctl start takes
  exactly one argument, the VM name), and show `Run Strategy: Always` in
  the describe output after the VM is started.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: YoungjuKim <[email protected]>
@kubevirt-prow kubevirt-prow Bot added dco-signoff: yes Indicates the PR's author has DCO signed all their commits. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Oct 16, 2026
@kubevirt-prow

kubevirt-prow Bot commented Oct 16, 2026

Copy link
Copy Markdown

Hi @fjvbn2003. Thanks for your PR.

I'm waiting for a kubevirt member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@jean-edouard jean-edouard left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/approve

@kubevirt-prow

kubevirt-prow Bot commented Oct 16, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jean-edouard

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubevirt-prow kubevirt-prow Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 16, 2026
@fjvbn2003

Copy link
Copy Markdown
Contributor Author

/cc @aburdenthehand

Hi! This has an /approve from @jean-edouard and only needs an /lgtm to merge. Could you take a look when you have a moment? Thanks!

@aburdenthehand

Copy link
Copy Markdown
Member

/lgtm
Thanks a lot for the corrections @fjvbn2003 and welcome to the project!

@kubevirt-prow kubevirt-prow Bot added the lgtm Indicates that a PR is ready to be merged. label Oct 26, 2026
@kubevirt-prow
kubevirt-prow Bot merged commit a30126d into kubevirt:main Oct 26, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. lgtm Indicates that a PR is ready to be merged. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants