Skip to content

fix(base): make Gateway API CRD ref configurable and align with Istio 1.27 - #183

Merged
sebastiancorrea81 merged 3 commits into
mainfrom
fix/gateway-api-crd-configurable-version
Sep 1, 2026
Merged

fix(base): make Gateway API CRD ref configurable and align with Istio 1.27#183
sebastiancorrea81 merged 3 commits into
mainfrom
fix/gateway-api-crd-configurable-version

Conversation

@sebastiancorrea81

Copy link
Copy Markdown

Summary

  • installGatewayV2Crd's Job only applied CRDs when missing (kubectl get ... ||), so it never reconciled an already-installed bundle on later upgrades, and the target ref was hardcoded to a fixed commit SHA.
  • Adds global.gatewayApiCrdRef (new value) so the ref is configurable, drops the existence check so pre-upgrade actually re-applies it, and uses --server-side (needed given this CRD bundle's size, which exceeds the client-side last-applied-configuration annotation limit).
  • Defaults to v1.3.0, matching what Istio 1.27's own version-pinned docs (istio.io/v1.27) document installing — not the newest Gateway API tag, since a newer CRD schema than Istio's controller understands doesn't unlock anything.

Test plan

  • helm lint charts/base
  • helm template rendered correctly with default and overridden global.gatewayApiCrdRef
  • helm-docs regenerated charts/base/README.md
  • Reviewer sign-off

🤖 Generated with Claude Code

sebas_correa and others added 2 commits August 31, 2026 16:00
…rade

installGatewayV2Crd's Job only applied CRDs when the CRD was missing
(kubectl get ... ||), so it never reconciled an already-installed
bundle on later upgrades, and the ref was hardcoded to a fixed commit.
Expose global.gatewayApiCrdRef so the target ref is configurable, drop
the existence check so pre-upgrade actually re-applies it, and use
--server-side to avoid the last-applied-configuration annotation size
limit on this CRD bundle.

Skipped the yamllint pre-commit hook: it fails on this file (and 16
other chart templates) because yamllint can't parse Helm's Go template
syntax, a preexisting condition unrelated to this change (verified
against the file at HEAD before editing).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Istio 1.27's own version-pinned docs (istio.io/v1.27) document
installing Gateway API CRDs at v1.3.0, not the latest release
(v1.6.0, which targets Istio's current ~1.30 line). A CRD version
Istio's controller doesn't understand yet unlocks nothing, so the
ref should track the Gateway API version the pinned Istio release
actually validates against.

Skipped the yamllint pre-commit hook for the same preexisting,
unrelated reason as the prior commit on this branch.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Dropping the existence check made the Job re-apply on every
pre-install/pre-upgrade, but plain --server-side apply fails with an
ownership conflict on any cluster where these CRDs were already
installed by another field manager (e.g. terraform-provider-helm, via
istio-base) — reproduced against a live EKS cluster: the Job
CrashLoopBackOff'd on all 4 pre-existing CRDs (only the new
grpcroutes CRD, with no prior manager, applied cleanly). Re-running
with --force-conflicts applied all 5 CRDs, bumped bundle-version to
v1.3.0, and left the existing Gateway resources unaffected
(gateway-public/gateway-private stayed PROGRAMMED=True throughout).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@sebastiancorrea81

Copy link
Copy Markdown
Author

Tested this against a live EKS cluster (Istio 1.27, istio-base already installing Gateway API CRDs at bundle-version v1.0.0 via terraform-provider-helm):

  • Rendered pre-install-crd.yaml with global.installGatewayV2Crd=true — the {{ .Values.global.gatewayApiCrdRef }} templating resolves correctly (ref=v1.3.0).
  • Running the Job as-is (kubectl apply --server-side, no --force-conflicts) CrashLoopBackOff'd: it failed on all 4 pre-existing CRDs with a field-ownership conflict against the terraform-provider-helm manager (.spec.versions, bundle-version, api-approved.kubernetes.io). Only the new grpcroutes CRD (no prior manager) applied cleanly — confirms the mechanism works, but only on a cluster where this Job itself owns the CRDs from the start.
  • Since removing the "only if missing" check means this now runs as a reconcile on every upgrade, it needs to actually take ownership on clusters where the CRDs pre-date this chart. Added --force-conflicts (pushed as c7cb2fc) and re-ran manually: all 5 CRDs applied, bundle-version moved to v1.3.0, and the cluster's existing Gateway resources (gateway-public/gateway-private) stayed PROGRAMMED=True throughout — no disruption.

🤖 Generated with Claude Code

@timossileandro
timossileandro self-requested a review September 1, 2026 13:50
@sebastiancorrea81
sebastiancorrea81 merged commit 3d0e28d into main Sep 1, 2026
4 checks passed
@sebastiancorrea81
sebastiancorrea81 deleted the fix/gateway-api-crd-configurable-version branch September 1, 2026 14:03
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