webhook

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	// ClientConfig is the WebhookClientCert that contains the information to generate
	// the certificate. The CA Certificate will be updated in the ClientConfig.
	// The updated ClientConfig will be used to inject into other runtime.Objects,
	// e.g. MutatingWebhookConfiguration and ValidatingWebhookConfiguration.
	ClientConfig *admissionregistrationv1.WebhookClientConfig
	// Objects are the objects that will use the ClientConfig above.
	Objects []client.Object
}

Options are options for provisioning the certificate.

type Provisioner

type Provisioner struct {
	// CertWriter knows how to persist the certificate.
	CertWriter writer.CertWriter
}

Provisioner provisions certificates for webhook configurations and writes them to an output destination - such as a Secret or local file. Provisioner can update the CA field of certain resources with the CA of the certs.

func (*Provisioner) Provision

func (cp *Provisioner) Provision(ctx context.Context, options Options) (bool, error)

Provision provisions certificates for the WebhookClientConfig. It ensures the cert and CA are valid and not expiring. It updates the CABundle in the webhookClientConfig if necessary. It inject the WebhookClientConfig into options.Objects.

Directories

Path Synopsis
NOTE: This package originates from controller-runtime v0.1.
NOTE: This package originates from controller-runtime v0.1.
NOTE: This package originates from controller-runtime v0.1.
NOTE: This package originates from controller-runtime v0.1.

Jump to

Keyboard shortcuts

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