Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent PodDisruptionBudget API Versions Prevent Installation on Older Kubernetes Clusters #15876

Open
dadrake3 opened this issue Jan 22, 2025 · 1 comment

Comments

@dadrake3
Copy link

There is inconsistent handling of apiVersion for PodDisruptionBudget templates preventing installation on older Kubernetes clusters.

There are two different ways apiVersion is being set in the templates:

1 Helper Method

apiVersion: {{ include "loki.pdb.apiVersion" . }}

Used in:

templates/overrides-exporter/poddisruptionbudget-overrides-exporter.yaml
templates/chunks-cache/poddisruptionbudget-chunks-cache.yaml
templates/ingester/poddisruptionbudget-ingester.yaml
templates/ingester/poddisruptionbudget-ingester-rollout.yaml
templates/querier/poddisruptionbudget-querier.yaml
templates/bloom-builder/poddisruptionbudget-bloom-builder.yaml
templates/ruler/poddisruptionbudget-ruler.yaml
templates/distributor/poddisruptionbudget-distributor.yaml
templates/query-scheduler/poddisruptionbudget-query-scheduler.yaml
templates/query-frontend/poddisruptionbudget-query-frontend.yaml
templates/index-gateway/poddisruptionbudget-index-gateway.yaml
templates/results-cache/poddisruptionbudget-results-cache.yaml

2 Hardcode

yamlCopyapiVersion: policy/v1

Used in:

templates/backend/poddisruptionbudget-backend.yaml
templates/gateway/poddisruptionbudget-gateway.yaml
templates/read/poddisruptionbudget-read.yaml
templates/single-binary/pdb.yaml
templates/write/poddisruptionbudget-write.yaml

This is causing the kubeVersionOverride value to only affect the templates that use the helper method while the hardcoded method fails on older clusters. Specifically this happens when using scalable mode or when specifying a pdb in single binary mode.

@dadrake3 dadrake3 closed this as completed Feb 3, 2025
@dadrake3 dadrake3 reopened this Feb 3, 2025
@dadrake3
Copy link
Author

dadrake3 commented Feb 3, 2025

I can open I PR to add the helper method to where its being hardcoded

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants