Skip to content

Commit

Permalink
Add compactor to loki (#426)
Browse files Browse the repository at this point in the history
<!-- Please make sure there is an issue that this PR is correlated to. -->
Fixes RVT-3598
## Changes
- Adds a compactor to loki to remove old logs
<!-- If there are frontend changes, please include screenshots. -->
  • Loading branch information
MasterPtato committed Feb 1, 2024
1 parent 49c0647 commit a22d187
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- **Infra** Prometheus VPA
- **Infra** Apache Traffic Server VPA
- **api-cloud** Admins can view all teams & games in a cluster
- Automatic deploy CI for staging
- Added automatic deploy CI for staging
- **Infra** Added compactor and GC to Loki

### Changed

Expand Down
11 changes: 11 additions & 0 deletions infra/tf/k8s_infra/loki.tf
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,17 @@ resource "helm_release" "loki" {
type = "filesystem"
}
}
compactor = {
retention_enabled = true
retention_delete_delay = "2h"
retention_delete_worker_count = 150
}
tableManager = {
retention_deletes_enabled = true
# NOTE: This must be a multiple of the index period in `schemaConfig`. Default is 24h
# (https://github.com/grafana/loki/blob/main/cmd/loki/loki-local-config.yaml#L34)
retention_period = "24h"
}
singleBinary = {
replicas = 1
resources = var.limit_resources ? {
Expand Down

0 comments on commit a22d187

Please sign in to comment.