From 3aa3ae2de485bdda930e26616464651f2f0f777d Mon Sep 17 00:00:00 2001 From: sayboras Date: Tue, 17 Mar 2020 21:39:50 +1100 Subject: [PATCH 1/3] Add the logLevel configuration in helm charts --- charts/flagger/Chart.yaml | 2 +- charts/flagger/templates/deployment.yaml | 4 ++++ charts/flagger/values.yaml | 3 +++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/charts/flagger/Chart.yaml b/charts/flagger/Chart.yaml index ba9c734c1..4e4b08861 100644 --- a/charts/flagger/Chart.yaml +++ b/charts/flagger/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v1 name: flagger -version: 0.24.0 +version: 0.25.0 appVersion: 1.0.0-rc.1 kubeVersion: ">=1.11.0-0" engine: gotpl diff --git a/charts/flagger/templates/deployment.yaml b/charts/flagger/templates/deployment.yaml index 5d6c5278e..7f21da52f 100644 --- a/charts/flagger/templates/deployment.yaml +++ b/charts/flagger/templates/deployment.yaml @@ -65,7 +65,11 @@ spec: containerPort: 8080 command: - ./flagger + {{- if .Values.logLevel }} + - -log-level={{ .Values.logLevel }} + {{- else }} - -log-level=info + {{- end }} {{- if .Values.meshProvider }} - -mesh-provider={{ .Values.meshProvider }} {{- end }} diff --git a/charts/flagger/values.yaml b/charts/flagger/values.yaml index 24495ef08..59300ecb5 100644 --- a/charts/flagger/values.yaml +++ b/charts/flagger/values.yaml @@ -6,6 +6,9 @@ image: pullPolicy: IfNotPresent pullSecret: +# accepted values are debug, info, warning, error (defaults to info) +logLevel: "info" + podAnnotations: prometheus.io/scrape: "true" prometheus.io/port: "8080" From b02370102ff965d543f7ca714e548fbb36d18a75 Mon Sep 17 00:00:00 2001 From: sayboras Date: Tue, 17 Mar 2020 22:26:48 +1100 Subject: [PATCH 2/3] Revert chart version upgrade Remove if/else for logLevel --- charts/flagger/Chart.yaml | 2 +- charts/flagger/templates/deployment.yaml | 4 ---- charts/flagger/values.yaml | 2 +- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/charts/flagger/Chart.yaml b/charts/flagger/Chart.yaml index 4e4b08861..ba9c734c1 100644 --- a/charts/flagger/Chart.yaml +++ b/charts/flagger/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v1 name: flagger -version: 0.25.0 +version: 0.24.0 appVersion: 1.0.0-rc.1 kubeVersion: ">=1.11.0-0" engine: gotpl diff --git a/charts/flagger/templates/deployment.yaml b/charts/flagger/templates/deployment.yaml index 7f21da52f..2c2115ea2 100644 --- a/charts/flagger/templates/deployment.yaml +++ b/charts/flagger/templates/deployment.yaml @@ -65,11 +65,7 @@ spec: containerPort: 8080 command: - ./flagger - {{- if .Values.logLevel }} - -log-level={{ .Values.logLevel }} - {{- else }} - - -log-level=info - {{- end }} {{- if .Values.meshProvider }} - -mesh-provider={{ .Values.meshProvider }} {{- end }} diff --git a/charts/flagger/values.yaml b/charts/flagger/values.yaml index 59300ecb5..ca9b123a3 100644 --- a/charts/flagger/values.yaml +++ b/charts/flagger/values.yaml @@ -7,7 +7,7 @@ image: pullSecret: # accepted values are debug, info, warning, error (defaults to info) -logLevel: "info" +logLevel: info podAnnotations: prometheus.io/scrape: "true" From f2ef8339d37aa1e0343733d3bd94ef0a85ecf3ba Mon Sep 17 00:00:00 2001 From: sayboras Date: Tue, 17 Mar 2020 22:29:11 +1100 Subject: [PATCH 3/3] Update README.md --- charts/flagger/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/charts/flagger/README.md b/charts/flagger/README.md index f17900d62..dc8df74c4 100644 --- a/charts/flagger/README.md +++ b/charts/flagger/README.md @@ -77,6 +77,7 @@ Parameter | Description | Default `image.repository` | Image repository | `weaveworks/flagger` `image.tag` | Image tag | `` `image.pullPolicy` | Image pull policy | `IfNotPresent` +`logLevel` | Log level | `info` `prometheus.install` | If `true`, installs Prometheus configured to scrape all pods in the custer including the App Mesh sidecar | `false` `metricsServer` | Prometheus URL, used when `prometheus.install` is `false` | `http://prometheus.istio-system:9090` `selectorLabels` | List of labels that Flagger uses to create pod selectors | `app,name,app.kubernetes.io/name`