Documentation
¶
Index ¶
- Constants
- func GetConfig() (*rest.Config, error)
- func GetOperatorName() (string, error)
- func GetWatchNamespace() (string, error)
- type Clients
- type ConfigOperatorClient
- func (c *ConfigOperatorClient) ApplyOperatorSpec(ctx context.Context, fieldManager string, ...) (err error)
- func (c *ConfigOperatorClient) ApplyOperatorStatus(ctx context.Context, fieldManager string, ...) (err error)
- func (c *ConfigOperatorClient) GetObjectMeta() (meta *metav1.ObjectMeta, err error)
- func (c *ConfigOperatorClient) GetOperatorState() (spec *operatorv1.OperatorSpec, status *operatorv1.OperatorStatus, ...)
- func (c *ConfigOperatorClient) GetOperatorStateWithQuorum(ctx context.Context) (spec *operatorv1.OperatorSpec, status *operatorv1.OperatorStatus, ...)
- func (c *ConfigOperatorClient) Informer() cache.SharedIndexInformer
- func (c *ConfigOperatorClient) PatchOperatorStatus(ctx context.Context, jsonPatch *jsonpatch.PatchSet) (err error)
- func (c *ConfigOperatorClient) UpdateOperatorSpec(ctx context.Context, oldResourceVersion string, in *operatorv1.OperatorSpec) (out *operatorv1.OperatorSpec, newResourceVersion string, err error)
- func (c *ConfigOperatorClient) UpdateOperatorStatus(ctx context.Context, oldResourceVersion string, in *operatorv1.OperatorStatus) (out *operatorv1.OperatorStatus, err error)
- type ImagePrunerControllerListers
- type Listers
- type StorageListers
Constants ¶
View Source
const ( // WatchNamespaceEnvVar is the constant for env variable WATCH_NAMESPACE // which is the namespace that the pod is currently running in. WatchNamespaceEnvVar = "WATCH_NAMESPACE" // OperatorNameEnvVar is the constant for env variable OPERATOR_NAME // which is the name of the current operator OperatorNameEnvVar = "OPERATOR_NAME" )
Variables ¶
This section is empty.
Functions ¶
func GetConfig ¶
GetConfig creates a *rest.Config for talking to a Kubernetes apiserver. Otherwise will assume running in cluster and use the cluster provided kubeconfig.
Config precedence ¶
* KUBECONFIG environment variable pointing at a file
* In-cluster config if running in cluster
* $HOME/.kube/config if exists
func GetOperatorName ¶
GetOperatorName return the operator name
func GetWatchNamespace ¶
GetWatchNamespace returns the namespace the operator should be watching for changes
Types ¶
type Clients ¶
type Clients struct { Kube kubeset.Interface Route routeset.RouteV1Interface Config configset.ConfigV1Interface RegOp regopset.Interface Core coreset.CoreV1Interface Apps appsset.AppsV1Interface RBAC rbacset.RbacV1Interface Batch batchset.BatchV1Interface Job jobset.BatchV1Interface }
type ConfigOperatorClient ¶
type ConfigOperatorClient struct {
// contains filtered or unexported fields
}
func NewConfigOperatorClient ¶
func NewConfigOperatorClient(client imageregistryv1client.ConfigInterface, informer imageregistryv1informers.ConfigInformer) *ConfigOperatorClient
func (*ConfigOperatorClient) ApplyOperatorSpec ¶
func (c *ConfigOperatorClient) ApplyOperatorSpec(ctx context.Context, fieldManager string, applyConfiguration *applyoperatorv1.OperatorSpecApplyConfiguration) (err error)
func (*ConfigOperatorClient) ApplyOperatorStatus ¶
func (c *ConfigOperatorClient) ApplyOperatorStatus(ctx context.Context, fieldManager string, applyConfiguration *applyoperatorv1.OperatorStatusApplyConfiguration) (err error)
func (*ConfigOperatorClient) GetObjectMeta ¶
func (c *ConfigOperatorClient) GetObjectMeta() (meta *metav1.ObjectMeta, err error)
func (*ConfigOperatorClient) GetOperatorState ¶
func (c *ConfigOperatorClient) GetOperatorState() (spec *operatorv1.OperatorSpec, status *operatorv1.OperatorStatus, resourceVersion string, err error)
func (*ConfigOperatorClient) GetOperatorStateWithQuorum ¶
func (c *ConfigOperatorClient) GetOperatorStateWithQuorum(ctx context.Context) (spec *operatorv1.OperatorSpec, status *operatorv1.OperatorStatus, resourceVersion string, err error)
GetOperatorStateWithQuorum implements v1helpers.OperatorClient.
func (*ConfigOperatorClient) Informer ¶
func (c *ConfigOperatorClient) Informer() cache.SharedIndexInformer
func (*ConfigOperatorClient) PatchOperatorStatus ¶
func (*ConfigOperatorClient) UpdateOperatorSpec ¶
func (c *ConfigOperatorClient) UpdateOperatorSpec(ctx context.Context, oldResourceVersion string, in *operatorv1.OperatorSpec) (out *operatorv1.OperatorSpec, newResourceVersion string, err error)
func (*ConfigOperatorClient) UpdateOperatorStatus ¶
func (c *ConfigOperatorClient) UpdateOperatorStatus(ctx context.Context, oldResourceVersion string, in *operatorv1.OperatorStatus) (out *operatorv1.OperatorStatus, err error)
type ImagePrunerControllerListers ¶
type ImagePrunerControllerListers struct { Jobs kjoblisters.JobNamespaceLister CronJobs kbatchlisters.CronJobNamespaceLister ServiceAccounts kcorelisters.ServiceAccountNamespaceLister ClusterRoles krbaclisters.ClusterRoleLister ClusterRoleBindings krbaclisters.ClusterRoleBindingLister RegistryConfigs regoplisters.ConfigLister ImagePrunerConfigs regoplisters.ImagePrunerLister ConfigMaps kcorelisters.ConfigMapNamespaceLister ImageConfigs configlisters.ImageLister }
type Listers ¶
type Listers struct { StorageListers Deployments kappslisters.DeploymentNamespaceLister Services kcorelisters.ServiceNamespaceLister ConfigMaps kcorelisters.ConfigMapNamespaceLister ServiceAccounts kcorelisters.ServiceAccountNamespaceLister PodDisruptionBudgets kpolicylisters.PodDisruptionBudgetNamespaceLister Routes routelisters.RouteNamespaceLister ClusterRoles krbaclisters.ClusterRoleLister ClusterRoleBindings krbaclisters.ClusterRoleBindingLister RegistryConfigs regoplisters.ConfigLister ProxyConfigs configlisters.ProxyLister }
type StorageListers ¶
type StorageListers struct { Infrastructures configlisters.InfrastructureLister OpenShiftConfig kcorelisters.ConfigMapNamespaceLister OpenShiftConfigManaged kcorelisters.ConfigMapNamespaceLister Secrets kcorelisters.SecretNamespaceLister }
StorageListers is a set of listers that can be used by storage drivers.
func NewStorageListers ¶
func NewStorageListers( infrastructures configlisters.InfrastructureLister, openshiftConfig kcorelisters.ConfigMapNamespaceLister, openshiftConfigManaged kcorelisters.ConfigMapNamespaceLister, secrets kcorelisters.SecretNamespaceLister, ) *StorageListers
Click to show internal directories.
Click to hide internal directories.