fix(helm): parameterize resource names to enable multi-operator sharding via Helm#6543
Open
timmy-mathew-ah wants to merge 1 commit intoapache:mainfrom
Open
fix(helm): parameterize resource names to enable multi-operator sharding via Helm#6543timmy-mathew-ah wants to merge 1 commit intoapache:mainfrom
timmy-mathew-ah wants to merge 1 commit intoapache:mainfrom
Conversation
…ase names in cluster-wide scope
squakez
approved these changes
Mar 24, 2026
gansheer
approved these changes
Mar 24, 2026
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.
Summary
Parameterize all hardcoded Kubernetes resource names in Helm chart templates using the existing
{{ include "camel-k.fullname" . }}helper, enabling installation of multiple Camel-K operators on the same cluster via Helm without resource name collisions in same or different namespaces.Fixes #6145, #6533
Problem
The official Camel-K documentation describes an operator sharding pattern when you set
global:trueduring helm install where each operator has a uniqueOPERATOR_IDand only reconciles resources annotated with the matchingcamel.apache.org/operator.id. However, installing multiple operators via Helm fails because all resource names are hardcoded tocamel-k-*regardless of the Helm release name or custom value.Since
ClusterRolesandClusterRoleBindingsare cluster-scoped (shared across all namespaces), the secondhelm installimmediately collides with the first:PR #6191 previously removed several unnecessary cluster-scoped resources but the core problem remained, resource names were still hardcoded and not parameterized by release name.
Backward Compatibility
Fully backward compatible
The
camel-k.fullnamehelper returnscamel-kwhen the release name iscamel-k(the standard install). All resource names resolve to their original hardcoded values and the rendered output is identical to the original chart for bothglobal: trueandglobal: falsemodes.# Standard install — output identical to before this fix helm install camel-k camel-k/camel-k --namespace camel-k --create-namespaceSupported Deployment Patterns
global: falseglobal: trueUsage Examples
Single operator (unchanged behaviour)
Multiple global operators - separate namespaces
Each operator in its own namespace, watching the entire cluster, only reconciling integrations annotated with its
operator.id:Multiple global operators - same namespace
All operators managed in a single namespace. Enables IntegrationKit sharing across shards (same runtime = reuse of already built kits):
Known Limitation
The builder ServiceAccount name (
camel-k-builder) is hardcoded in Go code atpkg/platform/defaults.go:Builder pods always use this SA name regardless of the Helm release name. This means:
camel-k-shard-1-builder) for RBAC consistencycamel-k-builderat runtime for actual builder podsThis is pre-existing behaviour, unchanged by this PR.