Switch Loki to storing in bucket

This commit is contained in:
Marcus Noble 2020-09-18 20:12:11 +01:00
parent 3ab7377253
commit 295bb89828
2 changed files with 39 additions and 8 deletions

View File

@ -13,6 +13,17 @@ metadata:
kube-1password/vault: Kubernetes kube-1password/vault: Kubernetes
type: Opaque type: Opaque
--- ---
apiVersion: v1
kind: Secret
metadata:
name: loki-values
namespace: logging
annotations:
kube-1password: 6u6ebtofcxbr5r4q7k5wkc5zea
kube-1password/vault: Kubernetes
kube-1password/secret-text-key: values.yaml
type: Opaque
---
apiVersion: helm.fluxcd.io/v1 apiVersion: helm.fluxcd.io/v1
kind: HelmRelease kind: HelmRelease
metadata: metadata:
@ -22,18 +33,31 @@ spec:
chart: chart:
repository: https://grafana.github.io/loki/charts repository: https://grafana.github.io/loki/charts
name: loki-stack name: loki-stack
version: 0.40.0 version: 0.40.1
maxHistory: 4 maxHistory: 4
skipCRDs: false skipCRDs: false
valuesFrom:
- secretKeyRef:
name: loki-values
namespace: logging
key: values.yaml
optional: false
values: values:
fluent-bit: fluent-bit:
enabled: "true" enabled: "true"
promtail: promtail:
enabled: "true" enabled: "true"
loki: loki:
persistence: config:
enabled: "true" schema_config:
size: 10Gi configs:
- from: "2018-04-15"
index:
period: 120h
prefix: index_
object_store: s3
schema: v9
store: boltdb
--- ---
apiVersion: helm.fluxcd.io/v1 apiVersion: helm.fluxcd.io/v1
@ -45,18 +69,16 @@ spec:
chart: chart:
repository: https://kubernetes-charts.storage.googleapis.com repository: https://kubernetes-charts.storage.googleapis.com
name: grafana name: grafana
version: 5.0.22 version: 5.5.7
maxHistory: 4 maxHistory: 4
skipCRDs: false skipCRDs: false
values: values:
image: image:
tag: 7.0.0 tag: 7.1.1
admin: admin:
existingSecret: "grafana-credentials" existingSecret: "grafana-credentials"
userKey: username userKey: username
passwordKey: password passwordKey: password
persistence:
enabled: "false"
datasources: datasources:
datasources.yaml: datasources.yaml:
apiVersion: 1 apiVersion: 1

View File

@ -24,3 +24,12 @@ resource "scaleway_object_bucket" "outline" {
output "outline-bucket_id" { output "outline-bucket_id" {
value = scaleway_object_bucket.outline.id value = scaleway_object_bucket.outline.id
} }
resource "scaleway_object_bucket" "logs" {
name = "cluster.fun-logs"
acl = "private"
}
output "logs-bucket_id" {
value = scaleway_object_bucket.logs.id
}