diff --git a/CHANGELOG.md b/CHANGELOG.md index 854dc3cd..002520fb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## master / unreleased +* [CHANGE] `namespace` template variable in dashboards now only selects namespaces for selected clusters. #311 + ## 1.9.0 / 2021-05-18 * [CHANGE] Replace use of removed Cortex CLI flag `-querier.compress-http-responses` for query frontend with `-api.response-compression-enabled`. #299 diff --git a/cortex-mixin/dashboards/dashboard-utils.libsonnet b/cortex-mixin/dashboards/dashboard-utils.libsonnet index f79c27af..1ba99603 100644 --- a/cortex-mixin/dashboards/dashboard-utils.libsonnet +++ b/cortex-mixin/dashboards/dashboard-utils.libsonnet @@ -36,13 +36,13 @@ local utils = import 'mixin-utils/utils.libsonnet'; then d.addMultiTemplate('job', 'cortex_build_info', 'job') else d .addMultiTemplate('cluster', 'cortex_build_info', 'cluster') - .addMultiTemplate('namespace', 'cortex_build_info', 'namespace') + .addMultiTemplate('namespace', 'cortex_build_info{cluster=~"$cluster"}', 'namespace') else if $._config.singleBinary then d.addTemplate('job', 'cortex_build_info', 'job') else d .addTemplate('cluster', 'cortex_build_info', 'cluster') - .addTemplate('namespace', 'cortex_build_info', 'namespace'), + .addTemplate('namespace', 'cortex_build_info{cluster=~"$cluster"}', 'namespace'), },