Documentation
¶
Overview ¶
Package v1beta1 contains API Schema definitions for the capsule v1beta1 API group +kubebuilder:object:generate=true +groupName=capsule.clastix.io
Index ¶
- Constants
- Variables
- func GetTypeLabel(t runtime.Object) (label string, err error)
- func HardQuotaFor(resource fmt.Stringer) string
- func UsedQuotaFor(resource fmt.Stringer) string
- type AdditionalMetadataSpec
- type AdditionalRoleBindingsSpec
- type AllowedIP
- type AllowedListSpec
- type ExternalServiceIPsSpec
- type ImagePullPolicySpec
- type LimitRangesSpec
- type NetworkPolicySpec
- type OwnerKind
- type OwnerSpec
- type ProxyOperation
- type ProxyServiceKind
- type ProxySettings
- type ResourceQuotaSpec
- type Tenant
- type TenantList
- type TenantSpec
- type TenantStatus
Constants ¶
const ( AvailableIngressClassesAnnotation = "capsule.clastix.io/ingress-classes" AvailableIngressClassesRegexpAnnotation = "capsule.clastix.io/ingress-classes-regexp" AvailableStorageClassesAnnotation = "capsule.clastix.io/storage-classes" AvailableStorageClassesRegexpAnnotation = "capsule.clastix.io/storage-classes-regexp" AllowedRegistriesAnnotation = "capsule.clastix.io/allowed-registries" AllowedRegistriesRegexpAnnotation = "capsule.clastix.io/allowed-registries-regexp" )
const ( TenantStateActive tenantState = "active" TenantStateCordoned tenantState = "cordoned" )
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "capsule.clastix.io", Version: "v1beta1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
Functions ¶
func HardQuotaFor ¶
func UsedQuotaFor ¶
Types ¶
type AdditionalMetadataSpec ¶
type AdditionalMetadataSpec struct {
AdditionalLabels map[string]string `json:"additionalLabels,omitempty"`
AdditionalAnnotations map[string]string `json:"additionalAnnotations,omitempty"`
}
func (*AdditionalMetadataSpec) DeepCopy ¶
func (in *AdditionalMetadataSpec) DeepCopy() *AdditionalMetadataSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AdditionalMetadataSpec.
func (*AdditionalMetadataSpec) DeepCopyInto ¶
func (in *AdditionalMetadataSpec) DeepCopyInto(out *AdditionalMetadataSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type AdditionalRoleBindingsSpec ¶
type AdditionalRoleBindingsSpec struct {
ClusterRoleName string `json:"clusterRoleName"`
// kubebuilder:validation:Minimum=1
Subjects []rbacv1.Subject `json:"subjects"`
}
func (*AdditionalRoleBindingsSpec) DeepCopy ¶
func (in *AdditionalRoleBindingsSpec) DeepCopy() *AdditionalRoleBindingsSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AdditionalRoleBindingsSpec.
func (*AdditionalRoleBindingsSpec) DeepCopyInto ¶
func (in *AdditionalRoleBindingsSpec) DeepCopyInto(out *AdditionalRoleBindingsSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type AllowedIP ¶
type AllowedIP string
+kubebuilder:validation:Pattern="^([0-9]{1,3}.){3}[0-9]{1,3}(/([0-9]|[1-2][0-9]|3[0-2]))?$"
type AllowedListSpec ¶
type AllowedListSpec struct {
Exact []string `json:"allowed,omitempty"`
Regex string `json:"allowedRegex,omitempty"`
}
func (*AllowedListSpec) DeepCopy ¶
func (in *AllowedListSpec) DeepCopy() *AllowedListSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AllowedListSpec.
func (*AllowedListSpec) DeepCopyInto ¶
func (in *AllowedListSpec) DeepCopyInto(out *AllowedListSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*AllowedListSpec) ExactMatch ¶
func (in *AllowedListSpec) ExactMatch(value string) (ok bool)
func (AllowedListSpec) RegexMatch ¶
func (in AllowedListSpec) RegexMatch(value string) (ok bool)
type ExternalServiceIPsSpec ¶
type ExternalServiceIPsSpec struct {
Allowed []AllowedIP `json:"allowed"`
}
func (*ExternalServiceIPsSpec) DeepCopy ¶
func (in *ExternalServiceIPsSpec) DeepCopy() *ExternalServiceIPsSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalServiceIPsSpec.
func (*ExternalServiceIPsSpec) DeepCopyInto ¶
func (in *ExternalServiceIPsSpec) DeepCopyInto(out *ExternalServiceIPsSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImagePullPolicySpec ¶
type ImagePullPolicySpec string
+kubebuilder:validation:Enum=Always;Never;IfNotPresent
func (ImagePullPolicySpec) String ¶
func (i ImagePullPolicySpec) String() string
type LimitRangesSpec ¶
type LimitRangesSpec struct {
Items []corev1.LimitRangeSpec `json:"items,omitempty"`
}
func (*LimitRangesSpec) DeepCopy ¶
func (in *LimitRangesSpec) DeepCopy() *LimitRangesSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LimitRangesSpec.
func (*LimitRangesSpec) DeepCopyInto ¶
func (in *LimitRangesSpec) DeepCopyInto(out *LimitRangesSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type NetworkPolicySpec ¶
type NetworkPolicySpec struct {
Items []networkingv1.NetworkPolicySpec `json:"items,omitempty"`
}
func (*NetworkPolicySpec) DeepCopy ¶
func (in *NetworkPolicySpec) DeepCopy() *NetworkPolicySpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NetworkPolicySpec.
func (*NetworkPolicySpec) DeepCopyInto ¶
func (in *NetworkPolicySpec) DeepCopyInto(out *NetworkPolicySpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type OwnerSpec ¶
type OwnerSpec struct {
Kind OwnerKind `json:"kind"`
Name string `json:"name"`
ProxyOperations []ProxySettings `json:"proxySettings,omitempty"`
}
OwnerSpec defines tenant owner name and kind
func (*OwnerSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OwnerSpec.
func (*OwnerSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProxyOperation ¶
type ProxyOperation string
+kubebuilder:validation:Enum=List;Update;Delete
func (ProxyOperation) String ¶
func (p ProxyOperation) String() string
type ProxyServiceKind ¶
type ProxyServiceKind string
+kubebuilder:validation:Enum=Nodes;StorageClasses;IngressClasses
func (ProxyServiceKind) String ¶
func (p ProxyServiceKind) String() string
type ProxySettings ¶
type ProxySettings struct {
Kind ProxyServiceKind `json:"kind"`
Operations []ProxyOperation `json:"operations"`
}
func (*ProxySettings) DeepCopy ¶
func (in *ProxySettings) DeepCopy() *ProxySettings
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxySettings.
func (*ProxySettings) DeepCopyInto ¶
func (in *ProxySettings) DeepCopyInto(out *ProxySettings)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ResourceQuotaSpec ¶
type ResourceQuotaSpec struct {
Items []corev1.ResourceQuotaSpec `json:"items,omitempty"`
}
func (*ResourceQuotaSpec) DeepCopy ¶
func (in *ResourceQuotaSpec) DeepCopy() *ResourceQuotaSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourceQuotaSpec.
func (*ResourceQuotaSpec) DeepCopyInto ¶
func (in *ResourceQuotaSpec) DeepCopyInto(out *ResourceQuotaSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Tenant ¶
type Tenant struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec TenantSpec `json:"spec,omitempty"`
Status TenantStatus `json:"status,omitempty"`
}
Tenant is the Schema for the tenants API
func (*Tenant) AssignNamespaces ¶
func (*Tenant) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Tenant.
func (*Tenant) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Tenant) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Tenant) IsCordoned ¶
type TenantList ¶
type TenantList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []Tenant `json:"items"`
}
TenantList contains a list of Tenant
func (*TenantList) DeepCopy ¶
func (in *TenantList) DeepCopy() *TenantList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TenantList.
func (*TenantList) DeepCopyInto ¶
func (in *TenantList) DeepCopyInto(out *TenantList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*TenantList) DeepCopyObject ¶
func (in *TenantList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type TenantSpec ¶
type TenantSpec struct {
Owners []OwnerSpec `json:"owners"`
//+kubebuilder:validation:Minimum=1
NamespaceQuota *int32 `json:"namespaceQuota,omitempty"`
NamespacesMetadata *AdditionalMetadataSpec `json:"namespacesMetadata,omitempty"`
ServicesMetadata *AdditionalMetadataSpec `json:"servicesMetadata,omitempty"`
StorageClasses *AllowedListSpec `json:"storageClasses,omitempty"`
IngressClasses *AllowedListSpec `json:"ingressClasses,omitempty"`
IngressHostnames *AllowedListSpec `json:"ingressHostnames,omitempty"`
ContainerRegistries *AllowedListSpec `json:"containerRegistries,omitempty"`
NodeSelector map[string]string `json:"nodeSelector,omitempty"`
NetworkPolicies *NetworkPolicySpec `json:"networkPolicies,omitempty"`
LimitRanges *LimitRangesSpec `json:"limitRanges,omitempty"`
ResourceQuota *ResourceQuotaSpec `json:"resourceQuotas,omitempty"`
AdditionalRoleBindings []AdditionalRoleBindingsSpec `json:"additionalRoleBindings,omitempty"`
ExternalServiceIPs *ExternalServiceIPsSpec `json:"externalServiceIPs,omitempty"`
ImagePullPolicies []ImagePullPolicySpec `json:"imagePullPolicies,omitempty"`
PriorityClasses *AllowedListSpec `json:"priorityClasses,omitempty"`
//+kubebuilder:default=true
EnableNodePorts bool `json:"enableNodePorts,omitempty"`
}
TenantSpec defines the desired state of Tenant
func (*TenantSpec) DeepCopy ¶
func (in *TenantSpec) DeepCopy() *TenantSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TenantSpec.
func (*TenantSpec) DeepCopyInto ¶
func (in *TenantSpec) DeepCopyInto(out *TenantSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type TenantStatus ¶
type TenantStatus struct {
//+kubebuilder:default=active
State tenantState `json:"state"`
Size uint `json:"size"`
Namespaces []string `json:"namespaces,omitempty"`
}
TenantStatus defines the observed state of Tenant
func (*TenantStatus) DeepCopy ¶
func (in *TenantStatus) DeepCopy() *TenantStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TenantStatus.
func (*TenantStatus) DeepCopyInto ¶
func (in *TenantStatus) DeepCopyInto(out *TenantStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.