controller

package
v0.0.0-...-2d77b09 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2024 License: Apache-2.0 Imports: 39 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DefaultDNSController is the name of the default DNS instance.
	DefaultDNSController = "default"

	// DNSControllerFinalizer is applied to a DNS before being considered for processing;
	// this ensures the operator has a chance to handle all states.
	DNSControllerFinalizer = "dns.operator.openshift.io/dns-controller"
)
View Source
const (

	// MetricsServingCertAnnotation is the annotation needed to generate
	// the certificates for secure DNS metrics.
	MetricsServingCertAnnotation = "service.beta.openshift.io/serving-cert-secret-name"

	// DefaultOperandNamespace is the default namespace name of operands.
	DefaultOperandNamespace = "openshift-dns"

	// DefaultOperatorName is the default name of dns cluster operator.
	DefaultOperatorName = "dns"

	// DefaultDNSName is the default name of dns resource.
	DefaultDNSName = "default"

	DefaultOperatorNamespace = "openshift-dns-operator"

	ContainerNameOfDNSOperator = "dns-operator"

	DeploymentNameOfDNSOperator = "dns-operator"

	// GlobalUserSpecifiedConfigNamespace is the namespace for configuring OpenShift.
	GlobalUserSpecifiedConfigNamespace = "openshift-config"

	// DefaultDNSNameResolverNamespace is the namespace which contains all the DNSNameResolver resources.
	DefaultDNSNameResolverNamespace = "openshift-ovn-kubernetes"
)

Variables

This section is empty.

Functions

func CABundleConfigMapName

func CABundleConfigMapName(sourceName string) types.NamespacedName

CABundleConfigMapName returns the namespaced name for the dns ca bundle config map.

func DNSClusterOperatorName

func DNSClusterOperatorName() types.NamespacedName

DNSClusterOperatorName returns the namespaced name of the ClusterOperator resource for the operator.

func DNSConfigMapName

func DNSConfigMapName(dns *operatorv1.DNS) types.NamespacedName

func DNSDaemonSetLabel

func DNSDaemonSetLabel(dns *operatorv1.DNS) string

func DNSDaemonSetName

func DNSDaemonSetName(dns *operatorv1.DNS) types.NamespacedName

DNSDaemonSetName returns the namespaced name for the dns daemonset.

func DNSDaemonSetPodSelector

func DNSDaemonSetPodSelector(dns *operatorv1.DNS) *metav1.LabelSelector

func DNSMetricsSecretName

func DNSMetricsSecretName(dns *operatorv1.DNS) string

func DNSServiceMonitorName

func DNSServiceMonitorName(dns *operatorv1.DNS) types.NamespacedName

func DNSServiceName

func DNSServiceName(dns *operatorv1.DNS) types.NamespacedName

func DefaultDNSNamespaceName

func DefaultDNSNamespaceName() types.NamespacedName

DefaultDNSNamespaceName returns the namespaced name of the default DNS resource.

func DefaultDNSOperandNamespaceName

func DefaultDNSOperandNamespaceName() types.NamespacedName

DefaultDNSOperandNamespaceName returns the namespaced name of the default DNS operand resource.

func DefaultDNSOperatorDeploymentName

func DefaultDNSOperatorDeploymentName() types.NamespacedName

func New

func New(mgr manager.Manager, config Config) (controller.Controller, error)

New creates the operator controller from configuration. This is the controller that handles all the logic for implementing dns based on DNS resources.

The controller will be pre-configured to watch for DNS resources.

func NodeResolverDaemonSetName

func NodeResolverDaemonSetName() types.NamespacedName

NodeResolverDaemonSetName returns the namespaced name for the node resolver daemonset.

func NodeResolverDaemonSetPodSelector

func NodeResolverDaemonSetPodSelector() *metav1.LabelSelector

NodeResolverDaemonSetPodSelector is label selector for node resolver pods.

Types

type Config

type Config struct {
	// DNSNameResolverEnabled indicates that the "DNSNameResolver" featuregate is enabled.
	DNSNameResolverEnabled bool
	// DNSNameResolverNamespaces are the namespaces which will be watched for the
	// DNSNameResolver resources and updated by the CoreDNS pods if the "DNSNameResolver"
	// featuregate is enabled.
	DNSNameResolverNamespaces []string

	operatorconfig.Config
}

Config holds all the configuration that must be provided when creating the controller.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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