Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Interfaces ¶
type Interfaces interface { DynamicInterface(gv schema.GroupVersion, kind string, listKind string) (dynamic.Interface, error) APIExtensionsClientset() (clientset.Interface, error) }
Interfaces interface allows access to the Kubernetes API Service methods. It is mainly used for test/injection purposes.
func NewKube ¶
func NewKube(cfg *rest.Config) Interfaces
NewKube returns a new instance of Interfaces.
func NewKubeFromConfigFile ¶
func NewKubeFromConfigFile(kubeconfig string) (Interfaces, error)
NewKubeFromConfigFile returns a new instance of Interfaces.
type ResourceSpec ¶
type ResourceSpec struct { // Singular name of the K8s resource Singular string // Plural name of the K8s resource Plural string // Group name of the K8s resource Group string // Version of the K8s resource Version string // Kind of the K8s resource Kind string // ListKind of the K8s resource ListKind string // Target resource type of the resource Target resource.Info // The converter to use Converter converter.Fn }
ResourceSpec represents a known crd. It is used to drive the K8s-related machinery, and to map to the proto format.
func (*ResourceSpec) APIResource ¶
func (i *ResourceSpec) APIResource() *v1.APIResource
APIResource generated from this type.
func (*ResourceSpec) CanonicalResourceName ¶
func (i *ResourceSpec) CanonicalResourceName() string
CanonicalResourceName of the resource.
func (*ResourceSpec) GroupVersion ¶
func (i *ResourceSpec) GroupVersion() sc.GroupVersion
GroupVersion returns the GroupVersion of this type.
type Schema ¶
type Schema struct {
// contains filtered or unexported fields
}
Schema represents a set of known Kubernetes resource types.
func (*Schema) All ¶
func (e *Schema) All() []ResourceSpec
All returns information about all known types.
type SchemaBuilder ¶
type SchemaBuilder struct {
// contains filtered or unexported fields
}
SchemaBuilder is a builder for schema.
func NewSchemaBuilder ¶
func NewSchemaBuilder() *SchemaBuilder
NewSchemaBuilder returns a new instance of a SchemaBuilder.
func (*SchemaBuilder) Add ¶
func (b *SchemaBuilder) Add(entry ResourceSpec)
Add a new ResourceSpec to the schema.
func (*SchemaBuilder) Build ¶
func (b *SchemaBuilder) Build() *Schema
Build a new instance of schema.