k8s_pb/api/node/v1beta1/
mod.rs

1// This file is @generated by prost-build.
2/// Overhead structure represents the resource overhead associated with running a pod.
3#[derive(Clone, PartialEq, ::prost::Message)]
4pub struct Overhead {
5    /// podFixed represents the fixed resource overhead associated with running a pod.
6    /// +optional
7    #[prost(btree_map = "string, message", tag = "1")]
8    pub pod_fixed: ::prost::alloc::collections::BTreeMap<
9        ::prost::alloc::string::String,
10        super::super::super::apimachinery::pkg::api::resource::Quantity,
11    >,
12}
13/// RuntimeClass defines a class of container runtime supported in the cluster.
14/// The RuntimeClass is used to determine which container runtime is used to run
15/// all containers in a pod. RuntimeClasses are (currently) manually defined by a
16/// user or cluster provisioner, and referenced in the PodSpec. The Kubelet is
17/// responsible for resolving the RuntimeClassName reference before running the
18/// pod.  For more details, see
19/// <https://git.k8s.io/enhancements/keps/sig-node/585-runtime-class>
20#[derive(Clone, PartialEq, ::prost::Message)]
21pub struct RuntimeClass {
22    /// More info: <https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata>
23    /// +optional
24    #[prost(message, optional, tag = "1")]
25    pub metadata: ::core::option::Option<super::super::super::apimachinery::pkg::apis::meta::v1::ObjectMeta>,
26    /// handler specifies the underlying runtime and configuration that the CRI
27    /// implementation will use to handle pods of this class. The possible values
28    /// are specific to the node & CRI configuration.  It is assumed that all
29    /// handlers are available on every node, and handlers of the same name are
30    /// equivalent on every node.
31    /// For example, a handler called "runc" might specify that the runc OCI
32    /// runtime (using native Linux containers) will be used to run the containers
33    /// in a pod.
34    /// The handler must be lowercase, conform to the DNS Label (RFC 1123) requirements,
35    /// and is immutable.
36    #[prost(string, optional, tag = "2")]
37    pub handler: ::core::option::Option<::prost::alloc::string::String>,
38    /// overhead represents the resource overhead associated with running a pod for a
39    /// given RuntimeClass. For more details, see
40    /// <https://git.k8s.io/enhancements/keps/sig-node/688-pod-overhead/README.md>
41    /// +optional
42    #[prost(message, optional, tag = "3")]
43    pub overhead: ::core::option::Option<Overhead>,
44    /// scheduling holds the scheduling constraints to ensure that pods running
45    /// with this RuntimeClass are scheduled to nodes that support it.
46    /// If scheduling is nil, this RuntimeClass is assumed to be supported by all
47    /// nodes.
48    /// +optional
49    #[prost(message, optional, tag = "4")]
50    pub scheduling: ::core::option::Option<Scheduling>,
51}
52/// RuntimeClassList is a list of RuntimeClass objects.
53#[derive(Clone, PartialEq, ::prost::Message)]
54pub struct RuntimeClassList {
55    /// Standard list metadata.
56    /// More info: <https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata>
57    /// +optional
58    #[prost(message, optional, tag = "1")]
59    pub metadata: ::core::option::Option<super::super::super::apimachinery::pkg::apis::meta::v1::ListMeta>,
60    /// items is a list of schema objects.
61    #[prost(message, repeated, tag = "2")]
62    pub items: ::prost::alloc::vec::Vec<RuntimeClass>,
63}
64/// Scheduling specifies the scheduling constraints for nodes supporting a
65/// RuntimeClass.
66#[derive(Clone, PartialEq, ::prost::Message)]
67pub struct Scheduling {
68    /// nodeSelector lists labels that must be present on nodes that support this
69    /// RuntimeClass. Pods using this RuntimeClass can only be scheduled to a
70    /// node matched by this selector. The RuntimeClass nodeSelector is merged
71    /// with a pod's existing nodeSelector. Any conflicts will cause the pod to
72    /// be rejected in admission.
73    /// +optional
74    /// +mapType=atomic
75    #[prost(btree_map = "string, string", tag = "1")]
76    pub node_selector:
77        ::prost::alloc::collections::BTreeMap<::prost::alloc::string::String, ::prost::alloc::string::String>,
78    /// tolerations are appended (excluding duplicates) to pods running with this
79    /// RuntimeClass during admission, effectively unioning the set of nodes
80    /// tolerated by the pod and the RuntimeClass.
81    /// +optional
82    /// +listType=atomic
83    #[prost(message, repeated, tag = "2")]
84    pub tolerations: ::prost::alloc::vec::Vec<super::super::core::v1::Toleration>,
85}