diff --git a/CHANGELOG.md b/CHANGELOG.md index 073dc51..2d406cc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,14 @@ In the previous version, if the `prometheus_adapter_chart_version` variable was **If you are not using the Prometheus Adapter (you do not specify the `prometheus_adapter_chart_version` variable in your configuration)**, you can safely ignore this breaking change. +If you receive the following error message during the upgrade: + +```bash +cannot patch "kube-prometheus-stack-prometheus-node-exporter" with kind DaemonSet: DaemonSet.apps "kube-prometheus-stack-prometheus-node-exporter" is invalid: spec.selector: Invalid value: v1.LabelSelector{MatchLabels:map[string]string{"app.kubernetes.io/instance":"kube-prometheus-stack", "app.kubernetes.io/name":"prometheus-node-exporter"}, MatchExpressions:[]v1.LabelSelectorRequirement(nil)}: field is immutable +``` + +you can delete the `DaemonSet` (`kubectl delete daemonsets kube-prometheus-stack-prometheus-node-exporter`) resource and apply the changes again. The helm release will recreate the `DaemonSet` resource with the correct selector. The only drawback is that you will lose the metrics collected by the `DaemonSet` during the downtime. + ### Added - Add the default versions for `prometheus_stack_chart_version` and `prometheus_adapter_chart_version` variables. These values indicate the default chart version to use and the reference to the shipped chart values. diff --git a/README.md b/README.md index 9997868..05ae731 100644 --- a/README.md +++ b/README.md @@ -65,13 +65,13 @@ module "kube_prometheus_stack" { } ``` -# Upgrading from 3.X.Y to 4.0.0 +# Upgrading from 3.Y.Z to 4.0.0 For the upgrading note, see the [CHANGELOG](./CHANGELOG.md#400---2024-05-31) note for the `4.0.0` release. -# Upgrading from 2.X.Y to 3.0.0 +# Upgrading from 2.Y.Z to 3.0.0 -Upgrading to `3.0.0` from `2.X.Y` will cause the destruction of the namespace and the basic auth secret. +Upgrading to `3.0.0` from `2.Y.Z` will cause the destruction of the namespace and the basic auth secret. You will need to remove these resources from the state and import them in the new `v1` resources. ```bash