fleet_api_rs/api/
fleet_cluster_registration_token.rs

1// WARNING: generated by kopium - manual changes will be overwritten
2// kopium command: kopium -D Default -D PartialEq -A -d -f -
3// kopium version: 0.21.2
4
5#[allow(unused_imports)]
6mod prelude {
7    pub use kube::CustomResource;
8    pub use schemars::JsonSchema;
9    pub use serde::{Deserialize, Serialize};
10}
11use self::prelude::*;
12
13#[derive(CustomResource, Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
14#[kube(
15    group = "fleet.cattle.io",
16    version = "v1alpha1",
17    kind = "ClusterRegistrationToken",
18    plural = "clusterregistrationtokens"
19)]
20#[kube(namespaced)]
21#[kube(status = "ClusterRegistrationTokenStatus")]
22#[kube(derive = "Default")]
23#[kube(derive = "PartialEq")]
24pub struct ClusterRegistrationTokenSpec {
25    /// TTL is the time to live for the token. It is used to calculate the
26    /// expiration time. If the token expires, it will be deleted.
27    #[serde(default, skip_serializing_if = "Option::is_none")]
28    pub ttl: Option<String>,
29}
30
31#[derive(Serialize, Deserialize, Clone, Debug, Default, PartialEq, JsonSchema)]
32pub struct ClusterRegistrationTokenStatus {
33    /// Expires is the time when the token expires.
34    #[serde(default, skip_serializing_if = "Option::is_none")]
35    pub expires: Option<String>,
36    /// SecretName is the name of the secret containing the token.
37    #[serde(
38        default,
39        skip_serializing_if = "Option::is_none",
40        rename = "secretName"
41    )]
42    pub secret_name: Option<String>,
43}