mirror of
https://github.com/kubernetes/sample-controller.git
synced 2026-04-12 00:00:26 +08:00
Merge pull request #57958 from nikhita/sample-controller-crd-validation
Automatic merge from submit-queue (batch tested with PRs 57902, 57958). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Add CustomResourceValidation example in sample-controller Add `CustomResourceValidation` example in sample-controller. Addresses the following part of https://github.com/kubernetes/sample-controller/issues/2: > CRDs support json-schema schemas. These CRDs don't have them. It would be nice to show how to add them **Release note**: ```release-note NONE ``` /assign sttts munnerz Kubernetes-commit: 51acead08489644d30b3f1a978e0b36f228d12a7
This commit is contained in:
+1
-1
@@ -153,7 +153,7 @@ func kindMatches(pattern schema.GroupVersionKind, kind schema.GroupVersionKind)
|
||||
}
|
||||
|
||||
func (m PriorityRESTMapper) RESTMapping(gk schema.GroupKind, versions ...string) (mapping *RESTMapping, err error) {
|
||||
mappings, err := m.Delegate.RESTMappings(gk)
|
||||
mappings, err := m.Delegate.RESTMappings(gk, versions...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user