feat(helm): configurable replicas (webhook + operator) and extraObjects#3683
Closed
aqeelat wants to merge 4 commits into
Closed
feat(helm): configurable replicas (webhook + operator) and extraObjects#3683aqeelat wants to merge 4 commits into
aqeelat wants to merge 4 commits into
Conversation
The webhook Deployment hardcoded replicas: 1. Expose it through webhook.replicas (default 1 in values.yaml). The operator Deployment is left at a fixed replica count of 1 because the operator does not run leader election, so scaling its reconcilers horizontally would cause duplicate writes and status flapping. Signed-off-by: Abdullah Alaqeel <abdullah.t.aqeel@gmail.com>
A webhook scaled to 0 pods has no endpoints, so admission calls time out and fail. Under failurePolicy: Fail this wedges operations on the matched CRs. Guard with `max 1` so an explicit 0 renders 1 instead of silently breaking admission. Addresses review feedback. Signed-off-by: Abdullah Alaqeel <abdullah.t.aqeel@gmail.com>
Render arbitrary user-supplied manifests from values.extraObjects, matching the standard pattern used by charts like argoproj/argo-cd. Lets consumers deploy resources the chart deliberately does not template, most notably a TektonConfig CR. Defaults to an empty list, which renders nothing. Signed-off-by: Abdullah Alaqeel <abdullah.t.aqeel@gmail.com>
The operator Deployment hardcoded replicas: 1. Expose it through operator.replicas (default 1). Unlike the webhook, scaling up is safe here: the operator runs on knative sharedmain, which enables leader election by default, so >=2 replicas run active/standby (no duplicate writes). A config-leader-election ConfigMap is optional; knative falls back to defaults when it is absent. Signed-off-by: Abdullah Alaqeel <abdullah.t.aqeel@gmail.com>
Contributor
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
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.
Changes
Feature additions to the community Helm chart (
charts/tekton-operator/). Each is a separate commit for independent review/cherry-pick. Split out from the bug-fix PR #3661 to keep review focused.1. feat(helm): make webhook Deployment replicas configurable, floored at 1
The webhook Deployment hardcoded
replicas: 1. Expose it viawebhook.replicas(default1), guarded withmax 1so an explicit0renders1. A webhook scaled to0has no endpoints, so admission calls time out; underfailurePolicy: Failthis wedges operations on the matched CRs.2. feat(helm): add extraObjects for user-supplied manifests
Render arbitrary manifests from
values.extraObjects(standard pattern, e.g. argoproj/argo-cd). Useful for resources the chart deliberately does not template, most notably a TektonConfig CR. Defaults to[](renders nothing).3. feat(helm): make operator Deployment replicas configurable
The operator Deployment hardcoded
replicas: 1. Expose it viaoperator.replicas(default1). Unlike the webhook, scaling up is safe here: the operator runs on knativesharedmain, which enables leader election by default (WithHADisabledis never called), so>=2replicas run active/standby — no duplicate writes. Aconfig-leader-electionConfigMap is optional; knative falls back to defaults when it is absent.Submitter Checklist
make test lintbefore submitting a PR(chart-only change;
make lint/make testcover Go packages and do not exercise the chart. Verified withhelm lint/helm template. Note: full-chart templating also requires the CRD parse fix from fix(helm): correct logging CM, add webhook replicas, add extraObjects #3661, which is a pre-existing bug onmain.)(No chart test framework exists in this repo. Validation is via
helm lint/helm templaterendering.)(values.yaml comments document all new values, including the leader-election note on
operator.replicasand theautoInstallComponentswarning onextraObjects.)Release Notes