Kyverno
Medium
Policies
Which of the following is a valid JMESPath expression in a Kyverno policy?
Select your answer:
Show answer and explanation
Answer: request.object.metadata.name == 'nginx'
Explanation
Kyverno uses JMESPath expressions for conditions and pattern matching. 'request.object.metadata.name == 'nginx'' is a valid JMESPath expression that checks if the name of the resource is 'nginx'.
More medium Kyverno questions
- What is the purpose of the 'exclude' field in a Kyverno policy?
- What is the purpose of the 'preconditions' field in a Kyverno rule?
- Which of the following is a valid pattern matching syntax in Kyverno?
- What is the purpose of the 'audit' value for 'validationFailureAction' in a Kyverno policy?
- What is the purpose of the 'synchronize' field in a Kyverno generate rule?
- Which of the following is NOT a valid operation in a Kyverno mutate rule?