-
Notifications
You must be signed in to change notification settings - Fork 0
/
self_subject_rules_review.cr
52 lines (45 loc) · 3.58 KB
/
self_subject_rules_review.cr
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
# THIS FILE WAS AUTO GENERATED FROM THE K8S SWAGGER SPEC
require "yaml"
require "json"
module K8S
# SelfSubjectRulesReview enumerates the set of actions the current user can perform within a namespace. The returned list of actions may be incomplete depending on the server's authorization mode, and any errors experienced during the evaluation. SelfSubjectRulesReview should be used by UIs to [show/hide actions, or to quickly let an end user reason about their permissions. It should NOT Be used by external systems to drive authorization decisions as this raises confused deputy, cache lifetime/revocation, and correctness concerns. SubjectAccessReview, and LocalAccessReview are the correct way to defer authorization decisions to the API server.](show/hide actions, or to quickly let an end user reason about their permissions. It should NOT Be used by external systems to drive authorization decisions as this raises confused deputy, cache lifetime/revocation, and correctness concerns. SubjectAccessReview, and LocalAccessReview are the correct way to defer authorization decisions to the API server.)
@[::K8S::GroupVersionKind(group: "authorization.k8s.io", kind: "SelfSubjectRulesReview", version: "v1", full: "io.k8s.api.authorization.v1.SelfSubjectRulesReview")]
@[::K8S::Properties(
api_version: {type: String, nilable: true, key: "apiVersion", getter: false, setter: false},
kind: {type: String, nilable: true, key: "kind", getter: false, setter: false},
metadata: {type: Apimachinery::Apis::Meta::V1::ObjectMeta, nilable: true, key: "metadata", getter: false, setter: false},
spec: {type: Api::Authorization::V1::SelfSubjectRulesReviewSpec, nilable: false, key: "spec", getter: false, setter: false},
status: {type: Api::Authorization::V1::SubjectRulesReviewStatus, nilable: true, key: "status", getter: false, setter: false},
)]
@[::K8S::Action(name: "post", verb: "post",
path: "/apis/authorization.k8s.io/v1/selfsubjectrulesreviews", toplevel: false,
args: [{name: "context", type: String | Nil, default: nil},
{name: "dry_run", type: String | Nil, default: nil},
{name: "include_uninitialized", type: Bool | Nil, default: nil}]
)]
class Api::Authorization::V1::SelfSubjectRulesReview < ::K8S::Kubernetes::Resource
include ::K8S::Kubernetes::Resource::Object
include ::JSON::Serializable
include ::YAML::Serializable
@[::JSON::Field(key: "apiVersion")]
@[::YAML::Field(key: "apiVersion")]
getter api_version : String = "authorization/v1"
getter kind : String = "SelfSubjectRulesReview"
@[::JSON::Field(key: "metadata", emit_null: false)]
@[::YAML::Field(key: "metadata", emit_null: false)]
property metadata : Apimachinery::Apis::Meta::V1::ObjectMeta | Nil
# Spec holds information about the request being evaluated.
@[::JSON::Field(key: "spec", emit_null: true)]
@[::YAML::Field(key: "spec", emit_null: true)]
property spec : Api::Authorization::V1::SelfSubjectRulesReviewSpec
# Status is filled in by the server and indicates the set of actions a user can perform.
@[::JSON::Field(key: "status", emit_null: false)]
@[::YAML::Field(key: "status", emit_null: false)]
property status : Api::Authorization::V1::SubjectRulesReviewStatus | Nil
def initialize(*, @spec : Api::Authorization::V1::SelfSubjectRulesReviewSpec, @metadata : Apimachinery::Apis::Meta::V1::ObjectMeta | Nil = nil, @status : Api::Authorization::V1::SubjectRulesReviewStatus | Nil = nil)
end
end
module Resources::Authorization::V1
alias SelfSubjectRulesReview = ::K8S::Api::Authorization::V1::SelfSubjectRulesReview
end
end