kubeobjects

package
v0.4.1-helm Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2022 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const AnnotationHash = "internal.operator.dynatrace.com/template-hash"

Variables

This section is empty.

Functions

func AffinityNodeRequirement

func AffinityNodeRequirement() []corev1.NodeSelectorRequirement

func AffinityNodeRequirementWithARM64

func AffinityNodeRequirementWithARM64() []corev1.NodeSelectorRequirement

func CheckIfOneAgentAPMExists

func CheckIfOneAgentAPMExists(cfg *rest.Config) (bool, error)

CheckIfOneAgentAPMExists checks if a OneAgentAPM object exists

func CreateEmptySecret

func CreateEmptySecret(name string, namespace string) *corev1.Secret

func CreateOrUpdateDaemonSet

func CreateOrUpdateDaemonSet(c client.Client, logger logr.Logger, desiredDs *appsv1.DaemonSet) (bool, error)

func CreateOrUpdateSecretIfNotExists

func CreateOrUpdateSecretIfNotExists(c client.Client, r client.Reader, secretName string, targetNS string, data map[string][]byte, secretType corev1.SecretType, log logr.Logger) (bool, error)

CreateOrUpdateSecretIfNotExists creates a secret in case it does not exist or updates it if there are changes

func ExtractToken

func ExtractToken(secret *corev1.Secret, key string) (string, error)

func GenerateHash

func GenerateHash(ds interface{}) (string, error)

func GetDeployment

func GetDeployment(c client.Client, podName, namespace string) (*appsv1.Deployment, error)

GetDeployment returns the Deployment object who is the owner of this pod.

func GetField

func GetField(values map[string]string, key string, defaultValue string) string

func GetFieldBool

func GetFieldBool(values map[string]string, key string, defaultValue bool) bool

func GetSecret

func GetSecret(ctx context.Context, apiReader client.Reader, name string, namespace string) (*corev1.Secret, error)

func HasChanged

func HasChanged(a, b metav1.Object) bool

func MergeLabels

func MergeLabels(labels ...map[string]string) map[string]string

Types

type Tokens

type Tokens struct {
	ApiToken  string
	PaasToken string
}

func NewTokens

func NewTokens(secret *corev1.Secret) (*Tokens, error)

Jump to

Keyboard shortcuts

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