From ec8106d3707c58154be19e9be7200e14497f8dae Mon Sep 17 00:00:00 2001 From: wanjunlei Date: Tue, 14 May 2024 16:25:20 +0800 Subject: [PATCH] release v2.5.2 Signed-off-by: wanjunlei --- CHANGLOG.md | 21 +++++++++++++++++++++ README.md | 10 +++++----- RELEASE.md | 1 + VERSION | 2 +- config/bundle.yaml | 2 +- config/manager/kustomization.yaml | 2 +- config/samples/bundle.yaml | 3 +-- config/samples/notification_manager.yaml | 2 +- helm/values.yaml | 4 ++-- 9 files changed, 34 insertions(+), 13 deletions(-) diff --git a/CHANGLOG.md b/CHANGLOG.md index 3e9ba66b..4592f67a 100644 --- a/CHANGLOG.md +++ b/CHANGLOG.md @@ -1,3 +1,24 @@ +## v2.5.2 / 2024-05-14 + +### Enhancements + +- support to get tenant info from multiple cluster (#263) @wanjunlei +- trim space (#267) @Gentleelephant +- update template (#264) @Gentleelephant +- update helm template (#266) @wanjunlei +- add alerttime to metric alert (#265) @wanjunlei + +### Bugfix + +- Fix Typo in documentation (#262) @mohamed-rafraf + +### Update + +- Bump google.golang.org/protobuf from 1.30.0 to 1.33.0 (#252) @dependabot +- Bump google.golang.org/protobuf from 1.31.0 to 1.33.0 in /sidecar/kubesphere/4.0.0 (#253) @dependabot +- Bump golang.org/x/net from 0.17.0 to 0.23.0 in /sidecar/kubesphere/4.0.0 (#260) @dependabot +- Bump golang.org/x/net from 0.17.0 to 0.23.0 (#261) @dependabot + ## v2.5.1 / 2024-04-03 ### Bugfix diff --git a/README.md b/README.md index 138bc715..33485eed 100644 --- a/README.md +++ b/README.md @@ -82,17 +82,17 @@ We assume you already have a Kubernetes cluster (v1.16+). You can install one us ```shell # Deploy CRDs and the Notification Manager Operator: -kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.1/bundle.yaml +kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.2/bundle.yaml # Deploy default template: -kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.1/template.yaml +kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.2/template.yaml # Deploy built-in language packs. -kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.1/zh-cn.yaml +kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.2/zh-cn.yaml ``` #### Install with helm ```shell -helm install notification-manager --create-namespace -n kubesphere-monitoring-system https://github.com/kubesphere/notification-manager/releases/download/v2.5.1/notification-manager.tgz +helm install notification-manager --create-namespace -n kubesphere-monitoring-system https://github.com/kubesphere/notification-manager/releases/download/v2.5.2/notification-manager.tgz ``` ### Configure NotificationManager @@ -103,7 +103,7 @@ ensures a deployment meeting the resource requirements is running. We should create a NotificationManager CR first, skip this when using helm install. ```shell -kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.1/notification_manager.yaml +kubectl apply -f https://github.com/kubesphere/notification-manager/releases/download/v2.5.2/notification_manager.yaml ``` ### Configure sender diff --git a/RELEASE.md b/RELEASE.md index c53d59c4..e4812564 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -19,6 +19,7 @@ This page describes the release process and the currently planned schedule for u | v2.4.0 | 2023-09-20 | leiwanjun (GitHub: @leiwanjun) | | v2.5.0 | 2024-03-21 | leiwanjun (GitHub: @leiwanjun) | | v2.5.1 | 2024-04-03 | leiwanjun (GitHub: @leiwanjun) | +| v2.5.2 | 2024-04-14 | leiwanjun (GitHub: @leiwanjun) | # How to cut a new release diff --git a/VERSION b/VERSION index 2c3fc419..f6dcb643 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v2.5.1 +v2.5.2 diff --git a/config/bundle.yaml b/config/bundle.yaml index 6d3dd54b..e620ce80 100644 --- a/config/bundle.yaml +++ b/config/bundle.yaml @@ -8044,7 +8044,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: kubesphere/notification-manager-operator:v2.5.1 + image: kubesphere/notification-manager-operator:v2.5.2 imagePullPolicy: Always name: notification-manager-operator ports: diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index 240974e9..8647407e 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -5,4 +5,4 @@ kind: Kustomization images: - name: controller newName: kubesphere/notification-manager-operator - newTag: v2.5.1 + newTag: v2.5.2 diff --git a/config/samples/bundle.yaml b/config/samples/bundle.yaml index 3b16a588..edc002e0 100644 --- a/config/samples/bundle.yaml +++ b/config/samples/bundle.yaml @@ -5,8 +5,7 @@ data: {{ define "nm.default.message.cn" }}{{ if ne (len .Status) 0 }}[{{ .Status | translate }}] {{ end }}{{ .MessageCN }}{{ end }} {{ define "nm.default.subject" }}{{ if eq (len .Alerts) 1 }}{{ range .Alerts }}{{ template "nm.default.message" . }}{{ end }}{{ else }}{{ .Alerts | len }} {{ if ne (len .Status) 0 }}{{ .Status }} {{ end }}alerts{{ if gt (len .GroupLabels.SortedPairs) 0 }} for {{ range .GroupLabels.SortedPairs }}{{ .Name | translate }}={{ .Value }} {{ end }}{{ end }}{{ end }}{{ end }} - {{ define "nm.subject" }}{{ .Alerts | len }} {{ if ne (len .Status) 0 }}{{ .Status }} {{ end }}alerts{{ if gt (len .CommonLabels.SortedPairs) 0 }} for {{ range .CommonLabels.SortedPairs }}{{ .Name | translate }}={{ .Value }} {{ end }}{{ end }}{{ end }} - + {{ define "nm.subject" -}}{{- $rawStatus := .Status -}}{{- $severity := index .CommonLabels "severity" -}}{{- $status := "" -}}{{- if eq $rawStatus "firing" -}}{{- $status = "FIRING" -}}{{- else if eq $rawStatus "resolved" -}}{{- $status = "RESOLVED" -}}{{- else -}}{{- $status = "UNKNOWN" -}}{{- end -}}{{- $numAlerts := len .Alerts -}}{{- if eq $numAlerts 0 -}}Show nothing{{- else if eq $numAlerts 1 -}}{{- range .Alerts -}}{{- $alertType := .Labels.alerttype -}}{{- $alertName := .Labels.alertname -}}{{- $cluster := .Labels.cluster -}}{{- $node := .Labels.node -}}{{- $pod := .Labels.pod -}}{{- $namespace := .Labels.namespace -}}{{- $output := printf "[%s]" $status -}}{{- if $severity -}}{{- $output = printf "%s | severity=%s" $output $severity -}}{{- end -}}{{- if $alertType -}}{{- $output = printf "%s | alerttype=%s" $output $alertType -}}{{- end -}}{{- if $alertName -}}{{- $output = printf "%s | alertname=%s" $output $alertName -}}{{- end -}}{{- if $cluster -}}{{- $output = printf "%s | cluster=%s" $output $cluster -}}{{- end -}}{{- if $node -}}{{- $output = printf "%s | node=%s" $output $node -}}{{- end -}}{{- if $namespace -}}{{- $output = printf "%s | namespace=%s" $output $namespace -}}{{- end -}}{{- if $pod -}}{{- $output = printf "%s | pod=%s" $output $pod -}}{{- end -}}{{- $output -}}{{- end -}}{{- else -}}{{- $alertType := index .GroupLabels "alerttype" -}}{{- $alertName := index .GroupLabels "alertname" -}}{{- $cluster := index .GroupLabels "cluster" -}}{{- $namespace := index .GroupLabels "namespace" -}}{{- $node := index .GroupLabels "node" -}}{{- $output := printf "[%s]" $status -}}{{- if $severity -}}{{- $output = printf "%s | severity=%s" $output $severity -}}{{- end -}}{{- if $alertType -}}{{- $output = printf "%s | alerttype=%s" $output $alertType -}}{{- end -}}{{- if $alertName -}}{{- $output = printf "%s | alertname=%s" $output $alertName -}}{{- end -}}{{- if $cluster -}}{{- $output = printf "%s | cluster=%s" $output $cluster -}}{{- end -}}{{- if $namespace -}}{{- $output = printf "%s | namespace=%s" $output $namespace -}}{{- end -}}{{- if $node -}}{{- $output = printf "%s | node=%s" $output $node -}}{{- end -}}{{- $output -}}{{- end -}}{{- end -}} {{ define "nm.default.text" }}{{ range .Alerts }}{{ template "nm.default.message" . }} {{ range .Labels.SortedPairs }} {{ .Name | translate }}: {{ .Value }} {{ end }}{{ range .Annotations.SortedPairs.Filter "runbook_url" "message" "summary" "summary_cn" }} {{ .Name | translate }}: {{ .Value }} diff --git a/config/samples/notification_manager.yaml b/config/samples/notification_manager.yaml index b9dc8aaa..737ac1a9 100644 --- a/config/samples/notification_manager.yaml +++ b/config/samples/notification_manager.yaml @@ -11,7 +11,7 @@ spec: requests: cpu: 100m memory: 20Mi - image: kubesphere/notification-manager:latest + image: kubesphere/notification-manager:v2.5.2 imagePullPolicy: Always serviceAccountName: notification-manager-sa portName: webhook diff --git a/helm/values.yaml b/helm/values.yaml index 70672a06..b6293adf 100644 --- a/helm/values.yaml +++ b/helm/values.yaml @@ -28,7 +28,7 @@ operator: operator: image: repo: kubesphere/notification-manager-operator - tag: v2.5.1 + tag: v2.5.2 pullPolicy: IfNotPresent resources: limits: @@ -46,7 +46,7 @@ operator: notificationmanager: image: repo: kubesphere/notification-manager - tag: v2.5.1 + tag: v2.5.2 pullPolicy: IfNotPresent sidecar: image: