From 725304165b407ae403f689c95b5487585fc1c8a1 Mon Sep 17 00:00:00 2001 From: VILJkid Date: Thu, 29 Aug 2024 10:38:53 +0530 Subject: [PATCH] (fix) : incorporate changes from pr#581 --- charts/opensearch-dashboards/CHANGELOG.md | 5 ++++- charts/opensearch-dashboards/Chart.yaml | 2 +- charts/opensearch-dashboards/README.md | 3 ++- charts/opensearch-dashboards/templates/service.yaml | 2 ++ charts/opensearch-dashboards/templates/serviceMonitor.yaml | 2 +- charts/opensearch-dashboards/values.yaml | 6 ++---- charts/opensearch/CHANGELOG.md | 5 ++++- charts/opensearch/Chart.yaml | 2 +- charts/opensearch/templates/serviceMonitor.yaml | 2 +- 9 files changed, 18 insertions(+), 11 deletions(-) diff --git a/charts/opensearch-dashboards/CHANGELOG.md b/charts/opensearch-dashboards/CHANGELOG.md index 93326146..f628296a 100644 --- a/charts/opensearch-dashboards/CHANGELOG.md +++ b/charts/opensearch-dashboards/CHANGELOG.md @@ -1,8 +1,10 @@ # Changelog + All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + --- ## [Unreleased] ### Added @@ -484,7 +486,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed ### Security -[Unreleased]: https://github.com/opensearch-project/helm-charts/compare/opensearch-dashboards-1.22.0...HEAD +[Unreleased]: https://github.com/opensearch-project/helm-charts/compare/opensearch-dashboards-1.23.0...HEAD +[1.23.0]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.22.0...opensearch-1.23.0 [1.22.0]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.21.0...opensearch-1.22.0 [1.21.0]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.20.0...opensearch-1.21.0 [1.20.0]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.19.0...opensearch-1.20.0 diff --git a/charts/opensearch-dashboards/Chart.yaml b/charts/opensearch-dashboards/Chart.yaml index 275268a0..a72b794f 100644 --- a/charts/opensearch-dashboards/Chart.yaml +++ b/charts/opensearch-dashboards/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.22.0 +version: 1.23.0 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/charts/opensearch-dashboards/README.md b/charts/opensearch-dashboards/README.md index 4f914fde..fc8ab04a 100644 --- a/charts/opensearch-dashboards/README.md +++ b/charts/opensearch-dashboards/README.md @@ -75,6 +75,8 @@ helm uninstall my-release | `service.type` | OpenSearch [Service Types][] | `ClusterIP` | | `service.ipFamilyPolicy` | This sets the preferred ip addresses in case of a dual-stack server, there are three options [PreferDualStack, SingleStack, RequireDualStack], [more information on dual stack](https://kubernetes.io/docs/concepts/services-networking/dual-stack/) | `""` | | `service.ipFamilies` | Sets the preferred IP variants and in which order they are preferred, the first family you list is used for the legacy .spec.ClusterIP field, [more information on dual stack](https://kubernetes.io/docs/concepts/services-networking/dual-stack/) | `""` | +| `service.metricsPort` | The metrics port (for Performance Analyzer) that Kubernetes will use for the service. | `9601` | +| `service.metricsPortName` | The name of the metrics port (for Performance Analyzer) within the service | `metrics` | | `tolerations` | Configurable [tolerations][] | `[]` | | `updateStrategy` | The [updateStrategy][] for the StatefulSet. By default Kubernetes will wait for the cluster to be green after upgrading each pod. Setting this to `OnDelete` will allow you to manually delete each pod during upgrades | `RollingUpdate` | | `extraObjects` | Array of extra K8s manifests to deploy | list `[]` | @@ -89,7 +91,6 @@ helm uninstall my-release | `serviceMonitor.enabled` | Enables the creation of a [ServiceMonitor] resource for Prometheus monitoring. Requires the Prometheus Operator to be installed in your Kubernetes cluster. | `false` | | `serviceMonitor.path` | Path where metrics are exposed. Applicable only if `serviceMonitor.enabled` is set to `true`. | `/_prometheus/metrics` | | `serviceMonitor.interval` | Interval at which metrics should be scraped by Prometheus. Applicable only if `serviceMonitor.enabled` is set to `true`. | `10s` | -| `metricsPort` | The metrics port (for Performance Analyzer) that Kubernetes will use for the service. | `9601` | [environment from variables]: https://kubernetes.io/docs/tasks/configure-pod-container/configure-pod-configmap/#configure-all-key-value-pairs-in-a-configmap-as-container-environment-variables diff --git a/charts/opensearch-dashboards/templates/service.yaml b/charts/opensearch-dashboards/templates/service.yaml index e520f5c1..e06a8c66 100644 --- a/charts/opensearch-dashboards/templates/service.yaml +++ b/charts/opensearch-dashboards/templates/service.yaml @@ -36,6 +36,8 @@ spec: protocol: TCP name: {{ .Values.service.httpPortName | default "http" }} targetPort: {{ .Values.service.port }} + - name: {{ .Values.service.metricsPortName | default "metrics" }} + port: {{ .Values.service.metricsPort }} selector: app: {{ .Chart.Name }} release: {{ .Release.Name | quote }} diff --git a/charts/opensearch-dashboards/templates/serviceMonitor.yaml b/charts/opensearch-dashboards/templates/serviceMonitor.yaml index a978d88c..1f1a2111 100644 --- a/charts/opensearch-dashboards/templates/serviceMonitor.yaml +++ b/charts/opensearch-dashboards/templates/serviceMonitor.yaml @@ -11,7 +11,7 @@ spec: matchLabels: {{- include "opensearch-dashboards.selectorLabels" . | nindent 6 }} endpoints: - - port: {{ .Values.metricsPort }} + - port: {{ .Values.service.metricsPortName | default "metrics" }} interval: {{ .Values.serviceMonitor.interval }} path: {{ .Values.serviceMonitor.path }} {{- end }} diff --git a/charts/opensearch-dashboards/values.yaml b/charts/opensearch-dashboards/values.yaml index 1fb1bb00..c0dcea7e 100644 --- a/charts/opensearch-dashboards/values.yaml +++ b/charts/opensearch-dashboards/values.yaml @@ -156,6 +156,7 @@ service: # ipFamilies: # - IPv4 port: 5601 + metricsPort: 9601 loadBalancerIP: "" nodePort: "" labels: {} @@ -163,6 +164,7 @@ service: loadBalancerSourceRanges: [] # 0.0.0.0/0 httpPortName: http + metricsPortName: metrics ingress: enabled: false @@ -284,7 +286,3 @@ serviceMonitor: # Frequency at which Prometheus will scrape metrics. # Modify as needed for your monitoring requirements. interval: 10s - -# Port configuration for metrics. -# This should match the port exposed by the OpenSearch Dashboards service. -metricsPort: 9601 diff --git a/charts/opensearch/CHANGELOG.md b/charts/opensearch/CHANGELOG.md index 9f74db67..da5fd917 100644 --- a/charts/opensearch/CHANGELOG.md +++ b/charts/opensearch/CHANGELOG.md @@ -1,8 +1,10 @@ # Changelog + All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + --- ## [Unreleased] ### Added @@ -726,7 +728,8 @@ config: ### Fixed ### Security -[Unreleased]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.29.0...HEAD +[Unreleased]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.30.0...HEAD +[1.30.0]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.29.0...opensearch-1.30.0 [1.29.0]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.28.1...opensearch-1.29.0 [1.28.1]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.28.0...opensearch-1.28.1 [1.28.0]: https://github.com/opensearch-project/helm-charts/compare/opensearch-1.27.0...opensearch-1.28.0 diff --git a/charts/opensearch/Chart.yaml b/charts/opensearch/Chart.yaml index 4bbf8b4c..f4a00193 100644 --- a/charts/opensearch/Chart.yaml +++ b/charts/opensearch/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.29.0 +version: 1.30.0 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/charts/opensearch/templates/serviceMonitor.yaml b/charts/opensearch/templates/serviceMonitor.yaml index 7bc28636..46b324e5 100644 --- a/charts/opensearch/templates/serviceMonitor.yaml +++ b/charts/opensearch/templates/serviceMonitor.yaml @@ -11,7 +11,7 @@ spec: matchLabels: {{- include "opensearch.selectorLabels" . | nindent 6 }} endpoints: - - port: {{ .Values.metricsPort }} + - port: {{ .Values.service.metricsPortName | default "metrics" }} interval: {{ .Values.serviceMonitor.interval }} path: {{ .Values.serviceMonitor.path }} {{- end }}