forked from cobaltcore-dev/cortex
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgroupversion_info.go
More file actions
31 lines (24 loc) · 1.03 KB
/
Copy pathgroupversion_info.go
File metadata and controls
31 lines (24 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// Copyright SAP SE
// SPDX-License-Identifier: Apache-2.0
// Package v1alpha1 contains API Schema definitions for the knowledge v1alpha1 API group.
// +kubebuilder:object:generate=true
// +groupName=cortex.cloud
package v1alpha1
import (
"k8s.io/apimachinery/pkg/runtime/schema"
"sigs.k8s.io/controller-runtime/pkg/scheme"
)
var (
// GroupVersion is group version used to register these objects.
GroupVersion = schema.GroupVersion{Group: "cortex.cloud", Version: "v1alpha1"}
// SchemeGroupVersion is group version used to register these objects.
SchemeGroupVersion = GroupVersion
// SchemeBuilder is used to add go types to the GroupVersionKind scheme.
SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}
// AddToScheme adds the types in this group-version to the given scheme.
AddToScheme = SchemeBuilder.AddToScheme
)
// Resource takes an unqualified resource and returns a Group qualified GroupResource
func Resource(resource string) schema.GroupResource {
return SchemeGroupVersion.WithResource(resource).GroupResource()
}