Skip to content

Commit

Permalink
fix config for statefulset rulers when using boltdb-shipper (grafana#…
Browse files Browse the repository at this point in the history
…3329)

Signed-off-by: Cyril Tovena <cyril.tovena@gmail.com>
  • Loading branch information
sandeepsukhani authored and cyriltovena committed Feb 15, 2021
1 parent 0dd3795 commit e93ee8b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
1 change: 0 additions & 1 deletion production/ksonnet/loki/boltdb_shipper.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
// run ingesters and queriers as statefulsets when using boltdb-shipper to avoid using node disk for storing the index.
stateful_ingesters: if self.using_boltdb_shipper then true else super.stateful_ingesters,
stateful_queriers: if self.using_boltdb_shipper then true else super.stateful_queriers,
stateful_rulers: if self.using_boltdb_shipper then true else super.stateful_rulers,

boltdb_shipper_shared_store: error 'must define boltdb_shipper_shared_store when using_boltdb_shipper=true. If this is not intentional, consider disabling it. boltdb_shipper_shared_store is a backend key from the storage_config, such as (gcs) or (s3)',
compactor_pvc_size: '10Gi',
Expand Down
8 changes: 8 additions & 0 deletions production/ksonnet/loki/ruler.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@

ruler_args:: $._config.commonArgs {
target: 'ruler',
} + if $._config.using_boltdb_shipper then {
// Use PVC for caching
'boltdb.shipper.cache-location': '/data/boltdb-cache',
} else {},

_config+:: {
// run rulers as statefulsets when using boltdb-shipper to avoid using node disk for storing the index.
stateful_rulers: if self.using_boltdb_shipper then true else super.stateful_rulers,
},

ruler_container::
Expand Down

0 comments on commit e93ee8b

Please sign in to comment.