Skip to content

Commit

Permalink
parametrize kubernetes policy api version (#372)
Browse files Browse the repository at this point in the history
* update apiVersion for podDisruptionBudget

* parametrize kubernetesPolicyVersion
  • Loading branch information
alvarorm22 authored Jun 30, 2023
1 parent 698b58b commit 61030af
Show file tree
Hide file tree
Showing 14 changed files with 15 additions and 13 deletions.
2 changes: 1 addition & 1 deletion chart/templates/accounts-www/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.accountsWww.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.accountsWww.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/cdn-invalidator-sub/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.cdnInvalidatorSub.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.cdnInvalidatorSub.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/http-cache/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.httpCache.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.httpCache.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/import-api/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.importApi.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.importApi.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/import-worker/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.importWorker.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.importWorker.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/lds-api/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.ldsApi.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.ldsApi.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/maps-api/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.mapsApi.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.mapsApi.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/notifier/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.notifier.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.notifier.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/router/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.router.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.router.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/sql-worker/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.sqlWorker.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.sqlWorker.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/workspace-api/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.workspaceApi.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.workspaceApi.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/workspace-subscriber/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.workspaceSubscriber.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.workspaceSubscriber.fullname" . }}-pdb
Expand Down
2 changes: 1 addition & 1 deletion chart/templates/workspace-www/pdb.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if and .Values.workspaceWww.podDisruptionBudget.enabled}}
---
apiVersion: policy/v1beta1
apiVersion: {{ .Values.global.kubernetesPolicyVersion }}
kind: PodDisruptionBudget
metadata:
name: {{ template "carto.workspaceWww.fullname" . }}-pdb
Expand Down
2 changes: 2 additions & 0 deletions chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ commonBackendServiceAccount:
## @param global.imageRegistry Global Docker image registry
## @param global.imagePullSecrets Global Docker registry secret names as an array
## @param global.storageClass Global StorageClass for Persistent Volume(s)
## @param global.kubernetesPolicyVersion Global Default kubernetes api version for policy object
##
global:
imageRegistry: ""
Expand All @@ -252,6 +253,7 @@ global:
##
imagePullSecrets: []
storageClass: ""
kubernetesPolicyVersion: "policy/v1"

## @section Common parameters
##
Expand Down

0 comments on commit 61030af

Please sign in to comment.