update thanos

This commit is contained in:
Remy Moll 2024-06-10 00:01:57 +02:00
parent 3c71ac8411
commit 806b42874c
4 changed files with 19 additions and 42 deletions

View File

@ -31,7 +31,7 @@ datasources:
datasources: datasources:
- name: Thanos - name: Thanos
type: prometheus type: prometheus
url: http://thanos-querier.prometheus.svc:9090 url: http://thanos-querier.prometheus.svc:10902
isDefault: true isDefault: true
- name: Prometheus - name: Prometheus
type: prometheus type: prometheus

View File

@ -4,7 +4,7 @@ metadata:
name: prometheus name: prometheus
--- ---
apiVersion: rbac.authorization.k8s.io/v1 apiVersion: rbac.authorization.k8s.io/v1
knd: ClusterRole kind: ClusterRole
metadata: metadata:
name: prometheus name: prometheus
rules: rules:
@ -52,26 +52,17 @@ spec:
requests: requests:
memory: 400Mi memory: 400Mi
retention: 730d retention: 730d
retentionSize: 50Gi retentionSize: 3GiB
serviceAccountName: prometheus serviceAccountName: prometheus
enableAdminAPI: false enableAdminAPI: false
serviceMonitorNamespaceSelector: {} serviceMonitorNamespaceSelector: {}
serviceMonitorSelector: {} serviceMonitorSelector: {}
thanos: thanos:
version: v0.33.0 version: v0.34.1
objectStorageConfig: objectStorageConfig:
# loads the config from a secret named thanos-objstore-config in the same namespace # loads the config from a secret named thanos-objstore-config in the same namespace
key: thanos.yaml key: thanos.yaml
name: thanos-objstore-config name: thanos-objstore-config
volumeClaimTemplate:
metadata:
name: prometheus-data
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 50Gi
--- ---
apiVersion: v1 apiVersion: v1
kind: Service kind: Service

View File

@ -52,16 +52,4 @@ spec:
- name: grpc - name: grpc
protocol: TCP protocol: TCP
port: 10901 port: 10901
targetPort: grpc targetPort: grpc
metadata:
labels:
app: thanos-querier
name: thanos-querier
spec:
ports:
- port: 9090
protocol: TCP
targetPort: http
name: http
selector:
app: thanos-querier

View File

@ -1,33 +1,32 @@
apiVersion: apps/v1 apiVersion: apps/v1
kind: StatefulSet kind: Deployment
metadata: metadata:
name: thanos-store-gateway name: thanos-store
labels: labels:
app: thanos-store-gateway app: thanos-store
spec: spec:
replicas: 1 replicas: 1
selector: selector:
matchLabels: matchLabels:
app: thanos-store-gateway app: thanos-store
serviceName: thanos-store-gateway
template: template:
metadata: metadata:
labels: labels:
app: thanos-store-gateway app: thanos-store
thanos-store-api: "true" thanos-store-api: "true"
spec: spec:
containers: containers:
- name: thanos - name: thanos
image: thanos image: thanos
args: args:
- "store" - store
- "--log.level=debug" - --log.level=debug
- "--data-dir=/data" - --data-dir=/data
- "--grpc-address=0.0.0.0:10901" - --grpc-address=0.0.0.0:10901
- "--http-address=0.0.0.0:10902" - --http-address=0.0.0.0:10902
- "--objstore.config-file=/etc/secret/thanos.yaml" - --objstore.config-file=/etc/secret/thanos.yaml
- "--index-cache-size=500MB" - --index-cache-size=500MB
- "--chunk-pool-size=500MB" - --chunk-pool-size=500MB
ports: ports:
- name: http - name: http
containerPort: 10902 containerPort: 10902
@ -61,7 +60,6 @@ metadata:
app.kubernetes.io/name: thanos-store app.kubernetes.io/name: thanos-store
name: thanos-store name: thanos-store
spec: spec:
clusterIP: None
ports: ports:
- name: grpc - name: grpc
port: 10901 port: 10901
@ -70,4 +68,4 @@ spec:
port: 10902 port: 10902
targetPort: 10902 targetPort: 10902
selector: selector:
app: thanos-store-gateway app: thanos-store