diff --git a/manifests/rbac/controller.yaml b/manifests/rbac/controller.yaml index 932e5b11..97811601 100644 --- a/manifests/rbac/controller.yaml +++ b/manifests/rbac/controller.yaml @@ -70,13 +70,19 @@ roleRef: subjects: - kind: ServiceAccount name: kustomize-controller + namespace: flux-system - kind: ServiceAccount name: helm-controller + namespace: flux-system - kind: ServiceAccount name: source-controller + namespace: flux-system - kind: ServiceAccount name: notification-controller + namespace: flux-system - kind: ServiceAccount name: image-reflector-controller + namespace: flux-system - kind: ServiceAccount name: image-automation-controller + namespace: flux-system diff --git a/manifests/rbac/reconciler.yaml b/manifests/rbac/reconciler.yaml index 7313d271..1155cf48 100644 --- a/manifests/rbac/reconciler.yaml +++ b/manifests/rbac/reconciler.yaml @@ -9,5 +9,7 @@ roleRef: subjects: - kind: ServiceAccount name: kustomize-controller + namespace: flux-system - kind: ServiceAccount name: helm-controller + namespace: flux-system diff --git a/pkg/manifestgen/install/templates.go b/pkg/manifestgen/install/templates.go index e870f4f6..316435d1 100644 --- a/pkg/manifestgen/install/templates.go +++ b/pkg/manifestgen/install/templates.go @@ -117,6 +117,7 @@ images: var kustomizationRolesTmpl = `--- apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization +namespace: {{.Namespace}} resources: - rbac.yaml nameSuffix: -{{.Namespace}}