v1beta1

package
v0.1.0-rc2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 27, 2019 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package v1beta1 contains API Schema definitions for the core v1beta1 API group +k8s:openapi-gen=true +k8s:deepcopy-gen=package,register +k8s:conversion-gen=sigs.k8s.io/kubefed/pkg/apis/core +k8s:defaulter-gen=TypeMeta +groupName=core.kubefed.k8s.io

Package v1beta1 contains API Schema definitions for the core v1beta1 API group +k8s:openapi-gen=true +k8s:deepcopy-gen=package,register +k8s:conversion-gen=sigs.k8s.io/kubefed/pkg/apis/core +k8s:defaulter-gen=TypeMeta +groupName=core.kubefed.k8s.io

Index

Constants

This section is empty.

Variables

View Source
var (
	// SchemeGroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: "core.kubefed.k8s.io", Version: "v1beta1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}

	// AddToScheme is required by pkg/client/...
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

func PluralName

func PluralName(kind string) string

PluralName computes the plural name from the kind by lowercasing and suffixing with 's' or `es`.

func Resource

func Resource(resource string) schema.GroupResource

Resource is required by pkg/client/listers/...

func SetFederatedTypeConfigDefaults

func SetFederatedTypeConfigDefaults(obj *FederatedTypeConfig)

Types

type APIResource

type APIResource struct {

	// Group of the resource.
	// +optional
	Group string `json:"group,omitempty"`
	// Version of the resource.
	Version string `json:"version"`
	// Camel-cased singular name of the resource (e.g. ConfigMap)
	Kind string `json:"kind"`
	// Lower-cased plural name of the resource (e.g. configmaps).  If
	// not provided, it will be computed by lower-casing the kind and
	// suffixing an 's'.
	PluralName string `json:"pluralName"`
	// Scope of the resource.
	Scope apiextv1b1.ResourceScope `json:"scope"`
}

APIResource defines how to configure the dynamic client for an API resource.

func (*APIResource) DeepCopy

func (in *APIResource) DeepCopy() *APIResource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new APIResource.

func (*APIResource) DeepCopyInto

func (in *APIResource) DeepCopyInto(out *APIResource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*APIResource) Namespaced

func (a *APIResource) Namespaced() bool

type ClusterCondition

type ClusterCondition struct {
	// Type of cluster condition, Ready or Offline.
	Type common.ClusterConditionType `json:"type"`
	// Status of the condition, one of True, False, Unknown.
	Status apiv1.ConditionStatus `json:"status"`
	// Last time the condition was checked.
	LastProbeTime metav1.Time `json:"lastProbeTime"`
	// Last time the condition transit from one status to another.
	// +optional
	LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty"`
	// (brief) reason for the condition's last transition.
	// +optional
	Reason string `json:"reason,omitempty"`
	// Human readable message indicating details about last transition.
	// +optional
	Message string `json:"message,omitempty"`
}

ClusterCondition describes current state of a cluster.

func (*ClusterCondition) DeepCopy

func (in *ClusterCondition) DeepCopy() *ClusterCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterCondition.

func (*ClusterCondition) DeepCopyInto

func (in *ClusterCondition) DeepCopyInto(out *ClusterCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ClusterHealthCheckConfig

type ClusterHealthCheckConfig struct {
	// How often to monitor the cluster health (in seconds).
	PeriodSeconds int64 `json:"periodSeconds"`
	// Minimum consecutive failures for the cluster health to be considered failed after having succeeded.
	FailureThreshold int64 `json:"failureThreshold"`
	// Minimum consecutive successes for the cluster health to be considered successful after having failed.
	SuccessThreshold int64 `json:"successThreshold"`
	// Number of seconds after which the cluster health check times out.
	TimeoutSeconds int64 `json:"timeoutSeconds"`
}

func (*ClusterHealthCheckConfig) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterHealthCheckConfig.

func (*ClusterHealthCheckConfig) DeepCopyInto

func (in *ClusterHealthCheckConfig) DeepCopyInto(out *ClusterHealthCheckConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ConfigurationMode

type ConfigurationMode string
const (
	ConfigurationEnabled  ConfigurationMode = "Enabled"
	ConfigurationDisabled ConfigurationMode = "Disabled"
)

type ControllerStatus

type ControllerStatus string

ControllerStatus defines the current state of the controller

const (
	// ControllerStatusRunning means controller is in "running" state
	ControllerStatusRunning ControllerStatus = "Running"
	// ControllerStatusNotRunning means controller is in "notrunning" state
	ControllerStatusNotRunning ControllerStatus = "NotRunning"
)

type DurationConfig

type DurationConfig struct {
	// Time to wait before reconciling on a healthy cluster.
	AvailableDelay metav1.Duration `json:"availableDelay"`
	// Time to wait before giving up on an unhealthy cluster.
	UnavailableDelay metav1.Duration `json:"unavailableDelay"`
}

func (*DurationConfig) DeepCopy

func (in *DurationConfig) DeepCopy() *DurationConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DurationConfig.

func (*DurationConfig) DeepCopyInto

func (in *DurationConfig) DeepCopyInto(out *DurationConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FeatureGatesConfig

type FeatureGatesConfig struct {
	Name          string            `json:"name"`
	Configuration ConfigurationMode `json:"configuration"`
}

func (*FeatureGatesConfig) DeepCopy

func (in *FeatureGatesConfig) DeepCopy() *FeatureGatesConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureGatesConfig.

func (*FeatureGatesConfig) DeepCopyInto

func (in *FeatureGatesConfig) DeepCopyInto(out *FeatureGatesConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FederatedTypeConfig

type FederatedTypeConfig struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec FederatedTypeConfigSpec `json:"spec"`
	// +optional
	Status FederatedTypeConfigStatus `json:"status,omitempty"`
}

FederatedTypeConfig programs federation to know about a single API type - the "target type" - that a user wants to federate. For each target type, there is a corresponding FederatedType that has the following fields:

  • The "template" field specifies the basic definition of a federated resource
  • The "placement" field specifies the placement information for the federated resource
  • The "overrides" field specifies how the target resource should vary across clusters.

+k8s:openapi-gen=true +kubebuilder:resource:path=federatedtypeconfigs +kubebuilder:subresource:status

func (*FederatedTypeConfig) DeepCopy

func (in *FederatedTypeConfig) DeepCopy() *FederatedTypeConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedTypeConfig.

func (*FederatedTypeConfig) DeepCopyInto

func (in *FederatedTypeConfig) DeepCopyInto(out *FederatedTypeConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FederatedTypeConfig) DeepCopyObject

func (in *FederatedTypeConfig) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*FederatedTypeConfig) GetFederatedNamespaced

func (f *FederatedTypeConfig) GetFederatedNamespaced() bool

TODO(font): This method should be removed from the interface i.e. remove special-case handling for namespaces, in favor of checking the namespaced property of the appropriate APIResource (TargetType, FederatedType) depending on context.

func (*FederatedTypeConfig) GetFederatedType

func (f *FederatedTypeConfig) GetFederatedType() metav1.APIResource

func (*FederatedTypeConfig) GetNamespaced

func (f *FederatedTypeConfig) GetNamespaced() bool

TODO(font): This method should be removed from the interface in favor of checking the namespaced property of the appropriate APIResource (TargetType, FederatedType) depending on context.

func (*FederatedTypeConfig) GetObjectMeta

func (f *FederatedTypeConfig) GetObjectMeta() metav1.ObjectMeta

func (*FederatedTypeConfig) GetPropagationEnabled

func (f *FederatedTypeConfig) GetPropagationEnabled() bool

func (*FederatedTypeConfig) GetStatusEnabled

func (f *FederatedTypeConfig) GetStatusEnabled() bool

func (*FederatedTypeConfig) GetStatusType

func (f *FederatedTypeConfig) GetStatusType() *metav1.APIResource

func (*FederatedTypeConfig) GetTargetType

func (f *FederatedTypeConfig) GetTargetType() metav1.APIResource

func (*FederatedTypeConfig) IsNamespace

func (f *FederatedTypeConfig) IsNamespace() bool

type FederatedTypeConfigList

type FederatedTypeConfigList struct {
	metav1.TypeMeta `json:",inline"`
	// +optional
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []FederatedTypeConfig `json:"items"`
}

FederatedTypeConfigList contains a list of FederatedTypeConfig

func (*FederatedTypeConfigList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedTypeConfigList.

func (*FederatedTypeConfigList) DeepCopyInto

func (in *FederatedTypeConfigList) DeepCopyInto(out *FederatedTypeConfigList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FederatedTypeConfigList) DeepCopyObject

func (in *FederatedTypeConfigList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type FederatedTypeConfigSpec

type FederatedTypeConfigSpec struct {
	// The configuration of the target type. If not set, the pluralName and
	// groupName fields will be set from the metadata.name of this resource. The
	// kind field must be set.
	TargetType APIResource `json:"targetType"`
	// Whether or not propagation to member clusters should be enabled.
	Propagation PropagationMode `json:"propagation"`
	// Configuration for the federated type that defines (via
	// template, placement and overrides fields) how the target type
	// should appear in multiple cluster.
	FederatedType APIResource `json:"federatedType"`
	// Configuration for the status type that holds information about which type
	// holds the status of the federated resource. If not provided, the group
	// and version will default to those provided for the federated type api
	// resource.
	// +optional
	StatusType *APIResource `json:"statusType,omitempty"`
	// Whether or not Status object should be populated.
	// +optional
	StatusCollection *StatusCollectionMode `json:"statusCollection,omitempty"`
}

FederatedTypeConfigSpec defines the desired state of FederatedTypeConfig.

func (*FederatedTypeConfigSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedTypeConfigSpec.

func (*FederatedTypeConfigSpec) DeepCopyInto

func (in *FederatedTypeConfigSpec) DeepCopyInto(out *FederatedTypeConfigSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FederatedTypeConfigStatus

type FederatedTypeConfigStatus struct {
	// ObservedGeneration is the generation as observed by the controller consuming the FederatedTypeConfig.
	ObservedGeneration int64 `json:"observedGeneration"`
	// PropagationController tracks the status of the sync controller.
	PropagationController ControllerStatus `json:"propagationController"`
	// StatusController tracks the status of the status controller.
	// +optional
	StatusController *ControllerStatus `json:"statusController,omitempty"`
}

FederatedTypeConfigStatus defines the observed state of FederatedTypeConfig

func (*FederatedTypeConfigStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedTypeConfigStatus.

func (*FederatedTypeConfigStatus) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type KubeFedCluster

type KubeFedCluster struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   KubeFedClusterSpec   `json:"spec,omitempty"`
	Status KubeFedClusterStatus `json:"status,omitempty"`
}

KubeFedCluster configures federation to be aware of a Kubernetes cluster and provides a Kubeconfig for federation to use to communicate with the cluster.

+k8s:openapi-gen=true +kubebuilder:resource:path=kubefedclusters +kubebuilder:subresource:status +kubebuilder:printcolumn:name=ready,type=string,JSONPath=.status.conditions[?(@.type=='Ready')].status +kubebuilder:printcolumn:name=age,type=date,JSONPath=.metadata.creationTimestamp

func (*KubeFedCluster) DeepCopy

func (in *KubeFedCluster) DeepCopy() *KubeFedCluster

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeFedCluster.

func (*KubeFedCluster) DeepCopyInto

func (in *KubeFedCluster) DeepCopyInto(out *KubeFedCluster)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KubeFedCluster) DeepCopyObject

func (in *KubeFedCluster) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type KubeFedClusterList

type KubeFedClusterList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []KubeFedCluster `json:"items"`
}

KubeFedClusterList contains a list of KubeFedCluster

func (*KubeFedClusterList) DeepCopy

func (in *KubeFedClusterList) DeepCopy() *KubeFedClusterList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeFedClusterList.

func (*KubeFedClusterList) DeepCopyInto

func (in *KubeFedClusterList) DeepCopyInto(out *KubeFedClusterList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KubeFedClusterList) DeepCopyObject

func (in *KubeFedClusterList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type KubeFedClusterSpec

type KubeFedClusterSpec struct {
	// The API endpoint of the member cluster. This can be a hostname,
	// hostname:port, IP or IP:port.
	APIEndpoint string `json:"apiEndpoint"`

	// CABundle contains the certificate authority information.
	// +optional
	CABundle []byte `json:"caBundle,omitempty"`

	// Name of the secret containing the token required to access the
	// member cluster. The secret needs to exist in the same namespace
	// as the control plane and should have a "token" key.
	SecretRef LocalSecretReference `json:"secretRef"`
}

KubeFedClusterSpec defines the desired state of KubeFedCluster

func (*KubeFedClusterSpec) DeepCopy

func (in *KubeFedClusterSpec) DeepCopy() *KubeFedClusterSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeFedClusterSpec.

func (*KubeFedClusterSpec) DeepCopyInto

func (in *KubeFedClusterSpec) DeepCopyInto(out *KubeFedClusterSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type KubeFedClusterStatus

type KubeFedClusterStatus struct {
	// Conditions is an array of current cluster conditions.
	Conditions []ClusterCondition `json:"conditions"`
	// Zones are the names of availability zones in which the nodes of the cluster exist, e.g. 'us-east1-a'.
	// +optional
	Zones []string `json:"zones,omitempty"`
	// Region is the name of the region in which all of the nodes in the cluster exist.  e.g. 'us-east1'.
	// +optional
	Region string `json:"region,omitempty"`
}

KubeFedClusterStatus contains information about the current status of a cluster updated periodically by cluster controller.

func (*KubeFedClusterStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeFedClusterStatus.

func (*KubeFedClusterStatus) DeepCopyInto

func (in *KubeFedClusterStatus) DeepCopyInto(out *KubeFedClusterStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type KubeFedConfig

type KubeFedConfig struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec KubeFedConfigSpec `json:"spec"`
}

KubeFedConfig +k8s:openapi-gen=true +kubebuilder:resource:path=kubefedconfigs

func (*KubeFedConfig) DeepCopy

func (in *KubeFedConfig) DeepCopy() *KubeFedConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeFedConfig.

func (*KubeFedConfig) DeepCopyInto

func (in *KubeFedConfig) DeepCopyInto(out *KubeFedConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KubeFedConfig) DeepCopyObject

func (in *KubeFedConfig) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type KubeFedConfigList

type KubeFedConfigList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []KubeFedConfig `json:"items"`
}

KubeFedConfigList contains a list of KubeFedConfig

func (*KubeFedConfigList) DeepCopy

func (in *KubeFedConfigList) DeepCopy() *KubeFedConfigList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeFedConfigList.

func (*KubeFedConfigList) DeepCopyInto

func (in *KubeFedConfigList) DeepCopyInto(out *KubeFedConfigList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KubeFedConfigList) DeepCopyObject

func (in *KubeFedConfigList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type KubeFedConfigSpec

type KubeFedConfigSpec struct {
	// The scope of the kubefed control plane should be either `Namespaced` or `Cluster`.
	// `Namespaced` indicates that the kubefed namespace will be the only target for federation.
	Scope              apiextv1b1.ResourceScope `json:"scope"`
	ControllerDuration DurationConfig           `json:"controllerDuration"`
	LeaderElect        LeaderElectConfig        `json:"leaderElect"`
	FeatureGates       []FeatureGatesConfig     `json:"featureGates"`
	ClusterHealthCheck ClusterHealthCheckConfig `json:"clusterHealthCheck"`
	SyncController     SyncControllerConfig     `json:"syncController"`
}

KubeFedConfigSpec defines the desired state of KubeFedConfig

func (*KubeFedConfigSpec) DeepCopy

func (in *KubeFedConfigSpec) DeepCopy() *KubeFedConfigSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeFedConfigSpec.

func (*KubeFedConfigSpec) DeepCopyInto

func (in *KubeFedConfigSpec) DeepCopyInto(out *KubeFedConfigSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LeaderElectConfig

type LeaderElectConfig struct {
	// The duration that non-leader candidates will wait after observing a leadership
	// renewal until attempting to acquire leadership of a led but unrenewed leader
	// slot. This is effectively the maximum duration that a leader can be stopped
	// before it is replaced by another candidate. This is only applicable if leader
	// election is enabled.
	LeaseDuration metav1.Duration `json:"leaseDuration"`
	// The interval between attempts by the acting master to renew a leadership slot
	// before it stops leading. This must be less than or equal to the lease duration.
	// This is only applicable if leader election is enabled.
	RenewDeadline metav1.Duration `json:"renewDeadline"`
	// The duration the clients should wait between attempting acquisition and renewal
	// of a leadership. This is only applicable if leader election is enabled.
	RetryPeriod metav1.Duration `json:"retryPeriod"`
	// The type of resource object that is used for locking during
	// leader election. Supported options are `configmaps` (default) and `endpoints`.
	ResourceLock ResourceLockType `json:"resourceLock"`
}

func (*LeaderElectConfig) DeepCopy

func (in *LeaderElectConfig) DeepCopy() *LeaderElectConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LeaderElectConfig.

func (*LeaderElectConfig) DeepCopyInto

func (in *LeaderElectConfig) DeepCopyInto(out *LeaderElectConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LocalSecretReference

type LocalSecretReference struct {
	// Name of a secret within the enclosing
	// namespace
	Name string `json:"name"`
}

LocalSecretReference is a reference to a secret within the enclosing namespace.

func (*LocalSecretReference) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalSecretReference.

func (*LocalSecretReference) DeepCopyInto

func (in *LocalSecretReference) DeepCopyInto(out *LocalSecretReference)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PropagationMode

type PropagationMode string

PropagationMode defines the state of propagation to member clusters.

const (
	PropagationEnabled  PropagationMode = "Enabled"
	PropagationDisabled PropagationMode = "Disabled"
)

type ResourceAdoption

type ResourceAdoption string
const (
	AdoptResourcesEnabled  ResourceAdoption = "Enabled"
	AdoptResourcesDisabled ResourceAdoption = "Disabled"
)

type ResourceLockType

type ResourceLockType string
const (
	ConfigMapsResourceLock ResourceLockType = "configmaps"
	EndpointsResourceLock  ResourceLockType = "endpoints"
)

type StatusCollectionMode

type StatusCollectionMode string

StatusCollectionMode defines the state of status collection.

const (
	StatusCollectionEnabled  StatusCollectionMode = "Enabled"
	StatusCollectionDisabled StatusCollectionMode = "Disabled"
)

type SyncControllerConfig

type SyncControllerConfig struct {
	// Whether to adopt pre-existing resources in member clusters. Defaults to
	// "Enabled".
	AdoptResources ResourceAdoption `json:"adoptResources"`
}

func (*SyncControllerConfig) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SyncControllerConfig.

func (*SyncControllerConfig) DeepCopyInto

func (in *SyncControllerConfig) DeepCopyInto(out *SyncControllerConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL