Skip to content

chore(envoy-gateway): exclude certgen hook Job from projected manifests - #186

Merged
themightychris merged 1 commit into
mainfrom
chore/exclude-certgen-hook
Aug 25, 2026
Merged

chore(envoy-gateway): exclude certgen hook Job from projected manifests#186
themightychris merged 1 commit into
mainfrom
chore/exclude-certgen-hook

Conversation

@themightychris

Copy link
Copy Markdown
Member

Stops the envoy-gateway certgen Job from appearing as recurring drift in every deploy PR.

Problem

The gateway-helm chart ships certgen.yaml as a Helm pre-install,pre-upgrade hook that generates the envoy-gateway webhook certs. helm template emits hooks like any other manifest, and the helm3 hololens has no --no-hooks option — so the Job lands in the projection and gets kubectl apply'd on every deploy.

It carries ttlSecondsAfterFinished: 30, so it deletes itself moments after running. kubectl diff therefore reports it as a fresh creation in every deploy PR, forever. It appeared alongside the vaultwarden bump in #185 and in #181 before that, and each occurrence has to be re-triaged by hand to confirm it's benign — which is exactly the kind of standing noise that erodes the diff gate's value as a review surface.

Fix

Exclude the chart template so the Job is dropped before helm renders it. This mirrors the !templates/tests/** exclusion already used for the vaultwarden chart, and sits next to the existing ingress-nginx exclusion in the same mapping.

certgen-rbac.yaml is deliberately left in place, so re-enabling this is a one-line revert.

Why it's safe to drop

  • It doesn't rotate existing certs. It re-ran during Deploy releases/k8s-manifests aa5d242 #181 a month ago, yet the envoy and envoy-gateway secrets still date to 2026-05-18 — it only creates certs when missing.
  • The certs it generated are valid until 2031-05-17.
  • Applying a Helm lifecycle hook declaratively was never really correct; hooks are meant to run under Helm's install/upgrade lifecycle, not be reconciled by kubectl apply.

Should this cluster ever need certgen again (cert loss, a from-scratch rebuild), reverting this line restores it.

Verification

Ran git holo project k8s-manifests locally against this branch. The only delta versus the currently deployed tree:

D  envoy-gateway-system/Job/envoy-gateway-gateway-helm-certgen.yaml

The certgen RBAC (ClusterRole, ClusterRoleBinding, Role, RoleBinding, ServiceAccount) is retained as intended, and nothing else in the projection moves.

🤖 Generated with Claude Code

https://claude.ai/code/session_01MSNAVVDuF46SMHjnyfmxwU

The gateway-helm chart ships certgen.yaml as a Helm
`pre-install,pre-upgrade` hook that generates the envoy-gateway webhook
certs. `helm template` emits hooks like any other manifest and the helm3
hololens has no --no-hooks option, so the Job lands in the projection and
gets kubectl-applied on every deploy.

Because it carries `ttlSecondsAfterFinished: 30` it deletes itself moments
after running, so `kubectl diff` reports it as a fresh creation in every
deploy PR. That noise recurs indefinitely and buries the real changes —
it showed up alongside the vaultwarden bump in #185 and in #181 before
that, and each occurrence has to be re-triaged by hand.

Excluding the chart template drops the Job before helm renders it,
mirroring the `!templates/tests/**` exclusion already used for the
vaultwarden chart.

certgen-rbac.yaml is deliberately left in place so re-enabling this is a
one-line revert. Verified safe to drop:

- The Job is idempotent and does not rotate existing certs — it re-ran
  during #181 and the envoy/envoy-gateway secrets still date to
  2026-05-18.
- Those certs are valid until 2031-05-17.

Verified with `git holo project k8s-manifests`: the only delta against
the deployed tree is removal of
envoy-gateway-system/Job/envoy-gateway-gateway-helm-certgen.yaml.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MSNAVVDuF46SMHjnyfmxwU
@themightychris
themightychris requested a review from a team as a code owner August 25, 2026 16:34
@themightychris
themightychris merged commit 4c3b05f into main Aug 25, 2026
@themightychris
themightychris deleted the chore/exclude-certgen-hook branch August 25, 2026 16:35
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.

1 participant