Documentation ¶
Overview ¶
Package v1 is the v1 version of the API. +groupName=jinghzhu.io
Index ¶
Constants ¶
const ( // Kind is normally the CamelCased singular type. The resource manifest uses this. Kind string = "Jinghzhu" // GroupVersion is the version. GroupVersion string = "v1" // Plural is the plural name used in /apis/<group>/<version>/<plural> Plural string = "jinghzhus" // Singular is used as an alias on kubectl for display. Singular string = "jinghzhu" // CRDName is the CRD name for Jinghzhu. CRDName string = Plural + "." + crdjinghzhu.GroupName // ShortName is the short alias for the CRD. ShortName string = "jh" )
Variables ¶
var ( // SchemeGroupVersion is the group version used to register these objects. SchemeGroupVersion = schema.GroupVersion{ Group: crdjinghzhu.GroupName, Version: GroupVersion, } SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme )
Functions ¶
func CreateCustomResourceDefinition ¶
func CreateCustomResourceDefinition(clientSet apiextensionsclientset.Interface) (*apiextensionsv1beta1.CustomResourceDefinition, error)
CreateCustomResourceDefinition creates the CRD and add it into Kubernetes. If there is error, it will do some clean up.
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type Jinghzhu ¶
type Jinghzhu struct { metav1.TypeMeta `json:",inline"` // Standard object's metadata. metav1.ObjectMeta `json:"metadata"` // Specification of the desired behavior of Jinghzhu. Spec JinghzhuSpec `json:"spec"` // Observed status of Jinghzhu. Status JinghzhuStatus `json:"status"` }
Jinghzhu is the CRD. Use this command to generate deepcopy for it: ./k8s.io/code-generator/generate-groups.sh all github.com/jinghzhu/KubernetesCRD/pkg/crd/jinghzhu/v1/apis github.com/jinghzhu/KubernetesCRD/pkg/crd "jinghzhu:v1" For more details of code-generator, please visit https://github.com/kubernetes/code-generator +genclient +genclient:noStatus +k8s:deepcopy-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +resource:path=jinghzhu
func (*Jinghzhu) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Jinghzhu.
func (*Jinghzhu) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Jinghzhu) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type JinghzhuList ¶
type JinghzhuList struct { metav1.TypeMeta `json:",inline"` // Standard list metadata. metav1.ListMeta `json:"metadata"` // List of Jinghzhus. Items []Jinghzhu `json:"items"` }
JinghzhuList is the list of Jinghzhus. +k8s:deepcopy-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +resource:path=jinghzhu
func (*JinghzhuList) DeepCopy ¶
func (in *JinghzhuList) DeepCopy() *JinghzhuList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new JinghzhuList.
func (*JinghzhuList) DeepCopyInto ¶
func (in *JinghzhuList) DeepCopyInto(out *JinghzhuList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*JinghzhuList) DeepCopyObject ¶
func (in *JinghzhuList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type JinghzhuSpec ¶
type JinghzhuSpec struct { // Desired is the desired Pod number. Desired int `json:"desired"` // Current is the number of Pod currently running. Current int `json:"current"` // PodList is the name list of current Pods. PodList []string `json:"podList"` }
JinghzhuSpec is a desired state description of Jinghzhu. +k8s:deepcopy-gen=true
func (*JinghzhuSpec) DeepCopy ¶
func (in *JinghzhuSpec) DeepCopy() *JinghzhuSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new JinghzhuSpec.
func (*JinghzhuSpec) DeepCopyInto ¶
func (in *JinghzhuSpec) DeepCopyInto(out *JinghzhuSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type JinghzhuStatus ¶
JinghzhuStatus describes the lifecycle status of Jinghzhu.
func (*JinghzhuStatus) DeepCopy ¶
func (in *JinghzhuStatus) DeepCopy() *JinghzhuStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new JinghzhuStatus.
func (*JinghzhuStatus) DeepCopyInto ¶
func (in *JinghzhuStatus) DeepCopyInto(out *JinghzhuStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
Directories ¶
Path | Synopsis |
---|---|
apis
|
|
clientset/versioned
This package has the automatically generated clientset.
|
This package has the automatically generated clientset. |
clientset/versioned/fake
This package has the automatically generated fake clientset.
|
This package has the automatically generated fake clientset. |
clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
|
This package contains the scheme of the automatically generated clientset. |
clientset/versioned/typed/jinghzhu/v1
This package has the automatically generated typed clients.
|
This package has the automatically generated typed clients. |
clientset/versioned/typed/jinghzhu/v1/fake
Package fake has the automatically generated clients.
|
Package fake has the automatically generated clients. |