01. Within a Kyverno policy, each rule is built from a match declaration, an optional exclude declaration, and an action declaration. How many action declarations of type validate, mutate, generate, or verifyImages may a single rule contain?
a) At least one declaration of each type, so that a single rule can both mutate and then validate the same resource.
b) Any number of them, and Kyverno applies the declarations in the order they appear in the rule.
c) Up to two declarations, provided that one of them is a mutate declaration.
d) Exactly one; a rule holds a single validate, mutate, generate, or verifyImages declaration.
02. The main Kyverno ConfigMap defines which users and groups are exempt from policy processing. Which groups does the excludeGroups key exclude by default?
a) system:serviceaccounts:kube-system and system:nodes.
b) No groups at all; the key starts empty until an administrator populates it explicitly.
c) Only system:masters, the cluster-admin group.
d) system:authenticated together with system:unauthenticated.
03. Several Kyverno policies match the same incoming resource, and some of those policies contain more than one rule. Which statements correctly describe how Kyverno orders and applies these matching rules?
(Select all that apply.)
a) Every matching rule is applied to the resource, not only the first rule that matches.
b) Kyverno evaluates the matching policies strictly in the alphabetical order of their names.
c) There is no guaranteed ordering of rule evaluation within or across policies.
d) After the first rule matches, Kyverno skips the remaining matching rules for efficiency.
04. On a freshly installed Kyverno cluster with no policies created yet, an engineer inspects kyverno-resource-validating-webhook-cfg and finds that it has effectively no rules.
What is the correct explanation?
a) Validating webhooks stay empty until an administrator enables backgroundScan so that periodic scans can begin to populate them.
b) The admission controller populates that configuration only after it has been restarted at least once following installation.
c) No policies have been installed yet, and webhook rules are registered dynamically from the policies that exist.
d) The installation is broken, since a healthy Kyverno registers validating rules for every resource kind immediately at controller startup.
05. Kyverno supports two installation methods. Which one is documented as the recommended and most flexible method for production?
a) The kubectl kyverno install plugin subcommand.
b) The Helm chart.
c) A raw YAML manifest applied with kubectl.
d) The kyverno apply command from the CLI binary.
06. In a validate pattern, a field carries the Global anchor <(). A resource does not satisfy the anchored condition. What happens to that resource?
a) The entire rule is skipped for that resource.
b) The resource is blocked because the global condition failed.
c) The violation is recorded in a PolicyReport but the resource is admitted.
d) Only the anchored field is skipped; the rest of the pattern is still enforced.
07. By default Kyverno serves Prometheus metrics on port 8000. A team wants Kyverno to export its metrics to an OpenTelemetry collector over gRPC instead of exposing the Prometheus endpoint.
Which configuration change accomplishes this?
a) Set metricsPort=4317.
b) Set enableTracing=true.
c) Set disableMetrics=false.
d) Set otelConfig=grpc.
08. An engineer runs a dry run with kyverno apply and wants the resources that a mutate policy produces saved to a folder so they can be inspected afterward.
Which flag writes those resources to a file or directory?
a) -o, --output, which saves the mutated or generated resources to the given path
b) -f, --values-file, which supplies a file of variables and values
c) -p, --policy-report, which produces a policy report for validate policies during the run
d) -r, --resource, which points apply at the input manifests to evaluate
09. A precondition must test whether a Pod's namespace label is contained in a list of several permitted values. The author first tries Equals, but it compares against only a single value.
Which operator correctly tests membership of a value within an array?
a) NotEquals
b) AnyIn
c) GreaterThan
d) DurationGreaterThan
10. A mutate rule written with patchesJson6902 includes a conditional anchor () inside one of its patch operations, expecting the patch to apply only when the condition matches. The anchor appears to have no effect.
What explains this?
a) Conditional anchors require failureAction: Enforce to take effect.
b) Conditional anchors are evaluated only during background scans, not at admission.
c) patchesJson6902 does not support conditional anchors; anchors work only with patchStrategicMerge.
d) The anchor must be declared in the rule's match block rather than inside the individual patch operation where it was written.