Add RBAC support for cross-namespace secret reading#6919
Open
rohitrsh wants to merge 1 commit intoflyteorg:masterfrom
Open
Add RBAC support for cross-namespace secret reading#6919rohitrsh wants to merge 1 commit intoflyteorg:masterfrom
rohitrsh wants to merge 1 commit intoflyteorg:masterfrom
Conversation
…ret reading Add optional ClusterRole and ClusterRoleBinding to the flyteconnector Helm chart, enabling the connector to read secrets from workflow namespaces for per-project Databricks token authentication. Disabled by default (rbac.enabled: false) for backward compatibility. Tracking: flyteorg#6911 Signed-off-by: Rohit Sharma <rohitrsh@gmail.com>
Open
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tracking issue
Related to #6911
Why are the changes needed?
The Databricks Spark connector now supports Add multi-tenant Databricks token support via cross-namespace K8S secrets, allowing the connector to read Databricks tokens from Kubernetes secrets in workflow namespaces. This enables multi-tenant Databricks access, allowing each Flyte project to use its own Databricks workspace/token.
For this feature to work, the connector's ServiceAccount needs
getpermission onsecretsacross namespaces. Currently, theflyteconnectorHelm chart creates a ServiceAccount but no RBAC resources (ClusterRole / ClusterRoleBinding), so the connector cannot read secrets from workflow namespaces.What changes were proposed in this pull request?
New file:
templates/connector/rbac.yamlAdds an optional
ClusterRoleandClusterRoleBindingfor the flyteconnector ServiceAccount:values.yaml, defaulting togetonsecretsrbac.enabled: true(default:falsefor backward compatibility)Updated:
values.yamlAdded
rbacconfiguration block:Key design decisions:
enabled: falseby default Opt-in to avoid breaking existing deployments that don't need cross-namespace secret accessgetverb Least privilege; nolistorwatchvalues.yamloverridesresourceNamesrestriction Supports both the defaultdatabricks-tokenand custom secret namesHow was this patch tested?
helm template:Verified RBAC disabled by default no ClusterRole/ClusterRoleBinding rendered when
rbac.enabledis omittedVerified cross-namespace secret access after applying:
Setup process
To enable Databricks per-project token support:
Then create secrets in workflow namespaces:
Screenshots
N/A (infrastructure-only change)
Check all the applicable boxes
Related PRs
Docs link
N/A