mirror of https://github.com/knative/eventing.git
Compare commits
3 Commits
Author | SHA1 | Date |
---|---|---|
|
c138419361 | |
|
4542e6bf08 | |
|
cbdf86e94b |
|
@ -79,6 +79,19 @@ rules:
|
||||||
---
|
---
|
||||||
kind: ClusterRole
|
kind: ClusterRole
|
||||||
apiVersion: rbac.authorization.k8s.io/v1
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
metadata:
|
||||||
|
name: knative-sinks-namespaced-admin
|
||||||
|
labels:
|
||||||
|
rbac.authorization.k8s.io/aggregate-to-admin: "true"
|
||||||
|
app.kubernetes.io/version: devel
|
||||||
|
app.kubernetes.io/name: knative-eventing
|
||||||
|
rules:
|
||||||
|
- apiGroups: ["sinks.knative.dev"]
|
||||||
|
resources: ["*"]
|
||||||
|
verbs: ["*"]
|
||||||
|
---
|
||||||
|
kind: ClusterRole
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
metadata:
|
metadata:
|
||||||
name: knative-eventing-namespaced-edit
|
name: knative-eventing-namespaced-edit
|
||||||
labels:
|
labels:
|
||||||
|
@ -86,7 +99,7 @@ metadata:
|
||||||
app.kubernetes.io/version: devel
|
app.kubernetes.io/version: devel
|
||||||
app.kubernetes.io/name: knative-eventing
|
app.kubernetes.io/name: knative-eventing
|
||||||
rules:
|
rules:
|
||||||
- apiGroups: ["eventing.knative.dev", "messaging.knative.dev", "sources.knative.dev", "flows.knative.dev", "bindings.knative.dev"]
|
- apiGroups: ["eventing.knative.dev", "messaging.knative.dev", "sources.knative.dev", "flows.knative.dev", "bindings.knative.dev", "sinks.knative.dev"]
|
||||||
resources: ["*"]
|
resources: ["*"]
|
||||||
verbs: ["create", "update", "patch", "delete"]
|
verbs: ["create", "update", "patch", "delete"]
|
||||||
---
|
---
|
||||||
|
@ -99,6 +112,6 @@ metadata:
|
||||||
app.kubernetes.io/version: devel
|
app.kubernetes.io/version: devel
|
||||||
app.kubernetes.io/name: knative-eventing
|
app.kubernetes.io/name: knative-eventing
|
||||||
rules:
|
rules:
|
||||||
- apiGroups: ["eventing.knative.dev", "messaging.knative.dev", "sources.knative.dev", "flows.knative.dev", "bindings.knative.dev"]
|
- apiGroups: ["eventing.knative.dev", "messaging.knative.dev", "sources.knative.dev", "flows.knative.dev", "bindings.knative.dev", "sinks.knative.dev"]
|
||||||
resources: ["*"]
|
resources: ["*"]
|
||||||
verbs: ["get", "list", "watch"]
|
verbs: ["get", "list", "watch"]
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -1,5 +1,7 @@
|
||||||
module knative.dev/eventing
|
module knative.dev/eventing
|
||||||
|
|
||||||
|
// A placeholder comment to rebuild with Go 1.23.5 toolchain to cover CVEs
|
||||||
|
|
||||||
go 1.22.7
|
go 1.22.7
|
||||||
|
|
||||||
require (
|
require (
|
||||||
|
|
|
@ -25,11 +25,11 @@ import (
|
||||||
"k8s.io/client-go/tools/cache"
|
"k8s.io/client-go/tools/cache"
|
||||||
"knative.dev/pkg/apis"
|
"knative.dev/pkg/apis"
|
||||||
configmapinformer "knative.dev/pkg/client/injection/kube/informers/core/v1/configmap"
|
configmapinformer "knative.dev/pkg/client/injection/kube/informers/core/v1/configmap"
|
||||||
endpointsinformer "knative.dev/pkg/client/injection/kube/informers/core/v1/endpoints"
|
|
||||||
"knative.dev/pkg/configmap"
|
"knative.dev/pkg/configmap"
|
||||||
"knative.dev/pkg/controller"
|
"knative.dev/pkg/controller"
|
||||||
"knative.dev/pkg/injection/clients/dynamicclient"
|
"knative.dev/pkg/injection/clients/dynamicclient"
|
||||||
secretinformer "knative.dev/pkg/injection/clients/namespacedkube/informers/core/v1/secret"
|
secretinformer "knative.dev/pkg/injection/clients/namespacedkube/informers/core/v1/secret"
|
||||||
|
namespacedinformerfactory "knative.dev/pkg/injection/clients/namespacedkube/informers/factory"
|
||||||
"knative.dev/pkg/logging"
|
"knative.dev/pkg/logging"
|
||||||
pkgreconciler "knative.dev/pkg/reconciler"
|
pkgreconciler "knative.dev/pkg/reconciler"
|
||||||
"knative.dev/pkg/resolver"
|
"knative.dev/pkg/resolver"
|
||||||
|
@ -69,7 +69,12 @@ func NewController(
|
||||||
logger := logging.FromContext(ctx)
|
logger := logging.FromContext(ctx)
|
||||||
brokerInformer := brokerinformer.Get(ctx)
|
brokerInformer := brokerinformer.Get(ctx)
|
||||||
subscriptionInformer := subscriptioninformer.Get(ctx)
|
subscriptionInformer := subscriptioninformer.Get(ctx)
|
||||||
endpointsInformer := endpointsinformer.Get(ctx)
|
|
||||||
|
endpointsInformer := namespacedinformerfactory.Get(ctx).Core().V1().Endpoints()
|
||||||
|
if err := controller.StartInformers(ctx.Done(), endpointsInformer.Informer()); err != nil {
|
||||||
|
logger.Fatalw("Failed to start namespaced endpoints informer", zap.Error(err))
|
||||||
|
}
|
||||||
|
|
||||||
configmapInformer := configmapinformer.Get(ctx)
|
configmapInformer := configmapinformer.Get(ctx)
|
||||||
secretInformer := secretinformer.Get(ctx)
|
secretInformer := secretinformer.Get(ctx)
|
||||||
eventPolicyInformer := eventpolicyinformer.Get(ctx)
|
eventPolicyInformer := eventpolicyinformer.Get(ctx)
|
||||||
|
|
Loading…
Reference in New Issue