This repository has been archived by the owner on Jun 18, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 231
/
main.go
65 lines (62 loc) · 2.03 KB
/
main.go
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
package main
import (
adminv1 "github.com/rancher/rio/pkg/apis/admin.rio.cattle.io/v1"
v3 "github.com/rancher/rio/pkg/apis/management.cattle.io/v3"
riov1 "github.com/rancher/rio/pkg/apis/rio.cattle.io/v1"
controllergen "github.com/rancher/wrangler/pkg/controller-gen"
"github.com/rancher/wrangler/pkg/controller-gen/args"
solov1 "github.com/solo-io/gloo/projects/gateway/pkg/api/v1/kube/apis/gateway.solo.io/v1"
gloov1 "github.com/solo-io/gloo/projects/gloo/pkg/api/v1/kube/apis/gloo.solo.io/v1"
)
var (
basePackage = "github.com/rancher/rio/types"
)
func main() {
controllergen.Run(args.Options{
OutputPackage: "github.com/rancher/rio/pkg/generated",
Boilerplate: "scripts/boilerplate.go.txt",
Groups: map[string]args.Group{
"admin.rio.cattle.io": {
Types: []interface{}{
adminv1.ClusterDomain{},
adminv1.RioInfo{},
adminv1.PublicDomain{},
adminv1.SystemStack{},
},
GenerateTypes: true,
},
"rio.cattle.io": {
Types: []interface{}{
riov1.ExternalService{},
riov1.Router{},
riov1.Service{},
riov1.Stack{},
},
GenerateTypes: true,
},
"gateway.solo.io": {
Types: []interface{}{
solov1.VirtualService{},
},
ClientSetPackage: "github.com/solo-io/gloo/projects/gateway/pkg/api/v1/kube/client/clientset/versioned",
InformersPackage: "github.com/solo-io/gloo/projects/gateway/pkg/api/v1/kube/client/informers/externalversions",
ListersPackage: "github.com/solo-io/gloo/projects/gateway/pkg/api/v1/kube/client/listers",
},
"gloo.solo.io": {
Types: []interface{}{
gloov1.Settings{},
},
ClientSetPackage: "github.com/solo-io/gloo/projects/gloo/pkg/api/v1/kube/client/clientset/versioned",
InformersPackage: "github.com/solo-io/gloo/projects/gloo/pkg/api/v1/kube/client/informers/externalversions",
ListersPackage: "github.com/solo-io/gloo/projects/gloo/pkg/api/v1/kube/client/listers",
},
"management.cattle.io": {
Types: []interface{}{
v3.Setting{},
v3.User{},
},
GenerateTypes: true,
},
},
})
}