kubernetes_asyncio.client.models.v1_validating_webhook module

Kubernetes

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501

The version of the OpenAPI document: v1.34.3 Generated by: https://openapi-generator.tech

class kubernetes_asyncio.client.models.v1_validating_webhook.V1ValidatingWebhook(admission_review_versions=None, client_config=None, failure_policy=None, match_conditions=None, match_policy=None, name=None, namespace_selector=None, object_selector=None, rules=None, side_effects=None, timeout_seconds=None, local_vars_configuration=None)

Bases: object

NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech

Do not edit the class manually.

property admission_review_versions

Gets the admission_review_versions of this V1ValidatingWebhook. # noqa: E501

AdmissionReviewVersions is an ordered list of preferred AdmissionReview versions the Webhook expects. API server will try to use first version in the list which it supports. If none of the versions specified in this list supported by API server, validation will fail for this object. If a persisted webhook configuration specifies allowed versions and does not include any versions known to the API Server, calls to the webhook will fail and be subject to the failure policy. # noqa: E501

Returns:

The admission_review_versions of this V1ValidatingWebhook. # noqa: E501

Return type:

list[str]

attribute_map = {'admission_review_versions': 'admissionReviewVersions', 'client_config': 'clientConfig', 'failure_policy': 'failurePolicy', 'match_conditions': 'matchConditions', 'match_policy': 'matchPolicy', 'name': 'name', 'namespace_selector': 'namespaceSelector', 'object_selector': 'objectSelector', 'rules': 'rules', 'side_effects': 'sideEffects', 'timeout_seconds': 'timeoutSeconds'}
property client_config

Gets the client_config of this V1ValidatingWebhook. # noqa: E501

Returns:

The client_config of this V1ValidatingWebhook. # noqa: E501

Return type:

AdmissionregistrationV1WebhookClientConfig

property failure_policy

Gets the failure_policy of this V1ValidatingWebhook. # noqa: E501

FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Fail. # noqa: E501

Returns:

The failure_policy of this V1ValidatingWebhook. # noqa: E501

Return type:

str

property match_conditions

Gets the match_conditions of this V1ValidatingWebhook. # noqa: E501

MatchConditions is a list of conditions that must be met for a request to be sent to this webhook. Match conditions filter requests that have already been matched by the rules, namespaceSelector, and objectSelector. An empty list of matchConditions matches all requests. There are a maximum of 64 match conditions allowed. The exact matching logic is (in order): 1. If ANY matchCondition evaluates to FALSE, the webhook is skipped. 2. If ALL matchConditions evaluate to TRUE, the webhook is called. 3. If any matchCondition evaluates to an error (but none are FALSE): - If failurePolicy=Fail, reject the request - If failurePolicy=Ignore, the error is ignored and the webhook is skipped # noqa: E501

Returns:

The match_conditions of this V1ValidatingWebhook. # noqa: E501

Return type:

list[V1MatchCondition]

property match_policy

Gets the match_policy of this V1ValidatingWebhook. # noqa: E501

matchPolicy defines how the “rules” list is used to match incoming requests. Allowed values are “Exact” or “Equivalent”. - Exact: match a request only if it exactly matches a specified rule. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, but “rules” only included apiGroups:[“apps”], apiVersions:[“v1”], resources: [“deployments”], a request to apps/v1beta1 or extensions/v1beta1 would not be sent to the webhook. - Equivalent: match a request if modifies a resource listed in rules, even via another API group or version. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, and “rules” only included apiGroups:[“apps”], apiVersions:[“v1”], resources: [“deployments”], a request to apps/v1beta1 or extensions/v1beta1 would be converted to apps/v1 and sent to the webhook. Defaults to “Equivalent” # noqa: E501

Returns:

The match_policy of this V1ValidatingWebhook. # noqa: E501

Return type:

str

property name

Gets the name of this V1ValidatingWebhook. # noqa: E501

The name of the admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where “imagepolicy” is the name of the webhook, and kubernetes.io is the name of the organization. Required. # noqa: E501

Returns:

The name of this V1ValidatingWebhook. # noqa: E501

Return type:

str

property namespace_selector

Gets the namespace_selector of this V1ValidatingWebhook. # noqa: E501

Returns:

The namespace_selector of this V1ValidatingWebhook. # noqa: E501

Return type:

V1LabelSelector

property object_selector

Gets the object_selector of this V1ValidatingWebhook. # noqa: E501

Returns:

The object_selector of this V1ValidatingWebhook. # noqa: E501

Return type:

V1LabelSelector

openapi_types = {'admission_review_versions': 'list[str]', 'client_config': 'AdmissionregistrationV1WebhookClientConfig', 'failure_policy': 'str', 'match_conditions': 'list[V1MatchCondition]', 'match_policy': 'str', 'name': 'str', 'namespace_selector': 'V1LabelSelector', 'object_selector': 'V1LabelSelector', 'rules': 'list[V1RuleWithOperations]', 'side_effects': 'str', 'timeout_seconds': 'int'}
property rules

Gets the rules of this V1ValidatingWebhook. # noqa: E501

Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule. However, in order to prevent ValidatingAdmissionWebhooks and MutatingAdmissionWebhooks from putting the cluster in a state which cannot be recovered from without completely disabling the plugin, ValidatingAdmissionWebhooks and MutatingAdmissionWebhooks are never called on admission requests for ValidatingWebhookConfiguration and MutatingWebhookConfiguration objects. # noqa: E501

Returns:

The rules of this V1ValidatingWebhook. # noqa: E501

Return type:

list[V1RuleWithOperations]

property side_effects

Gets the side_effects of this V1ValidatingWebhook. # noqa: E501

SideEffects states whether this webhook has side effects. Acceptable values are: None, NoneOnDryRun (webhooks created via v1beta1 may also specify Some or Unknown). Webhooks with side effects MUST implement a reconciliation system, since a request may be rejected by a future step in the admission chain and the side effects therefore need to be undone. Requests with the dryRun attribute will be auto-rejected if they match a webhook with sideEffects == Unknown or Some. # noqa: E501

Returns:

The side_effects of this V1ValidatingWebhook. # noqa: E501

Return type:

str

property timeout_seconds

Gets the timeout_seconds of this V1ValidatingWebhook. # noqa: E501

TimeoutSeconds specifies the timeout for this webhook. After the timeout passes, the webhook call will be ignored or the API call will fail based on the failure policy. The timeout value must be between 1 and 30 seconds. Default to 10 seconds. # noqa: E501

Returns:

The timeout_seconds of this V1ValidatingWebhook. # noqa: E501

Return type:

int

to_dict(serialize=False)

Returns the model properties as a dict

to_str()

Returns the string representation of the model