Skip to content

Commit 231408e

Browse files
committed
fix pattern addon template
1 parent 9552d12 commit 231408e

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

plugins/addon/controller.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ import (
4848
ctrl "sigs.k8s.io/controller-runtime"
4949
"sigs.k8s.io/controller-runtime/pkg/client"
5050
51-
api "{{ .Resource.GoPackage }}/{{ .Resource.Version }}"
51+
api "{{ .Resource.Package }}"
5252
)
5353
5454
var _ reconcile.Reconciler = &{{ .Resource.Kind }}Reconciler{}
@@ -62,8 +62,8 @@ type {{ .Resource.Kind }}Reconciler struct {
6262
declarative.Reconciler
6363
}
6464
65-
// +kubebuilder:rbac:groups={{.Resource.GroupDomain}},resources={{ .Resource.Plural }},verbs=get;list;watch;create;update;patch;delete
66-
// +kubebuilder:rbac:groups={{.Resource.GroupDomain}},resources={{ .Resource.Plural }}/status,verbs=get;update;patch
65+
// +kubebuilder:rbac:groups={{ .Resource.Domain }},resources={{ .Resource.Plural }},verbs=get;list;watch;create;update;patch;delete
66+
// +kubebuilder:rbac:groups={{ .Resource.Domain }},resources={{ .Resource.Plural }}/status,verbs=get;update;patch
6767
6868
func (r *{{ .Resource.Kind }}Reconciler) SetupWithManager(mgr ctrl.Manager) error {
6969
addon.Init()

plugins/addon/type.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ type {{.Resource.Kind}}Status struct {
7777
// +kubebuilder:object:root=true
7878
{{ if not .Resource.Namespaced }} // +kubebuilder:resource:scope=Cluster {{ end }}
7979
80-
// {{.Resource.Kind}} is the Schema for the {{ .Resource.Resource }} API
80+
// {{.Resource.Kind}} is the Schema for the {{ .Resource.Plural }} API
8181
type {{.Resource.Kind}} struct {
8282
metav1.TypeMeta ` + "`" + `json:",inline"` + "`" + `
8383
metav1.ObjectMeta ` + "`" + `json:"metadata,omitempty"` + "`" + `

0 commit comments

Comments
 (0)