Skip to content

VEP 285: Preset launch security defaults via preference#286

Open
jschintag wants to merge 1 commit intokubevirt:mainfrom
jschintag:se-preference
Open

VEP 285: Preset launch security defaults via preference#286
jschintag wants to merge 1 commit intokubevirt:mainfrom
jschintag:se-preference

Conversation

@jschintag
Copy link
Copy Markdown
Contributor

This VEP proposes to enable easier management of confidential computing VMs by using common preferences.

VEP Metadata

Tracking issue: #285
SIG label: /sig api

What this PR does

Propose adding launchSecurity field to VirtualMachinePreference for configuring VMs.

Special notes for your reviewer

@kubevirt-bot kubevirt-bot added the dco-signoff: yes Indicates the PR's author has DCO signed all their commits. label Apr 21, 2026
@kubevirt-bot kubevirt-bot requested a review from lyarwood April 21, 2026 11:01
@kubevirt-bot kubevirt-bot requested review from vladikr and xpivarc April 21, 2026 11:01
@kubevirt-bot
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign vladikr for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

@xpivarc
Copy link
Copy Markdown
Member

xpivarc commented Apr 21, 2026

/cc @lyarwood @0xFelix

@kubevirt-bot kubevirt-bot requested a review from 0xFelix April 21, 2026 12:05
Copy link
Copy Markdown
Member

@0xFelix 0xFelix left a comment

Choose a reason for hiding this comment

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

At least we've got a conflict with #17.

- [ ] Unit tests are implemented and passing

### Beta
- [ ] Common preference types are added to common-templates for IBM Secure Execution
Copy link
Copy Markdown
Member

@0xFelix 0xFelix Apr 21, 2026

Choose a reason for hiding this comment

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

You mean common-instancetypes.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Good catch


The following table summarizes the outcomes:

| VMI | Preference | Outcome |
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

How does it go together with instancetypes?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

As far as i understand instancetypes override settings in the VMI, so it would override it here as well.
Let me add that here as well.


## Overview

Add the `launchSecurity` parameter to `VirtualMachineClusterPreference` and
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

IIRC the intention for providing launcheSecurity with instance types is that nodes need to have the necessary hardware i.e. the resources to support the chosen setting. It's not simply a runtime preference of the guest.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The hardware support for nodes is determined via nodeselectors (at least for AMD SEV and IBM Secure Execution, no idea about Interl/Arm).
The idea here is not related to the Hardware in the cluster, but rather to specific VM images.
For example IBM Secure Execution requires specific changes to the VM image, which would mean that image can only run in SE mode. If that is then used as a golden image in the cluster, linking it to a preference which means launchSecurity would be enabled automatically. No need for users to choose an instancetype with launchSecurity or enable it manually.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The more I think about this the more I think we need to deprecate LaunchSecurity out of the instance type spec entirely and just provide it through preferences.

@0xFelix this will bork the v1 VEP for a cycle, would you be against this?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

It's hard to draw a line on deciding what belongs into an instancetype or a preference. But I agree that we should move launchSecurity to preferences.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

okay, @jschintag can you deprecate the instance type field as part of this work in v1beta1?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Sure @lyarwood. I have added the removal to the beta target and added a deprecation notice to the alpha target.

@jschintag
Copy link
Copy Markdown
Contributor Author

Thank you for the quick review @0xFelix.

I have updated the table to include instancetypes and fixed the mention of common-templates.

// Optionally defines the preferred LaunchSecurity
//
// +optional
LaunchSecurity *v1.LaunchSecurity `json:"launchSecurity,omitempty"`
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm not a fan of it but everything is prefixed with preferred, I've wanted to drop it forever but the backwards compat required would be a nightmare.

@0xFelix if we do delay v1 maybe yet another thing to throw in the backlog?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@lyarwood Do you want this to keep using the preferred prefix? But I agree we could drop it in the future (even this cycle already?).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm pretty overloaded this cycle but I can write it up as a backlog VEP and we can try to address it either this cycle or next.

Comment thread veps/sig-compute/285-launchsecurity-preference/launchsecurity-preference.md Outdated

## Overview

Add the `launchSecurity` parameter to `VirtualMachineClusterPreference` and
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The more I think about this the more I think we need to deprecate LaunchSecurity out of the instance type spec entirely and just provide it through preferences.

@0xFelix this will bork the v1 VEP for a cycle, would you be against this?

@0xFelix
Copy link
Copy Markdown
Member

0xFelix commented Apr 22, 2026

@0xFelix this will bork the v1 VEP for a cycle, would you be against this?

I am fine with that, let's refine the instanctype API first and not rush v1 in this cycle.

This VEP proposes to enable easier management of confidential computing
VMs by using common preferences.

Signed-off-by: Jan Schintag <jan.schintag@de.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dco-signoff: yes Indicates the PR's author has DCO signed all their commits. sig/compute size/L

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants