resourcesynccontroller

package
v0.0.0-...-6401c32 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2019 License: Apache-2.0 Imports: 23 Imported by: 61

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CombineCABundleConfigMaps

func CombineCABundleConfigMaps(destinationConfigMap ResourceLocation, lister corev1listers.ConfigMapLister, client corev1client.ConfigMapsGetter, recorder events.Recorder, inputConfigMaps ...ResourceLocation) (*corev1.ConfigMap, error)

Types

type ResourceLocation

type ResourceLocation struct {
	Namespace string
	Name      string
}

ResourceLocation describes coordinates for a resource to be synced

type ResourceSyncController

type ResourceSyncController struct {
	// contains filtered or unexported fields
}

ResourceSyncController is a controller that will copy source configmaps and secrets to their destinations. It will also mirror deletions by deleting destinations.

func NewResourceSyncController

func NewResourceSyncController(
	operatorConfigClient v1helpers.OperatorClient,
	kubeInformersForNamespaces v1helpers.KubeInformersForNamespaces,
	kubeClient kubernetes.Interface,
	eventRecorder events.Recorder,
) *ResourceSyncController

NewResourceSyncController creates ResourceSyncController.

func (*ResourceSyncController) Run

func (c *ResourceSyncController) Run(workers int, stopCh <-chan struct{})

func (*ResourceSyncController) SyncConfigMap

func (c *ResourceSyncController) SyncConfigMap(destination, source ResourceLocation) error

func (*ResourceSyncController) SyncSecret

func (c *ResourceSyncController) SyncSecret(destination, source ResourceLocation) error

type ResourceSyncer

type ResourceSyncer interface {
	// SyncConfigMap indicates that a configmap should be copied from the source to the destination.  It will also
	// mirror a deletion from the source.  If the source is a zero object the destination will be deleted.
	SyncConfigMap(destination, source ResourceLocation) error
	// SyncSecret indicates that a secret should be copied from the source to the destination.  It will also
	// mirror a deletion from the source.  If the source is a zero object the destination will be deleted.
	SyncSecret(destination, source ResourceLocation) error
}

ResourceSyncer allows changes to syncing rules by this controller

Jump to

Keyboard shortcuts

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