Documentation
¶
Index ¶
- type AccessEntity
- type AccessEntityType
- type ApprovalSpec
- type ExtendedDuration
- func (d ExtendedDuration) MarshalJSON() ([]byte, error)
- func (ExtendedDuration) OpenAPISchemaFormat() string
- func (ExtendedDuration) OpenAPISchemaType() []string
- func (d ExtendedDuration) String() string
- func (d ExtendedDuration) ToUnstructured() any
- func (d *ExtendedDuration) UnmarshalJSON(b []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessEntity ¶
type AccessEntity struct {
// The name of the entity
Name string `json:"name,omitempty"`
// The type of the entity
// +kubebuilder:validation:Enum=User;Group;System;ServiceAccount
Type AccessEntityType `json:"type,omitempty"`
// The groups the entity belongs to
Groups []string `json:"groups,omitempty"`
}
+kubebuilder:object:generate=true
func (*AccessEntity) DeepCopy ¶
func (in *AccessEntity) DeepCopy() *AccessEntity
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AccessEntity.
func (*AccessEntity) DeepCopyInto ¶
func (in *AccessEntity) DeepCopyInto(out *AccessEntity)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type AccessEntityType ¶
type AccessEntityType string
const ( AccessEntityTypeUser AccessEntityType = "User" AccessEntityTypeGroup AccessEntityType = "Group" AccessEntityTypeSystem AccessEntityType = "System" AccessEntityTypeServiceAccount AccessEntityType = "ServiceAccount" )
func (AccessEntityType) String ¶
func (t AccessEntityType) String() string
type ApprovalSpec ¶
type ApprovalSpec struct {
// Auto automatically approves matching requests. Approvers are ignored for
// automatic approvals.
// +optional
Auto bool `json:"auto,omitempty"`
// Approvers lists the subjects permitted to approve a request manually.
// When omitted, any subject with permission to update the request status may
// approve it.
// +optional
Approvers rbac.UserListSpec `json:"approvers,omitempty"`
// Conditions contains CEL expressions evaluated as an OR list. At least one
// expression must evaluate to true. When omitted, approval is unconditional.
// +kubebuilder:validation:items:MinLength=1
// +optional
Conditions []string `json:"conditions,omitempty"`
}
+kubebuilder:object:generate=true
func (*ApprovalSpec) DeepCopy ¶
func (in *ApprovalSpec) DeepCopy() *ApprovalSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApprovalSpec.
func (*ApprovalSpec) DeepCopyInto ¶
func (in *ApprovalSpec) DeepCopyInto(out *ApprovalSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ApprovalSpec) IsApprover ¶
func (a ApprovalSpec) IsApprover(name string, groups []string) bool
IsApprover reports whether an authenticated subject may manually approve a request. An empty approver list deliberately permits any authenticated subject that already has Kubernetes authorization to update the request.
type ExtendedDuration ¶
func (ExtendedDuration) MarshalJSON ¶
func (d ExtendedDuration) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaler interface.
func (ExtendedDuration) OpenAPISchemaFormat ¶
func (ExtendedDuration) OpenAPISchemaFormat() string
OpenAPISchemaFormat is used by the kube-openapi generator when constructing the OpenAPI spec of this type.
func (ExtendedDuration) OpenAPISchemaType ¶
func (ExtendedDuration) OpenAPISchemaType() []string
OpenAPISchemaType is used by the kube-openapi generator when constructing the OpenAPI spec of this type.
See: https://github.com/kubernetes/kube-openapi/tree/master/pkg/generators
func (ExtendedDuration) String ¶
func (d ExtendedDuration) String() string
String returns the duration formatted as an extended duration string.
func (ExtendedDuration) ToUnstructured ¶
func (d ExtendedDuration) ToUnstructured() any
ToUnstructured implements the value.UnstructuredConverter interface.
func (*ExtendedDuration) UnmarshalJSON ¶
func (d *ExtendedDuration) UnmarshalJSON(b []byte) error
UnmarshalJSON implements the json.Unmarshaller interface.