cluster_api_rs/api/capi_machineset.rs
1// WARNING: generated by kopium - manual changes will be overwritten
2// kopium command: kopium --smart-derive-elision -D Default -D PartialEq -A -d -f -
3// kopium version: 0.22.5
4
5#[allow(unused_imports)]
6mod prelude {
7 pub use k8s_openapi::apimachinery::pkg::apis::meta::v1::Condition;
8 pub use kube::CustomResource;
9 pub use schemars::JsonSchema;
10 pub use serde::{Deserialize, Serialize};
11 pub use std::collections::BTreeMap;
12}
13
14use self::prelude::*;
15
16/// spec is the desired state of MachineSet.
17#[derive(CustomResource, Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
18#[kube(
19 group = "cluster.x-k8s.io",
20 version = "v1beta2",
21 kind = "MachineSet",
22 plural = "machinesets"
23)]
24#[kube(namespaced)]
25#[kube(status = "MachineSetStatus")]
26#[kube(derive = "Default")]
27#[kube(derive = "PartialEq")]
28pub struct MachineSetSpec {
29 /// clusterName is the name of the Cluster this object belongs to.
30 #[serde(rename = "clusterName")]
31 pub cluster_name: String,
32 /// deletion contains configuration options for MachineSet deletion.
33 #[serde(default, skip_serializing_if = "Option::is_none")]
34 pub deletion: Option<MachineSetDeletion>,
35 /// machineNaming allows changing the naming pattern used when creating Machines.
36 /// Note: InfraMachines & BootstrapConfigs will use the same name as the corresponding Machines.
37 #[serde(
38 default,
39 skip_serializing_if = "Option::is_none",
40 rename = "machineNaming"
41 )]
42 pub machine_naming: Option<MachineSetMachineNaming>,
43 /// replicas is the number of desired replicas.
44 /// This is a pointer to distinguish between explicit zero and unspecified.
45 ///
46 /// Defaults to:
47 /// * if the Kubernetes autoscaler min size and max size annotations are set:
48 /// - if it's a new MachineSet, use min size
49 /// - if the replicas field of the old MachineSet is < min size, use min size
50 /// - if the replicas field of the old MachineSet is > max size, use max size
51 /// - if the replicas field of the old MachineSet is in the (min size, max size) range, keep the value from the oldMS
52 /// * otherwise use 1
53 /// Note: Defaulting will be run whenever the replicas field is not set:
54 /// * A new MachineSet is created with replicas not set.
55 /// * On an existing MachineSet the replicas field was first set and is now unset.
56 /// Those cases are especially relevant for the following Kubernetes autoscaler use cases:
57 /// * A new MachineSet is created and replicas should be managed by the autoscaler
58 /// * An existing MachineSet which initially wasn't controlled by the autoscaler
59 /// should be later controlled by the autoscaler
60 #[serde(default, skip_serializing_if = "Option::is_none")]
61 pub replicas: Option<i32>,
62 /// selector is a label query over machines that should match the replica count.
63 /// Label keys and values that must match in order to be controlled by this MachineSet.
64 /// It must match the machine template's labels.
65 /// More info: <https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors>
66 pub selector: MachineSetSelector,
67 /// template is the object that describes the machine that will be created if
68 /// insufficient replicas are detected.
69 /// Object references to custom resources are treated as templates.
70 pub template: MachineSetTemplate,
71}
72
73/// deletion contains configuration options for MachineSet deletion.
74#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
75pub struct MachineSetDeletion {
76 /// order defines the order in which Machines are deleted when downscaling.
77 /// Defaults to "Random". Valid values are "Random, "Newest", "Oldest"
78 #[serde(default, skip_serializing_if = "Option::is_none")]
79 pub order: Option<MachineSetDeletionOrder>,
80}
81
82/// deletion contains configuration options for MachineSet deletion.
83#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
84pub enum MachineSetDeletionOrder {
85 Random,
86 Newest,
87 Oldest,
88}
89
90/// machineNaming allows changing the naming pattern used when creating Machines.
91/// Note: InfraMachines & BootstrapConfigs will use the same name as the corresponding Machines.
92#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
93pub struct MachineSetMachineNaming {
94 /// template defines the template to use for generating the names of the
95 /// Machine objects.
96 /// If not defined, it will fallback to `{{ .machineSet.name }}-{{ .random }}`.
97 /// If the generated name string exceeds 63 characters, it will be trimmed to
98 /// 58 characters and will
99 /// get concatenated with a random suffix of length 5.
100 /// Length of the template string must not exceed 256 characters.
101 /// The template allows the following variables `.cluster.name`,
102 /// `.machineSet.name` and `.random`.
103 /// The variable `.cluster.name` retrieves the name of the cluster object
104 /// that owns the Machines being created.
105 /// The variable `.machineSet.name` retrieves the name of the MachineSet
106 /// object that owns the Machines being created.
107 /// The variable `.random` is substituted with random alphanumeric string,
108 /// without vowels, of length 5. This variable is required part of the
109 /// template. If not provided, validation will fail.
110 #[serde(default, skip_serializing_if = "Option::is_none")]
111 pub template: Option<String>,
112}
113
114/// selector is a label query over machines that should match the replica count.
115/// Label keys and values that must match in order to be controlled by this MachineSet.
116/// It must match the machine template's labels.
117/// More info: <https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors>
118#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
119pub struct MachineSetSelector {
120 /// matchExpressions is a list of label selector requirements. The requirements are ANDed.
121 #[serde(
122 default,
123 skip_serializing_if = "Option::is_none",
124 rename = "matchExpressions"
125 )]
126 pub match_expressions: Option<Vec<MachineSetSelectorMatchExpressions>>,
127 /// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
128 /// map is equivalent to an element of matchExpressions, whose key field is "key", the
129 /// operator is "In", and the values array contains only "value". The requirements are ANDed.
130 #[serde(
131 default,
132 skip_serializing_if = "Option::is_none",
133 rename = "matchLabels"
134 )]
135 pub match_labels: Option<BTreeMap<String, String>>,
136}
137
138/// A label selector requirement is a selector that contains values, a key, and an operator that
139/// relates the key and values.
140#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
141pub struct MachineSetSelectorMatchExpressions {
142 /// key is the label key that the selector applies to.
143 pub key: String,
144 /// operator represents a key's relationship to a set of values.
145 /// Valid operators are In, NotIn, Exists and DoesNotExist.
146 pub operator: String,
147 /// values is an array of string values. If the operator is In or NotIn,
148 /// the values array must be non-empty. If the operator is Exists or DoesNotExist,
149 /// the values array must be empty. This array is replaced during a strategic
150 /// merge patch.
151 #[serde(default, skip_serializing_if = "Option::is_none")]
152 pub values: Option<Vec<String>>,
153}
154
155/// template is the object that describes the machine that will be created if
156/// insufficient replicas are detected.
157/// Object references to custom resources are treated as templates.
158#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
159pub struct MachineSetTemplate {
160 /// metadata is the standard object's metadata.
161 /// More info: <https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata>
162 #[serde(default, skip_serializing_if = "Option::is_none")]
163 pub metadata: Option<MachineSetTemplateMetadata>,
164 /// spec is the specification of the desired behavior of the machine.
165 /// More info: <https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status>
166 pub spec: MachineSetTemplateSpec,
167}
168
169/// metadata is the standard object's metadata.
170/// More info: <https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata>
171#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
172pub struct MachineSetTemplateMetadata {
173 /// annotations is an unstructured key value map stored with a resource that may be
174 /// set by external tools to store and retrieve arbitrary metadata. They are not
175 /// queryable and should be preserved when modifying objects.
176 /// More info: <http://kubernetes.io/docs/user-guide/annotations>
177 #[serde(default, skip_serializing_if = "Option::is_none")]
178 pub annotations: Option<BTreeMap<String, String>>,
179 /// labels is a map of string keys and values that can be used to organize and categorize
180 /// (scope and select) objects. May match selectors of replication controllers
181 /// and services.
182 /// More info: <http://kubernetes.io/docs/user-guide/labels>
183 #[serde(default, skip_serializing_if = "Option::is_none")]
184 pub labels: Option<BTreeMap<String, String>>,
185}
186
187/// spec is the specification of the desired behavior of the machine.
188/// More info: <https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status>
189#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
190pub struct MachineSetTemplateSpec {
191 /// bootstrap is a reference to a local struct which encapsulates
192 /// fields to configure the Machine’s bootstrapping mechanism.
193 pub bootstrap: MachineSetTemplateSpecBootstrap,
194 /// clusterName is the name of the Cluster this object belongs to.
195 #[serde(rename = "clusterName")]
196 pub cluster_name: String,
197 /// deletion contains configuration options for Machine deletion.
198 #[serde(default, skip_serializing_if = "Option::is_none")]
199 pub deletion: Option<MachineSetTemplateSpecDeletion>,
200 /// failureDomain is the failure domain the machine will be created in.
201 /// Must match the name of a FailureDomain from the Cluster status.
202 #[serde(
203 default,
204 skip_serializing_if = "Option::is_none",
205 rename = "failureDomain"
206 )]
207 pub failure_domain: Option<String>,
208 /// infrastructureRef is a required reference to a custom resource
209 /// offered by an infrastructure provider.
210 #[serde(rename = "infrastructureRef")]
211 pub infrastructure_ref: MachineSetTemplateSpecInfrastructureRef,
212 /// minReadySeconds is the minimum number of seconds for which a Machine should be ready before considering it available.
213 /// Defaults to 0 (Machine will be considered available as soon as the Machine is ready)
214 #[serde(
215 default,
216 skip_serializing_if = "Option::is_none",
217 rename = "minReadySeconds"
218 )]
219 pub min_ready_seconds: Option<i32>,
220 /// providerID is the identification ID of the machine provided by the provider.
221 /// This field must match the provider ID as seen on the node object corresponding to this machine.
222 /// This field is required by higher level consumers of cluster-api. Example use case is cluster autoscaler
223 /// with cluster-api as provider. Clean-up logic in the autoscaler compares machines to nodes to find out
224 /// machines at provider which could not get registered as Kubernetes nodes. With cluster-api as a
225 /// generic out-of-tree provider for autoscaler, this field is required by autoscaler to be
226 /// able to have a provider view of the list of machines. Another list of nodes is queried from the k8s apiserver
227 /// and then a comparison is done to find out unregistered machines and are marked for delete.
228 /// This field will be set by the actuators and consumed by higher level entities like autoscaler that will
229 /// be interfacing with cluster-api as generic provider.
230 #[serde(
231 default,
232 skip_serializing_if = "Option::is_none",
233 rename = "providerID"
234 )]
235 pub provider_id: Option<String>,
236 /// readinessGates specifies additional conditions to include when evaluating Machine Ready condition.
237 ///
238 /// This field can be used e.g. by Cluster API control plane providers to extend the semantic of the
239 /// Ready condition for the Machine they control, like the kubeadm control provider adding ReadinessGates
240 /// for the APIServerPodHealthy, SchedulerPodHealthy conditions, etc.
241 ///
242 /// Another example are external controllers, e.g. responsible to install special software/hardware on the Machines;
243 /// they can include the status of those components with a new condition and add this condition to ReadinessGates.
244 ///
245 /// NOTE: In case readinessGates conditions start with the APIServer, ControllerManager, Scheduler prefix, and all those
246 /// readiness gates condition are reporting the same message, when computing the Machine's Ready condition those
247 /// readinessGates will be replaced by a single entry reporting "Control plane components: " + message.
248 /// This helps to improve readability of conditions bubbling up to the Machine's owner resource / to the Cluster).
249 #[serde(
250 default,
251 skip_serializing_if = "Option::is_none",
252 rename = "readinessGates"
253 )]
254 pub readiness_gates: Option<Vec<MachineSetTemplateSpecReadinessGates>>,
255 /// version defines the desired Kubernetes version.
256 /// This field is meant to be optionally used by bootstrap providers.
257 #[serde(default, skip_serializing_if = "Option::is_none")]
258 pub version: Option<String>,
259}
260
261/// bootstrap is a reference to a local struct which encapsulates
262/// fields to configure the Machine’s bootstrapping mechanism.
263#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
264pub struct MachineSetTemplateSpecBootstrap {
265 /// configRef is a reference to a bootstrap provider-specific resource
266 /// that holds configuration details. The reference is optional to
267 /// allow users/operators to specify Bootstrap.DataSecretName without
268 /// the need of a controller.
269 #[serde(default, skip_serializing_if = "Option::is_none", rename = "configRef")]
270 pub config_ref: Option<MachineSetTemplateSpecBootstrapConfigRef>,
271 /// dataSecretName is the name of the secret that stores the bootstrap data script.
272 /// If nil, the Machine should remain in the Pending state.
273 #[serde(
274 default,
275 skip_serializing_if = "Option::is_none",
276 rename = "dataSecretName"
277 )]
278 pub data_secret_name: Option<String>,
279}
280
281/// configRef is a reference to a bootstrap provider-specific resource
282/// that holds configuration details. The reference is optional to
283/// allow users/operators to specify Bootstrap.DataSecretName without
284/// the need of a controller.
285#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
286pub struct MachineSetTemplateSpecBootstrapConfigRef {
287 /// apiGroup is the group of the resource being referenced.
288 /// apiGroup must be fully qualified domain name.
289 /// The corresponding version for this reference will be looked up from the contract
290 /// labels of the corresponding CRD of the resource being referenced.
291 #[serde(rename = "apiGroup")]
292 pub api_group: String,
293 /// kind of the resource being referenced.
294 /// kind must consist of alphanumeric characters or '-', start with an alphabetic character, and end with an alphanumeric character.
295 pub kind: String,
296 /// name of the resource being referenced.
297 /// name must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character.
298 pub name: String,
299}
300
301/// deletion contains configuration options for Machine deletion.
302#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
303pub struct MachineSetTemplateSpecDeletion {
304 /// nodeDeletionTimeoutSeconds defines how long the controller will attempt to delete the Node that the Machine
305 /// hosts after the Machine is marked for deletion. A duration of 0 will retry deletion indefinitely.
306 /// Defaults to 10 seconds.
307 #[serde(
308 default,
309 skip_serializing_if = "Option::is_none",
310 rename = "nodeDeletionTimeoutSeconds"
311 )]
312 pub node_deletion_timeout_seconds: Option<i32>,
313 /// nodeDrainTimeoutSeconds is the total amount of time that the controller will spend on draining a node.
314 /// The default value is 0, meaning that the node can be drained without any time limitations.
315 /// NOTE: nodeDrainTimeoutSeconds is different from `kubectl drain --timeout`
316 #[serde(
317 default,
318 skip_serializing_if = "Option::is_none",
319 rename = "nodeDrainTimeoutSeconds"
320 )]
321 pub node_drain_timeout_seconds: Option<i32>,
322 /// nodeVolumeDetachTimeoutSeconds is the total amount of time that the controller will spend on waiting for all volumes
323 /// to be detached. The default value is 0, meaning that the volumes can be detached without any time limitations.
324 #[serde(
325 default,
326 skip_serializing_if = "Option::is_none",
327 rename = "nodeVolumeDetachTimeoutSeconds"
328 )]
329 pub node_volume_detach_timeout_seconds: Option<i32>,
330}
331
332/// infrastructureRef is a required reference to a custom resource
333/// offered by an infrastructure provider.
334#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
335pub struct MachineSetTemplateSpecInfrastructureRef {
336 /// apiGroup is the group of the resource being referenced.
337 /// apiGroup must be fully qualified domain name.
338 /// The corresponding version for this reference will be looked up from the contract
339 /// labels of the corresponding CRD of the resource being referenced.
340 #[serde(rename = "apiGroup")]
341 pub api_group: String,
342 /// kind of the resource being referenced.
343 /// kind must consist of alphanumeric characters or '-', start with an alphabetic character, and end with an alphanumeric character.
344 pub kind: String,
345 /// name of the resource being referenced.
346 /// name must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character.
347 pub name: String,
348}
349
350/// MachineReadinessGate contains the type of a Machine condition to be used as a readiness gate.
351#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
352pub struct MachineSetTemplateSpecReadinessGates {
353 /// conditionType refers to a condition with matching type in the Machine's condition list.
354 /// If the conditions doesn't exist, it will be treated as unknown.
355 /// Note: Both Cluster API conditions or conditions added by 3rd party controllers can be used as readiness gates.
356 #[serde(rename = "conditionType")]
357 pub condition_type: String,
358 /// polarity of the conditionType specified in this readinessGate.
359 /// Valid values are Positive, Negative and omitted.
360 /// When omitted, the default behaviour will be Positive.
361 /// A positive polarity means that the condition should report a true status under normal conditions.
362 /// A negative polarity means that the condition should report a false status under normal conditions.
363 #[serde(default, skip_serializing_if = "Option::is_none")]
364 pub polarity: Option<MachineSetTemplateSpecReadinessGatesPolarity>,
365}
366
367/// MachineReadinessGate contains the type of a Machine condition to be used as a readiness gate.
368#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
369pub enum MachineSetTemplateSpecReadinessGatesPolarity {
370 Positive,
371 Negative,
372}
373
374/// status is the observed state of MachineSet.
375#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
376pub struct MachineSetStatus {
377 /// availableReplicas is the number of available replicas for this MachineSet. A machine is considered available when Machine's Available condition is true.
378 #[serde(
379 default,
380 skip_serializing_if = "Option::is_none",
381 rename = "availableReplicas"
382 )]
383 pub available_replicas: Option<i32>,
384 /// conditions represents the observations of a MachineSet's current state.
385 /// Known condition types are MachinesReady, MachinesUpToDate, ScalingUp, ScalingDown, Remediating, Deleting, Paused.
386 #[serde(default, skip_serializing_if = "Option::is_none")]
387 pub conditions: Option<Vec<Condition>>,
388 /// deprecated groups all the status fields that are deprecated and will be removed when all the nested field are removed.
389 #[serde(default, skip_serializing_if = "Option::is_none")]
390 pub deprecated: Option<MachineSetStatusDeprecated>,
391 /// observedGeneration reflects the generation of the most recently observed MachineSet.
392 #[serde(
393 default,
394 skip_serializing_if = "Option::is_none",
395 rename = "observedGeneration"
396 )]
397 pub observed_generation: Option<i64>,
398 /// readyReplicas is the number of ready replicas for this MachineSet. A machine is considered ready when Machine's Ready condition is true.
399 #[serde(
400 default,
401 skip_serializing_if = "Option::is_none",
402 rename = "readyReplicas"
403 )]
404 pub ready_replicas: Option<i32>,
405 /// replicas is the most recently observed number of replicas.
406 #[serde(default, skip_serializing_if = "Option::is_none")]
407 pub replicas: Option<i32>,
408 /// selector is the same as the label selector but in the string format to avoid introspection
409 /// by clients. The string will be in the same format as the query-param syntax.
410 /// More info about label selectors: <http://kubernetes.io/docs/user-guide/labels#label-selectors>
411 #[serde(default, skip_serializing_if = "Option::is_none")]
412 pub selector: Option<String>,
413 /// upToDateReplicas is the number of up-to-date replicas for this MachineSet. A machine is considered up-to-date when Machine's UpToDate condition is true.
414 #[serde(
415 default,
416 skip_serializing_if = "Option::is_none",
417 rename = "upToDateReplicas"
418 )]
419 pub up_to_date_replicas: Option<i32>,
420}
421
422/// deprecated groups all the status fields that are deprecated and will be removed when all the nested field are removed.
423#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
424pub struct MachineSetStatusDeprecated {
425 /// v1beta1 groups all the status fields that are deprecated and will be removed when support for v1beta1 will be dropped.
426 #[serde(default, skip_serializing_if = "Option::is_none")]
427 pub v1beta1: Option<MachineSetStatusDeprecatedV1beta1>,
428}
429
430/// v1beta1 groups all the status fields that are deprecated and will be removed when support for v1beta1 will be dropped.
431#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
432pub struct MachineSetStatusDeprecatedV1beta1 {
433 /// availableReplicas is the number of available replicas (ready for at least minReadySeconds) for this MachineSet.
434 ///
435 /// Deprecated: This field is deprecated and is going to be removed when support for v1beta1 will be dropped. Please see <https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20240916-improve-status-in-CAPI-resources.md> for more details.
436 #[serde(
437 default,
438 skip_serializing_if = "Option::is_none",
439 rename = "availableReplicas"
440 )]
441 pub available_replicas: Option<i32>,
442 /// conditions defines current service state of the MachineSet.
443 ///
444 /// Deprecated: This field is deprecated and is going to be removed when support for v1beta1 will be dropped. Please see <https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20240916-improve-status-in-CAPI-resources.md> for more details.
445 #[serde(default, skip_serializing_if = "Option::is_none")]
446 pub conditions: Option<Vec<Condition>>,
447 /// failureMessage will be set in the event that there is a terminal problem
448 /// reconciling the Machine and will contain a more verbose string suitable
449 /// for logging and human consumption.
450 ///
451 /// Deprecated: This field is deprecated and is going to be removed when support for v1beta1 will be dropped. Please see <https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20240916-improve-status-in-CAPI-resources.md> for more details.
452 #[serde(
453 default,
454 skip_serializing_if = "Option::is_none",
455 rename = "failureMessage"
456 )]
457 pub failure_message: Option<String>,
458 /// failureReason will be set in the event that there is a terminal problem
459 /// reconciling the Machine and will contain a succinct value suitable
460 /// for machine interpretation.
461 ///
462 /// In the event that there is a terminal problem reconciling the
463 /// replicas, both FailureReason and FailureMessage will be set. FailureReason
464 /// will be populated with a succinct value suitable for machine
465 /// interpretation, while FailureMessage will contain a more verbose
466 /// string suitable for logging and human consumption.
467 ///
468 /// These fields should not be set for transitive errors that a
469 /// controller faces that are expected to be fixed automatically over
470 /// time (like service outages), but instead indicate that something is
471 /// fundamentally wrong with the MachineTemplate's spec or the configuration of
472 /// the machine controller, and that manual intervention is required. Examples
473 /// of terminal errors would be invalid combinations of settings in the
474 /// spec, values that are unsupported by the machine controller, or the
475 /// responsible machine controller itself being critically misconfigured.
476 ///
477 /// Any transient errors that occur during the reconciliation of Machines
478 /// can be added as events to the MachineSet object and/or logged in the
479 /// controller's output.
480 ///
481 /// Deprecated: This field is deprecated and is going to be removed when support for v1beta1 will be dropped. Please see <https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20240916-improve-status-in-CAPI-resources.md> for more details.
482 #[serde(
483 default,
484 skip_serializing_if = "Option::is_none",
485 rename = "failureReason"
486 )]
487 pub failure_reason: Option<String>,
488 /// fullyLabeledReplicas is the number of replicas that have labels matching the labels of the machine template of the MachineSet.
489 ///
490 /// Deprecated: This field is deprecated and is going to be removed when support for v1beta1 will be dropped. Please see <https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20240916-improve-status-in-CAPI-resources.md> for more details.
491 #[serde(
492 default,
493 skip_serializing_if = "Option::is_none",
494 rename = "fullyLabeledReplicas"
495 )]
496 pub fully_labeled_replicas: Option<i32>,
497 /// readyReplicas is the number of ready replicas for this MachineSet. A machine is considered ready when the node has been created and is "Ready".
498 ///
499 /// Deprecated: This field is deprecated and is going to be removed when support for v1beta1 will be dropped. Please see <https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20240916-improve-status-in-CAPI-resources.md> for more details.
500 #[serde(
501 default,
502 skip_serializing_if = "Option::is_none",
503 rename = "readyReplicas"
504 )]
505 pub ready_replicas: Option<i32>,
506}