incubator/kube-downscaler - fix a regression about namespaces (#23030)

* Fix a kube-downscaler regression about namespaces

The present fixes a regression where invalid option value 'namespaces' is passed to the tool
and overly generous permissions are granted over namespaces.

Signed-off-by: Danil Mironov <patrungel@gmail.com>

* Delete excessive quotes in arguments

Signed-off-by: Danil Mironov <patrungel@gmail.com>
This commit is contained in:
Danil Mironov
2020-07-01 13:44:01 -07:00
committed by GitHub
parent f8487e2350
commit 35d4b2f944
5 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
name: kube-downscaler
apiVersion: v1
version: 0.4.1
version: 0.4.2
appVersion: 19.10.1
description: A Helm chart for kube-downscaler
home: https://github.com/hjacobs/kube-downscaler
+1 -1
View File
@@ -61,7 +61,7 @@ The following tables lists the configurable parameters of the kube-downscaler ch
| `securityContext` | SecurityContext to apply to the downscaler pod | `{}` |
| `rbac.create` | If true, create & use RBAC resources | `true` |
| `rbac.serviceAccountName` | ServiceAccount downscaler will use (ignored if rbac.create=true) | `default` |
| `downscaleResources` | Resources the downscaler is allowed to manage | `[deployments, statefulsets, namespaces]` |
| `downscaleResources` | Resources the downscaler is allowed to manage | `[deployments, statefulsets]` |
| `excludedDeployments` | Deployments to exclude from the downscaler | `[]` |
| `excludedNamespaces` | Namespaces to exclude from the downscaler | `[]` |
| `extraArgs` | Add extra args to docker command | `[]` |
@@ -13,6 +13,7 @@ rules:
- ""
resources:
- pods
- namespaces
verbs:
- get
- watch
@@ -40,12 +40,12 @@ spec:
{{- if .Values.debug.enable }}
- --debug
{{- end }}
- --include-resources="{{- join "," .Values.downscaleResources }}"
- --include-resources={{- join "," .Values.downscaleResources }}
{{- if .Values.excludedNamespaces }}
- --exclude-namespaces="{{- join "," .Values.excludedNamespaces }}"
- --exclude-namespaces={{- join "," .Values.excludedNamespaces }}
{{- end }}
{{- if .Values.excludedDeployments }}
- --exclude-deployments="{{- join "," .Values.excludedDeployments }}"
- --exclude-deployments={{- join "," .Values.excludedDeployments }}
{{- end }}
{{- with .Values.extraArgs }}
{{ toYaml . | indent 10 }}
-1
View File
@@ -16,7 +16,6 @@ namespace:
downscaleResources:
- deployments
- statefulsets
- namespaces
# List of namespaces to be excluded from the downscaler
excludedNamespaces: []