diff --git a/README.md b/README.md index 8d966676193f2e42a1c8b4f5f891c4532175a1cc..71608dd7aacbeb2b1647910ee36299ac218a1e89 100644 --- a/README.md +++ b/README.md @@ -637,11 +637,11 @@ In order to configure a static etcd cluster to scrape there is a simple [kube-pr ### Pod Anti-Affinity To prevent `Prometheus` and `Alertmanager` instances from being deployed onto the same node when -possible, one can include the [kube-prometheus-anti-affinity.libsonnet](jsonnet/kube-prometheus/kube-prometheus-anti-affinity.libsonnet) mixin: +possible, one can include the [kube-prometheus-anti-affinity.libsonnet](jsonnet/kube-prometheus/addons/anti-affinity.libsonnet) mixin: ```jsonnet (import 'kube-prometheus/kube-prometheus.libsonnet') + -(import 'kube-prometheus/kube-prometheus-anti-affinity.libsonnet') +(import 'kube-prometheus/addons/anti-affinity.libsonnet') ``` ### Stripping container resource limits diff --git a/jsonnet/kube-prometheus/addons/anti-affinity.libsonnet b/jsonnet/kube-prometheus/addons/anti-affinity.libsonnet index d7a48107fa4eadfc8274ee9535bcd1426ce01f59..2053e950a9bfcb3405bccefa79a3a8fe4ad4be1f 100644 --- a/jsonnet/kube-prometheus/addons/anti-affinity.libsonnet +++ b/jsonnet/kube-prometheus/addons/anti-affinity.libsonnet @@ -45,7 +45,7 @@ alertmanager+: { spec+: antiaffinity( - $.alertmanager.config.selectorLabels, + $.alertmanager._config.selectorLabels, $.values.common.namespace, $.values.alertmanager.podAntiAffinity, $.values.alertmanager.podAntiAffinityTopologyKey, @@ -57,7 +57,7 @@ prometheus+: { spec+: antiaffinity( - $.prometheus.config.selectorLabels, + $.prometheus._config.selectorLabels, $.values.common.namespace, $.values.prometheus.podAntiAffinity, $.values.prometheus.podAntiAffinityTopologyKey, @@ -71,7 +71,7 @@ template+: { spec+: antiaffinity( - $.blackboxExporter.config.selectorLabels, + $.blackboxExporter._config.selectorLabels, $.values.common.namespace, $.values.blackboxExporter.podAntiAffinity, $.values.blackboxExporter.podAntiAffinityTopologyKey, @@ -87,7 +87,7 @@ template+: { spec+: antiaffinity( - $.prometheusAdapter.config.selectorLabels, + $.prometheusAdapter._config.selectorLabels, $.values.common.namespace, $.values.prometheusAdapter.podAntiAffinity, $.values.prometheusAdapter.podAntiAffinityTopologyKey,