Kyverno
Medium
Validation
Which of the following is a valid pattern matching syntax in Kyverno?
Select your answer:
Show answer and explanation
Answer: metadata.name: regex('^test-.*$')
Explanation
Kyverno supports pattern matching using the 'regex' function. The syntax 'metadata.name: regex('^test-.*$')' is valid and matches any resource name that starts with 'test-'.
More medium Kyverno questions
- 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?
- What is the purpose of the 'policyReport' resource in Kyverno?
- Which of the following is a valid way to exclude system namespaces in a Kyverno policy?
- What is the purpose of the 'match.resources.selector' field in a Kyverno policy?