utils

package
v0.0.0-...-349559c Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	// WebhookServiceName is the webhook service name.
	WebhookServiceName = "e2e-test-webhook"
)

Variables

This section is empty.

Functions

func CleanWebhookTest

func CleanWebhookTest(client clientset.Interface, namespaceName string)

CleanWebhookTest cleans after a webhook test.

func CreateAuthReaderRoleBinding

func CreateAuthReaderRoleBinding(f *framework.Framework, namespace string)

CreateAuthReaderRoleBinding creates the role binding to allow the webhook read the extension-apiserver-authentication configmap.

func CreateWebhookConfigurationReadyNamespace

func CreateWebhookConfigurationReadyNamespace(f *framework.Framework)

CreateWebhookConfigurationReadyNamespace creates a separate namespace for webhook configuration ready markers to prevent cross-talk with webhook configurations being tested.

func DeployWebhookAndService

func DeployWebhookAndService(f *framework.Framework, image string, certContext *certContext, servicePort int32,
	containerPort int32, params ...string)

DeployWebhookAndService creates a webhook with a corresponding service.

func LabelNamespace

func LabelNamespace(f *framework.Framework, namespace string)

LabelNamespace applies unique label to the namespace.

func RegisterMutatingWebhookForPod

func RegisterMutatingWebhookForPod(f *framework.Framework, configName string, certContext *certContext, servicePort int32) func()

RegisterMutatingWebhookForPod creates mutation webhook configuration and applies it to the cluster.

func SetupWebhookCert

func SetupWebhookCert(namespaceName string) *certContext

SetupWebhookCert sets up the server cert. For example, user, apiservers and admission webhooks can use the cert to prove their identity to the kube-apiserver.

Types

This section is empty.

Jump to

Keyboard shortcuts

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