diff --git a/bitnami/kubeapps/CHANGELOG.md b/bitnami/kubeapps/CHANGELOG.md index 7378c73408..40f3f97e6d 100644 --- a/bitnami/kubeapps/CHANGELOG.md +++ b/bitnami/kubeapps/CHANGELOG.md @@ -1,8 +1,12 @@ # Changelog -## 15.1.2 (2024-06-03) +## 15.2.0 (2024-06-03) -* [bitnami/kubeapps] Release 15.1.2 ([#26573](https://github.com/bitnami/charts/pull/26573)) +* [bitnami/kubeapps] Enable PodDisruptionBudgets ([#26505](https://github.com/bitnami/charts/pull/26505)) + +## 15.1.2 (2024-06-03) + +* [bitnami/kubeapps] Release 15.1.2 (#26573) ([a1ac42b](https://github.com/bitnami/charts/commit/a1ac42b09c572000f01b7159699cc399aef3d875)), closes [#26573](https://github.com/bitnami/charts/issues/26573) ## 15.1.1 (2024-05-22) diff --git a/bitnami/kubeapps/Chart.yaml b/bitnami/kubeapps/Chart.yaml index 31670f5542..4d62da274f 100644 --- a/bitnami/kubeapps/Chart.yaml +++ b/bitnami/kubeapps/Chart.yaml @@ -52,4 +52,5 @@ maintainers: name: kubeapps sources: - https://github.com/bitnami/charts/tree/main/bitnami/kubeapps -version: 15.1.2 +version: 15.2.0 + diff --git a/bitnami/kubeapps/README.md b/bitnami/kubeapps/README.md index d44f954aa2..df992e99b3 100644 --- a/bitnami/kubeapps/README.md +++ b/bitnami/kubeapps/README.md @@ -269,6 +269,9 @@ In the first two cases, it is needed a certificate and a key. We would expect th | `frontend.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for frontend container(s) | `[]` | | `frontend.sidecars` | Add additional sidecar containers to the frontend pod | `[]` | | `frontend.initContainers` | Add additional init containers to the frontend pods | `[]` | +| `frontend.pdb.create` | Enable/disable a Pod Disruption Budget creation | `false` | +| `frontend.pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` | +| `frontend.pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `frontend.pdb.minAvailable` and `frontend.pdb.maxUnavailable` are empty. | `""` | | `frontend.service.type` | Frontend service type | `ClusterIP` | | `frontend.service.ports.http` | Frontend service HTTP port | `80` | | `frontend.service.nodePorts.http` | Node port for HTTP | `""` | @@ -374,6 +377,9 @@ In the first two cases, it is needed a certificate and a key. We would expect th | `dashboard.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for Dashboard container(s) | `[]` | | `dashboard.sidecars` | Add additional sidecar containers to the Dashboard pod | `[]` | | `dashboard.initContainers` | Add additional init containers to the Dashboard pods | `[]` | +| `dashboard.pdb.create` | Enable/disable a Pod Disruption Budget creation | `false` | +| `dashboard.pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` | +| `dashboard.pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `dashboard.pdb.minAvailable` and `dashboard.pdb.maxUnavailable` are empty. | `""` | | `dashboard.service.ports.http` | Dashboard service HTTP port | `8080` | | `dashboard.service.annotations` | Additional custom annotations for Dashboard service | `{}` | | `dashboard.networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` | @@ -454,6 +460,9 @@ In the first two cases, it is needed a certificate and a key. We would expect th | `apprepository.hostAliases` | Custom host aliases for AppRepository Controller pods | `[]` | | `apprepository.sidecars` | Add additional sidecar containers to the AppRepository Controller pod(s) | `[]` | | `apprepository.initContainers` | Add additional init containers to the AppRepository Controller pod(s) | `[]` | +| `apprepository.pdb.create` | Enable/disable a Pod Disruption Budget creation | `false` | +| `apprepository.pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` | +| `apprepository.pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `apprepository.pdb.minAvailable` and `apprepository.pdb.maxUnavailable` are empty. | `""` | | `apprepository.networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` | | `apprepository.networkPolicy.allowExternalEgress` | Allow the pod to access any range of port and all destinations. | `true` | | `apprepository.networkPolicy.kubeAPIServerPorts` | List of possible endpoints to kube-apiserver (limit to your cluster settings to increase security) | `[]` | @@ -671,6 +680,9 @@ In the first two cases, it is needed a certificate and a key. We would expect th | `kubeappsapis.hostAliases` | Custom host aliases for KubeappsAPIs pods | `[]` | | `kubeappsapis.sidecars` | Add additional sidecar containers to the KubeappsAPIs pod(s) | `[]` | | `kubeappsapis.initContainers` | Add additional init containers to the KubeappsAPIs pod(s) | `[]` | +| `kubeappsapis.pdb.create` | Enable/disable a Pod Disruption Budget creation | `false` | +| `kubeappsapis.pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` | +| `kubeappsapis.pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `kubeappsapis.pdb.minAvailable` and `kubeappsapis.pdb.maxUnavailable` are empty. | `""` | | `kubeappsapis.service.ports.http` | KubeappsAPIs service HTTP port | `8080` | | `kubeappsapis.service.annotations` | Additional custom annotations for KubeappsAPIs service | `{}` | | `kubeappsapis.networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` | diff --git a/bitnami/kubeapps/templates/apprepository/pdb.yaml b/bitnami/kubeapps/templates/apprepository/pdb.yaml new file mode 100644 index 0000000000..a71a363551 --- /dev/null +++ b/bitnami/kubeapps/templates/apprepository/pdb.yaml @@ -0,0 +1,30 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.packaging.helm.enabled .Values.apprepository.pdb.create }} +apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} +kind: PodDisruptionBudget +metadata: + name: {{ template "kubeapps.apprepository.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + {{- $versionLabel := dict "app.kubernetes.io/version" ( include "common.images.version" ( dict "imageRoot" .Values.apprepository.image "chart" .Chart ) ) }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.commonLabels $versionLabel ) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: apprepository + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.apprepository.pdb.minAvailable }} + minAvailable: {{ .Values.apprepository.pdb.minAvailable }} + {{- end }} + {{- if or .Values.apprepository.pdb.maxUnavailable ( not .Values.apprepository.pdb.minAvailable ) }} + maxUnavailable: {{ .Values.apprepository.pdb.maxUnavailable | default 1 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.apprepository.podLabels .Values.commonLabels $versionLabel ) "context" . ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/component: apprepository +{{- end }} diff --git a/bitnami/kubeapps/templates/dashboard/pdb.yaml b/bitnami/kubeapps/templates/dashboard/pdb.yaml new file mode 100644 index 0000000000..675784024d --- /dev/null +++ b/bitnami/kubeapps/templates/dashboard/pdb.yaml @@ -0,0 +1,30 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.dashboard.enabled .Values.dashboard.pdb.create }} +apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} +kind: PodDisruptionBudget +metadata: + name: {{ template "kubeapps.dashboard.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + {{- $versionLabel := dict "app.kubernetes.io/version" ( include "common.images.version" ( dict "imageRoot" .Values.dashboard.image "chart" .Chart ) ) }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.commonLabels $versionLabel ) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: dashboard + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.dashboard.pdb.minAvailable }} + minAvailable: {{ .Values.dashboard.pdb.minAvailable }} + {{- end }} + {{- if or .Values.dashboard.pdb.maxUnavailable ( not .Values.dashboard.pdb.minAvailable ) }} + maxUnavailable: {{ .Values.dashboard.pdb.maxUnavailable | default 1 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.dashboard.podLabels .Values.commonLabels $versionLabel ) "context" . ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/component: dashboard +{{- end }} diff --git a/bitnami/kubeapps/templates/frontend/pdb.yaml b/bitnami/kubeapps/templates/frontend/pdb.yaml new file mode 100644 index 0000000000..3e9a8ec241 --- /dev/null +++ b/bitnami/kubeapps/templates/frontend/pdb.yaml @@ -0,0 +1,30 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.frontend.pdb.create }} +apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} +kind: PodDisruptionBudget +metadata: + name: {{ template "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + {{- $versionLabel := dict "app.kubernetes.io/version" ( include "common.images.version" ( dict "imageRoot" .Values.frontend.image "chart" .Chart ) ) }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.commonLabels $versionLabel ) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: frontend + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.frontend.pdb.minAvailable }} + minAvailable: {{ .Values.frontend.pdb.minAvailable }} + {{- end }} + {{- if or .Values.frontend.pdb.maxUnavailable ( not .Values.frontend.pdb.minAvailable ) }} + maxUnavailable: {{ .Values.frontend.pdb.maxUnavailable | default 1 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.frontend.podLabels .Values.commonLabels $versionLabel ) "context" . ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/component: frontend +{{- end }} diff --git a/bitnami/kubeapps/templates/kubeappsapis/pdb.yaml b/bitnami/kubeapps/templates/kubeappsapis/pdb.yaml new file mode 100644 index 0000000000..d5a2713632 --- /dev/null +++ b/bitnami/kubeapps/templates/kubeappsapis/pdb.yaml @@ -0,0 +1,30 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.kubeappsapis.pdb.create }} +apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} +kind: PodDisruptionBudget +metadata: + name: {{ template "kubeapps.kubeappsapis.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + {{- $versionLabel := dict "app.kubernetes.io/version" ( include "common.images.version" ( dict "imageRoot" .Values.kubeappsapis.image "chart" .Chart ) ) }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.commonLabels $versionLabel ) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: kubeappsapis + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.kubeappsapis.pdb.minAvailable }} + minAvailable: {{ .Values.kubeappsapis.pdb.minAvailable }} + {{- end }} + {{- if or .Values.kubeappsapis.pdb.maxUnavailable ( not .Values.kubeappsapis.pdb.minAvailable ) }} + maxUnavailable: {{ .Values.kubeappsapis.pdb.maxUnavailable | default 1 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.kubeappsapis.podLabels .Values.commonLabels $versionLabel ) "context" . ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/component: kubeappsapis +{{- end }} diff --git a/bitnami/kubeapps/values.yaml b/bitnami/kubeapps/values.yaml index a6afa3c83e..39bd71b744 100644 --- a/bitnami/kubeapps/values.yaml +++ b/bitnami/kubeapps/values.yaml @@ -484,6 +484,16 @@ frontend: ## command: ['sh', '-c', 'echo "hello world"'] ## initContainers: [] + ## Pod Disruption Budget configuration + ## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb + ## @param frontend.pdb.create Enable/disable a Pod Disruption Budget creation + ## @param frontend.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled + ## @param frontend.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `frontend.pdb.minAvailable` and `frontend.pdb.maxUnavailable` are empty. + ## + pdb: + create: false + minAvailable: "" + maxUnavailable: "" ## Frontend service parameters ## service: @@ -922,6 +932,16 @@ dashboard: ## command: ['sh', '-c', 'echo "hello world"'] ## initContainers: [] + ## Pod Disruption Budget configuration + ## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb + ## @param dashboard.pdb.create Enable/disable a Pod Disruption Budget creation + ## @param dashboard.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled + ## @param dashboard.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `dashboard.pdb.minAvailable` and `dashboard.pdb.maxUnavailable` are empty. + ## + pdb: + create: false + minAvailable: "" + maxUnavailable: "" ## Dashboard service parameters ## service: @@ -1312,6 +1332,16 @@ apprepository: ## command: ['sh', '-c', 'echo "hello world"'] ## initContainers: [] + ## Pod Disruption Budget configuration + ## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb + ## @param apprepository.pdb.create Enable/disable a Pod Disruption Budget creation + ## @param apprepository.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled + ## @param apprepository.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `apprepository.pdb.minAvailable` and `apprepository.pdb.maxUnavailable` are empty. + ## + pdb: + create: false + minAvailable: "" + maxUnavailable: "" ## Network Policies ## Ref: https://kubernetes.io/docs/concepts/services-networking/network-policies/ ## @@ -2134,6 +2164,16 @@ kubeappsapis: ## command: ['sh', '-c', 'echo "hello world"'] ## initContainers: [] + ## Pod Disruption Budget configuration + ## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb + ## @param kubeappsapis.pdb.create Enable/disable a Pod Disruption Budget creation + ## @param kubeappsapis.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled + ## @param kubeappsapis.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `kubeappsapis.pdb.minAvailable` and `kubeappsapis.pdb.maxUnavailable` are empty. + ## + pdb: + create: false + minAvailable: "" + maxUnavailable: "" ## kubeappsapis service parameters ## service: