Skip to content

Commit ee918f2

Browse files
committed
Allow mixins to share dashboard folders: merge config maps.
Signed-off-by: Tom Wilkie <[email protected]>
1 parent 405e8d7 commit ee918f2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

prometheus-ksonnet/grafana/dashboards.libsonnet

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777
// in a single config map. So we split each mixin's dashboards up over
7878
// multiple config maps, depending on the hash of dashboards name.
7979
local sharded_config_maps(name_prefix, shards, dashboards) = {
80-
['%s-%d' % [name_prefix, shard]]:
80+
['%s-%d' % [name_prefix, shard]]+:
8181
configMap.new('%s-%d' % [name_prefix, shard]) +
8282
configMap.withDataMixin({
8383
[name]: std.toString(dashboards[name])
@@ -107,7 +107,7 @@
107107
else
108108
local config_map_name = 'dashboards-%s' % $.folderID(mixin.grafanaDashboardFolder);
109109
acc {
110-
[config_map_name]:
110+
[config_map_name]+:
111111
sharded_config_maps(
112112
config_map_name,
113113
if std.objectHas(mixin, 'grafanaDashboardShards')

0 commit comments

Comments
 (0)