You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 6802f19
Browse filesBrowse the repository at this point in the historyBrowse files
The gateway chart always rendered the ClusterRole and ClusterRoleBinding, so
every install and upgrade required cluster-admin even when only namespaced
objects were needed. Installers that are namespace-admin GitOps or platform
controllers could not run the release at all, and clusters where cluster-scoped
RBAC is owned by a separate team had no supported way to split the install.
Add an rbac values block so a cluster-admin can apply the cluster-scoped objects
once and a namespace-admin can install and upgrade the release without
cluster-scoped permissions:
rbac:
create: true
clusterScoped:
create: true
clusterRoleName: ""
clusterRoleBindingName: ""
rbac.clusterScoped.create gates the ClusterRole and ClusterRoleBinding, and is
independent of the workspace mode. rbac.create additionally gates the namespaced
sandbox Role and RoleBinding, which matters because Kubernetes escalation
prevention stops an installer holding only the built-in admin role from creating
a Role that grants agents.x-k8s.io verbs it does not itself hold. The certgen
hook and credential driver RBAC keep their existing flags.
Both flags default to true, so current installs are unchanged. The helpers treat
a missing rbac block as enabled so upgrades with --reuse-values do not drop RBAC,
matching the existing workspaceResources pattern. The ClusterRoleBinding roleRef
follows clusterRoleName so a separately applied ClusterRole can carry a name the
cluster-admin chooses.
Document the migration for a release that already owns the cluster-scoped
objects: Helm deletes objects that leave the manifest, so annotate them with
helm.sh/resource-policy=keep before setting the flag, otherwise the gateway
loses TokenReview until a cluster-admin re-applies them.
Signed-off-by: ansjindal <ansjindal@nvidia.com>
The objects then survive the upgrade that sets the flag, and the cluster-admin
118
+
owns them from that point on. Fresh installs need no such step.
119
+
120
+
`rbac.clusterScoped.create` is independent of
121
+
`server.drivers.kubernetes.workspaceMode`. Managed and operator modes change
122
+
what the `ClusterRole` contains, but they never force the namespaced release to
123
+
apply it. Re-run the cluster-admin step after changing values that affect the
124
+
`ClusterRole` rules.
125
+
20
126
## Prerequisites
21
127
22
128
> **Required:** Your cluster CNI MUST enforce Kubernetes `NetworkPolicy` for
@@ -260,6 +366,10 @@ discovery endpoint or its TLS CA.
260
366
| probes.startup.failureThreshold | int |`30`| Startup probe failure threshold before the container is killed. |
261
367
| probes.startup.periodSeconds | int |`2`| Startup probe period, in seconds. |
262
368
| probes.startup.timeoutSeconds | int |`1`| Startup probe timeout, in seconds. |
369
+
| rbac.clusterScoped.clusterRoleBindingName | string |`""`| Name for the ClusterRoleBinding. Empty uses the `<fullname>-node-reader-<release namespace>` default. |
370
+
| rbac.clusterScoped.clusterRoleName | string |`""`| Name for the ClusterRole. Empty uses the `<fullname>-node-reader-<release namespace>` default. |
371
+
| rbac.clusterScoped.create | bool |`true`| Create the cluster-scoped ClusterRole and ClusterRoleBinding. Disable for a namespace-admin install where a cluster-admin applies them separately; the gateway ServiceAccount name and namespace are unchanged, so a pre-created ClusterRoleBinding still matches. |
372
+
| rbac.create | bool |`true`| Create the RBAC objects that grant the gateway ServiceAccount access. Disable to supply the namespaced sandbox and peer Role/RoleBinding and the cluster-scoped ClusterRole/ClusterRoleBinding out of band. The certgen hook and credential driver RBAC keep their own flags. |
263
373
| replicaCount | int |`1`| Number of OpenShell gateway replicas. Values greater than 1 require server.externalDbSecret because the default SQLite backend is per pod. |
264
374
| resources | object |`{}`| Gateway pod resource requests and limits. |
265
375
| sandbox.image.digest | string |`""`| Sandbox image digest. When set, this takes precedence over tag. |
0 commit comments