Skip to content

Commit fc89b1b

Browse files
committed
kernel variant
1 parent 4360008 commit fc89b1b

1 file changed

Lines changed: 24 additions & 1 deletion

File tree

protect/control/v1/control.proto

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ service ControlService {
2323
rpc ImportImage(stream ImportImageRequest) returns (stream ImportImageReply);
2424
rpc RemoveImage(RemoveImageRequest) returns (RemoveImageReply);
2525
rpc ListImages(ListImagesRequest) returns (stream ListImagesReply);
26+
rpc ListKernelVariants(ListKernelVariantsRequest) returns (ListKernelVariantsReply);
2627

2728
rpc CreateZone(CreateZoneRequest) returns (CreateZoneReply);
2829
rpc DestroyZone(DestroyZoneRequest) returns (DestroyZoneReply);
@@ -641,7 +642,13 @@ message SnoopControlPacket {
641642
// for moving tags) instead of resolving from the local cache.
642643
// Set `want_metadata` to receive the OCI manifest/config in the final reply.
643644
message PullImageRequest {
644-
string image = 1;
645+
// The image to pull, given either as a literal OCI reference or as a named
646+
// kernel variant OCI alias the daemon resolves from its `[zone.kernel-variants]`
647+
// mapping in daemon.toml.
648+
oneof source {
649+
string image = 1;
650+
string kernel_variant = 7;
651+
}
645652
OciImageFormat format = 2;
646653
bool overwrite_cache = 3;
647654
bool update = 4;
@@ -657,6 +664,22 @@ message PullImageReply {
657664
OciImageMetadata metadata = 3;
658665
}
659666

667+
// Lists the named zone kernel variants the daemon can resolve, as configured under
668+
// `[zone.kernel-variants]` in daemon.toml. These are the names accepted by the
669+
// `--kernel-variant` / `dev.edera/kernel-variant` selectors.
670+
message ListKernelVariantsRequest {}
671+
672+
message ListKernelVariantsReply {
673+
repeated KernelVariant variants = 1;
674+
}
675+
676+
// A single named kernel variant: the selectable `name` and the OCI reference
677+
// the daemon resolves it to.
678+
message KernelVariant {
679+
string name = 1;
680+
string image = 2;
681+
}
682+
660683
// Client stream message for `ImportImage`: uploads an image archive directly into the
661684
// local image cache, as a sequence of `chunk`s with `last_chunk` set on the final one.
662685
// The first message must carry `image`, `digest` and `format`, identifying the image

0 commit comments

Comments
 (0)