api: add user namespaces field to NodeRuntimeHandlerFeatures

Signed-off-by: Sohan Kunkerkar <sohank2602@gmail.com>
This commit is contained in:
Peter Hunt
2024-05-31 13:30:45 -04:00
committed by Sohan Kunkerkar
parent 48eef1fc4f
commit 86240aaca1
18 changed files with 1088 additions and 995 deletions

View File

@@ -4898,7 +4898,10 @@ type NodeRuntimeHandlerFeatures struct {
// +featureGate=RecursiveReadOnlyMounts
// +optional
RecursiveReadOnlyMounts *bool
// Reserved: UserNamespaces *bool
// UserNamespaces is set to true if the runtime handler supports UserNamespaces, including for volumes.
// +featureGate=UserNamespacesSupport
// +optional
UserNamespaces *bool
}
// NodeRuntimeHandler is a set of runtime handler information.
@@ -5024,6 +5027,7 @@ type NodeStatus struct {
Config *NodeConfigStatus
// The available runtime handlers.
// +featureGate=RecursiveReadOnlyMounts
// +featureGate=UserNamespacesSupport
// +optional
RuntimeHandlers []NodeRuntimeHandler
}

View File

@@ -5171,6 +5171,7 @@ func Convert_core_NodeRuntimeHandler_To_v1_NodeRuntimeHandler(in *core.NodeRunti
func autoConvert_v1_NodeRuntimeHandlerFeatures_To_core_NodeRuntimeHandlerFeatures(in *v1.NodeRuntimeHandlerFeatures, out *core.NodeRuntimeHandlerFeatures, s conversion.Scope) error {
out.RecursiveReadOnlyMounts = (*bool)(unsafe.Pointer(in.RecursiveReadOnlyMounts))
out.UserNamespaces = (*bool)(unsafe.Pointer(in.UserNamespaces))
return nil
}
@@ -5181,6 +5182,7 @@ func Convert_v1_NodeRuntimeHandlerFeatures_To_core_NodeRuntimeHandlerFeatures(in
func autoConvert_core_NodeRuntimeHandlerFeatures_To_v1_NodeRuntimeHandlerFeatures(in *core.NodeRuntimeHandlerFeatures, out *v1.NodeRuntimeHandlerFeatures, s conversion.Scope) error {
out.RecursiveReadOnlyMounts = (*bool)(unsafe.Pointer(in.RecursiveReadOnlyMounts))
out.UserNamespaces = (*bool)(unsafe.Pointer(in.UserNamespaces))
return nil
}

View File

@@ -2805,6 +2805,11 @@ func (in *NodeRuntimeHandlerFeatures) DeepCopyInto(out *NodeRuntimeHandlerFeatur
*out = new(bool)
**out = **in
}
if in.UserNamespaces != nil {
in, out := &in.UserNamespaces, &out.UserNamespaces
*out = new(bool)
**out = **in
}
return
}