1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
/*
* Kubernetes
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: v1.27.5+k3s1
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
/// IoCattleManagementv3GlobalRole : GlobalRole defines rules that can be applied to the local cluster and or every downstream cluster.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct IoCattleManagementv3GlobalRole {
/// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
#[serde(rename = "apiVersion", skip_serializing_if = "Option::is_none")]
pub api_version: Option<String>,
/// Builtin specifies that this GlobalRole was created by Rancher if true. Immutable.
#[serde(rename = "builtin", skip_serializing_if = "Option::is_none")]
pub builtin: Option<bool>,
/// Description holds text that describes the resource.
#[serde(rename = "description", skip_serializing_if = "Option::is_none")]
pub description: Option<String>,
/// DisplayName is the human-readable name displayed in the UI for this resource.
#[serde(rename = "displayName", skip_serializing_if = "Option::is_none")]
pub display_name: Option<String>,
/// InheritedClusterRoles are the names of RoleTemplates whose permissions are granted by this GlobalRole in every cluster besides the local cluster. To grant permissions in the local cluster, use the Rules field.
#[serde(rename = "inheritedClusterRoles", skip_serializing_if = "Option::is_none")]
pub inherited_cluster_roles: Option<Vec<String>>,
/// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
#[serde(rename = "kind", skip_serializing_if = "Option::is_none")]
pub kind: Option<String>,
#[serde(rename = "metadata", skip_serializing_if = "Option::is_none")]
pub metadata: Option<kube::api::ObjectMeta>,
/// NewUserDefault specifies that all new users created should be bound to this GlobalRole if true.
#[serde(rename = "newUserDefault", skip_serializing_if = "Option::is_none")]
pub new_user_default: Option<bool>,
/// Rules holds a list of PolicyRules that are applied to the local cluster only.
#[serde(rename = "rules", skip_serializing_if = "Option::is_none")]
pub rules: Option<Vec<models::IoCattleManagementv3GlobalRoleRulesInner>>,
}
impl IoCattleManagementv3GlobalRole {
/// GlobalRole defines rules that can be applied to the local cluster and or every downstream cluster.
pub fn new() -> IoCattleManagementv3GlobalRole {
IoCattleManagementv3GlobalRole {
api_version: None,
builtin: None,
description: None,
display_name: None,
inherited_cluster_roles: None,
kind: None,
metadata: None,
new_user_default: None,
rules: None,
}
}
}