Documentation ¶
Overview ¶
Package v1beta1 contains API Schema definitions for the maegus v1beta1 API group +k8s:deepcopy-gen=package,register +groupName=maegus.com
Package v1beta1 contains API Schema definitions for the maegus v1beta1 API group +k8s:deepcopy-gen=package,register +groupName=maegus.com
Index ¶
- Constants
- Variables
- func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition
- func GetProxierName(labels map[string]string) string
- func Kind(kind string) schema.GroupKind
- func RegisterDefaults(scheme *runtime.Scheme) error
- func Resource(resource string) schema.GroupResource
- type BackendSpec
- type Protocol
- type Proxier
- type ProxierList
- type ProxierPort
- type ProxierSpec
- type ProxierStatus
Constants ¶
const ( // ConfigMapHashAnnotationKey is the name of an annotation which detects the update of // proxier corresponding config map. ConfigMapHashAnnotationKey = "proxier.maegus.com/configmap-hash" )
const (
// ProxierKeyLabel is the key of proxier name
ProxierKeyLabel = "maegus.com/proxier-name"
)
Variables ¶
var ( // SchemeGroupVersion is group version used to register these objects SchemeGroupVersion = schema.GroupVersion{Group: "maegus.com", Version: "v1beta1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion} // AddToScheme . AddToScheme = SchemeBuilder.AddToScheme )
Functions ¶
func GetOpenAPIDefinitions ¶
func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition
func GetProxierName ¶
GetProxierName returns proxier name from labels.
func RegisterDefaults ¶
RegisterDefaults adds defaulters functions to the given scheme. Public to allow building arbitrary schemes. All generated defaulters are covering - they call all nested defaulters.
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type BackendSpec ¶
type BackendSpec struct { // +kubebuilder:validation:MinLength=1 Name string `json:"name"` // +kubebuilder:validation:Minimum=1 Weight int32 `json:"weight"` Selector map[string]string `json:"selector,omitempty"` }
BackendSpec defines the target backend of Proxier
func (*BackendSpec) DeepCopy ¶
func (in *BackendSpec) DeepCopy() *BackendSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackendSpec.
func (*BackendSpec) DeepCopyInto ¶
func (in *BackendSpec) DeepCopyInto(out *BackendSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Protocol ¶
type Protocol string
Protocol defines network protocols supported for things like container ports.
type Proxier ¶
type Proxier struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec ProxierSpec `json:"spec,omitempty"` Status ProxierStatus `json:"status,omitempty"` }
Proxier is the Schema for the proxiers API +genclient +k8s:openapi-gen=true +kubebuilder:subresource:status
func (*Proxier) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Proxier.
func (*Proxier) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Proxier) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ProxierList ¶
type ProxierList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []Proxier `json:"items"` }
ProxierList contains a list of Proxier
func (*ProxierList) DeepCopy ¶
func (in *ProxierList) DeepCopy() *ProxierList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxierList.
func (*ProxierList) DeepCopyInto ¶
func (in *ProxierList) DeepCopyInto(out *ProxierList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ProxierList) DeepCopyObject ¶
func (in *ProxierList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ProxierPort ¶
type ProxierPort struct { // The name of this port within the proxier. This must be a DNS_LABEL. // All ports within a ServiceSpec must have unique names. This maps to // the 'Name' field in EndpointPort objects. // Optional if only one ProxierPort is defined on this service. // +required Name string `json:"name,omitempty"` // The IP protocol for this port. Supports "TCP", "UDP". // Default is TCP. // +optional Protocol Protocol `json:"protocol,omitempty"` // The port that will be exposed by this proxier Port int32 `json:"port"` // +optional TargetPort intstr.IntOrString `json:"targetPort,omitempty"` }
ProxierPort contains information on proxier's port.
func (*ProxierPort) DeepCopy ¶
func (in *ProxierPort) DeepCopy() *ProxierPort
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxierPort.
func (*ProxierPort) DeepCopyInto ¶
func (in *ProxierPort) DeepCopyInto(out *ProxierPort)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProxierSpec ¶
type ProxierSpec struct { // +kubebuilder:validation:MinItems=1 Backends []BackendSpec `json:"backends"` Selector map[string]string `json:"selector,omitempty"` Ports []ProxierPort `json:"ports"` }
ProxierSpec defines the desired state of Proxier +k8s:openapi-gen=true
func (*ProxierSpec) DeepCopy ¶
func (in *ProxierSpec) DeepCopy() *ProxierSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxierSpec.
func (*ProxierSpec) DeepCopyInto ¶
func (in *ProxierSpec) DeepCopyInto(out *ProxierSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProxierStatus ¶
type ProxierStatus struct { // ActiveBackends stores the count of current active services, which are required by the current // proxier spec. // +optional ActiveBackends int32 `json:"activeBackends,omitempty"` // ObsoleteBackends stores the count of obsolete services, which should be removed in controller // +optional ObsoleteBackends int32 `json:"obsoleteBackends,omitempty"` }
ProxierStatus defines the observed state of Proxier +k8s:openapi-gen=true
func (*ProxierStatus) DeepCopy ¶
func (in *ProxierStatus) DeepCopy() *ProxierStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxierStatus.
func (*ProxierStatus) DeepCopyInto ¶
func (in *ProxierStatus) DeepCopyInto(out *ProxierStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.