Skip to content

Conversation

@olegenii
Copy link
Owner

RCA:

The HelmRelease test/komoplane-20 failed during Helm install because the chart rendered a Deployment
with spec.replicas set to a string value. The HelmRelease contained replicaCount: o1 (letter 'o' + 1)
which is a string. Kubernetes expects replicas to be an integer (int32). The helm-controller reported:

  • Deployment in version "v1" cannot be handled as a Deployment: json: cannot unmarshal string into Go struct field DeploymentSpec.spec.replicas of type int32

Remediation implemented:

  • Replaced invalid string value replicaCount: o1 with integer replicaCount: 1 in apps/overlay/control-cluster/hr-failed.yaml.
  • Annotated the HelmRepository and HelmRelease with kagentFix=2025-09-17T08:58:30Z per agent requirements.

Why this fix is safe:

  • Changing replicaCount from a non-numeric string to a numeric integer corrects the type mismatch and allows Helm to render valid Deployment YAML.
  • The change is scoped to the intentionally failing test overlay manifest (hr-failed.yaml) only.

Next steps and verification:

  1. Merge this PR to the local branch. Flux will pick up the change and re-apply the HelmRelease.
  2. Verify the HelmRelease status in namespace test: kubectl -n test get hr komoplane-20 -o yaml and confirm Ready condition.
  3. Check helm-controller logs and events for successful install.
  4. If the HelmRelease still fails, inspect rendered Helm template using helm template locally against the chart version 0.1.6 and the provided values.

Fix applied by AI agent: [kagent/aire-agent]

RCA: Helm install failed because HelmRelease contained replicaCount as a string 'o1' which
decompression into a Deployment spec causes a type error (string -> int32). Change to integer.

chore: annotate resources with kagentFix timestamp

Signed-off-by: aire_agent
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants