Skip to content

k8s-stack: ignore operator webhook validation#2875

Merged
AndrewChubatiuk merged 2 commits into
VictoriaMetrics:masterfrom
onedr0p:vm-op-adhooks
May 3, 2026
Merged

k8s-stack: ignore operator webhook validation#2875
AndrewChubatiuk merged 2 commits into
VictoriaMetrics:masterfrom
onedr0p:vm-op-adhooks

Conversation

@onedr0p

@onedr0p onedr0p commented May 2, 2026

Copy link
Copy Markdown
Contributor

Closes #2874


Summary by cubic

Adds IgnoreOnInstallOnly support for admissionWebhooks.policy. In victoria-metrics-k8s-stack, default the operator webhook policy to Ignore so the stack installs and upgrades in one pass; the operator chart still defaults to Fail.

  • New Features
    • Helm: when policy is IgnoreOnInstallOnly, set failurePolicy to Ignore on install and Fail on upgrade; otherwise honor explicit Fail/Ignore, defaulting to Fail.
    • Defaults/docs: victoria-metrics-k8s-stack sets policy: Ignore by default and documents override to Fail for strict validation.

Written for commit 9d125cb. Summary will update on new commits.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 3 files

@onedr0p onedr0p marked this pull request as draft May 2, 2026 15:24
@onedr0p

onedr0p commented May 2, 2026

Copy link
Copy Markdown
Contributor Author

I'm going to change back the default to Fail in the operator and override the default to IgnoreOnInstallOnly in the stack chart.

@github-actions github-actions Bot added the k8s-stack k8s-stack helm chart related issue label May 2, 2026
@onedr0p onedr0p marked this pull request as ready for review May 2, 2026 15:38

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 5 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="charts/victoria-metrics-operator/templates/webhook.yaml">

<violation number="1" location="charts/victoria-metrics-operator/templates/webhook.yaml:47">
P1: `IgnoreOnInstallOnly` relies on `Release.IsInstall`, which stays install-like in render-only/GitOps workflows, so the webhook can remain `Ignore` permanently instead of switching to `Fail` after the first install.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review, or fix all with cubic.

Comment thread charts/victoria-metrics-operator/templates/webhook.yaml Outdated
@onedr0p onedr0p changed the title feat(victoria-metrics-operator): ignore webhook validation on first install victoria-metrics-operator/k8s-stack: ignore webhook validation on first install May 2, 2026
@onedr0p onedr0p changed the title victoria-metrics-operator/k8s-stack: ignore webhook validation on first install k8s-stack: ignore operator webhook validation May 3, 2026
@AndrewChubatiuk

Copy link
Copy Markdown
Collaborator

LGTM! Thanks for contribution!

@AndrewChubatiuk AndrewChubatiuk merged commit aae9947 into VictoriaMetrics:master May 3, 2026
2 checks passed
@onedr0p onedr0p deleted the vm-op-adhooks branch May 11, 2026 23:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

k8s-stack k8s-stack helm chart related issue metrics operator operator helm chart related issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

operator: ignore webhook validation on first install

2 participants