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