Skip to content

Commit

Permalink
Add overrides to compactor
Browse files Browse the repository at this point in the history
Signed-off-by: Goutham Veeramachaneni <gouthamve@gmail.com>
  • Loading branch information
gouthamve committed Sep 2, 2021
1 parent dda3e68 commit 4d40ca6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
3 changes: 3 additions & 0 deletions cortex/config.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,9 @@
// 300 rules
ruler_max_rules_per_rule_group: 15,
ruler_max_rule_groups_per_tenant: 20,

// No retention for now.
compactor_blocks_retention_period: 0,
},

medium_small_user:: {
Expand Down
7 changes: 6 additions & 1 deletion cortex/tsdb.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,10 @@
'compactor.ring.store': 'consul',
'compactor.ring.consul.hostname': 'consul.%s.svc.cluster.local:8500' % $._config.namespace,
'compactor.ring.prefix': '',

// Limits config.
'runtime-config.file': '/etc/cortex/overrides.yaml',
'compactor.blocks-retention-period': $._config.limits.compactor_blocks_retention_period,
},

compactor_ports:: $.util.defaultPorts,
Expand Down Expand Up @@ -187,7 +191,8 @@
// one by one. This does NOT affect rolling updates: they will continue to be
// rolled out one by one (the next pod will be rolled out once the previous is
// ready).
statefulSet.mixin.spec.withPodManagementPolicy('Parallel'),
statefulSet.mixin.spec.withPodManagementPolicy('Parallel') +
$.util.configVolumeMount($._config.overrides_configmap, '/etc/cortex'),

compactor_statefulset:
$.newCompactorStatefulSet('compactor', $.compactor_container),
Expand Down

0 comments on commit 4d40ca6

Please sign in to comment.