Help us shape the future of Go! Take the 2026 Go Developer Survey

cmapichecker

package
v1.21.3 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2026 License: Apache-2.0 Imports: 13 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrCertManagerCRDsNotFound   = fmt.Errorf("the cert-manager CRDs are not yet installed on the Kubernetes API server")
	ErrWebhookServiceFailure     = fmt.Errorf("the cert-manager webhook service is not created yet")
	ErrWebhookDeploymentFailure  = fmt.Errorf("the cert-manager webhook deployment is not ready yet")
	ErrWebhookCertificateFailure = fmt.Errorf("the cert-manager webhook CA bundle is not injected yet")
	ErrMutationWebhookMissing    = fmt.Errorf("the cert-manager mutation webhook did not mutate the dry-run CertificateRequest object")
	ErrValidatingWebhookMissing  = fmt.Errorf("the cert-manager validating webhook did not validate the dry-run CertificateRequest object")
	ErrMutationWebhookIncorrect  = fmt.Errorf("the cert-manager validating webhook failed because the dry-run CertificateRequest object was mutated incorrectly")

	ErrFailedToCheckAPI = fmt.Errorf("failed to check the cert-manager API")
)

Functions

func TranslateToSimpleError added in v1.13.0

func TranslateToSimpleError(err error) error

TranslateToSimpleError detects errors based on the error message. It tries to map these error messages to a better understandable error message that explains what is wrong. If it cannot create a simple error, it will return nil. ErrCertManagerCRDsNotFound: - error finding the scope of the object: failed to get restmapping: no matches for kind "Certificate" in group "cert-manager.io" ErrWebhookServiceFailure: - Internal error occurred: failed calling webhook "webhook.cert-manager.io": Post "https://cert-manager-webhook.cert-manager.svc:443/mutate?timeout=10s": service "cert-manager-webhook" not found ErrWebhookDeploymentFailure: - Internal error occurred: failed calling webhook "webhook.cert-manager.io": Post "https://cert-manager-webhook.cert-manager.svc:443/mutate?timeout=10s": dial tcp 10.96.38.90:443: connect: connection refused ErrWebhookCertificateFailure: - Internal error occurred: failed calling webhook "webhook.cert-manager.io": Post "https://cert-manager-webhook.cert-manager.svc:443/mutate?timeout=10s": x509: certificate signed by unknown authority (possibly because of "x509: ECDSA verification failure" while trying to verify candidate authority certificate "cert-manager-webhook-ca") ErrMutationWebhookIncorrect: - admission webhook "webhook.cert-manager.io" denied the request: [spec.username: Forbidden: username identity must be that of the requester, spec.groups: Forbidden: groups identity must be that of the requester] ErrFailedToCheckAPI: - certificaterequests.cert-manager.io is forbidden: User "test" cannot create resource "certificaterequests" in API group "cert-manager.io" in the namespace "default" - admission webhook "validate.kyverno.svc-fail" denied the request: ...

Types

type Interface

type Interface interface {
	Check(context.Context) error
}

Interface is used to check that the cert-manager CRDs have been installed and are usable.

func New

func New(restcfg *rest.Config, namespace string) (Interface, error)

New returns a cert-manager API checker

func NewForConfigAndClient added in v1.16.0

func NewForConfigAndClient(restcfg *rest.Config, httpClient *http.Client, namespace string) (Interface, error)

Jump to

Keyboard shortcuts

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