-
Notifications
You must be signed in to change notification settings - Fork 11
/
thanos-receive-hashring-0.yaml
122 lines (122 loc) · 3.24 KB
/
thanos-receive-hashring-0.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
apiVersion: apps/v1
kind: StatefulSet
metadata:
labels:
app: thanos-receive
tenant: ab
controller.receive.thanos.io: thanos-receive-controller
controller.receive.thanos.io/hashring: hashring-0
part-of: thanos
name: thanos-receive-hashring-0
namespace: thanos
spec:
replicas: 4
selector:
matchLabels:
app: thanos-receive
tenant: ab
controller.receive.thanos.io: thanos-receive-controller
controller.receive.thanos.io/hashring: hashring-0
part-of: thanos
serviceName: thanos-receive-hashring-0
template:
metadata:
labels:
app: thanos-receive
tenant: ab
controller.receive.thanos.io: thanos-receive-controller
controller.receive.thanos.io/hashring: hashring-0
part-of: thanos
spec:
affinity: {}
containers:
- args:
- receive
- --receive.replication-factor=2
- --objstore.config=$(OBJSTORE_CONFIG)
- --tsdb.path=/var/thanos/receive
- --label=receive_replica="$(NAME)"
- --receive.local-endpoint=$(NAME).thanos-receive-hashring-0.$(NAMESPACE).svc.cluster.local:10901
- --receive.default-tenant-id=ab
- --tsdb.retention=15d
- --receive.hashrings-file=/var/lib/thanos-receive/hashrings.json
env:
- name: NAME
valueFrom:
fieldRef:
fieldPath: metadata.name
- name: NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
- name: OBJSTORE_CONFIG
valueFrom:
secretKeyRef:
key: thanos-s3.yaml
name: thanos-objectstorage
image: quay.io/thanos/thanos:v0.14.0
livenessProbe:
failureThreshold: 8
httpGet:
path: /-/healthy
port: 10902
scheme: HTTP
periodSeconds: 30
name: thanos-receive
ports:
- containerPort: 10901
name: grpc
- containerPort: 10902
name: http
- containerPort: 19291
name: remote-write
readinessProbe:
failureThreshold: 20
httpGet:
path: /-/ready
port: 10902
scheme: HTTP
periodSeconds: 5
terminationMessagePolicy: FallbackToLogsOnError
volumeMounts:
- mountPath: /var/thanos/receive
name: data
readOnly: false
- mountPath: /var/lib/thanos-receive
name: hashring-config
terminationGracePeriodSeconds: 900
volumes:
- emptyDir: {}
name: data
- configMap:
name: thanos-receive-generated
name: hashring-config
---
apiVersion: v1
kind: Service
metadata:
labels:
app: thanos-receive
tenant: ab
controller.receive.thanos.io/hashring: hashring-0
part-of: thanos
name: thanos-receive-hashring-0
namespace: thanos
spec:
clusterIP: None
ports:
- name: grpc
port: 10901
targetPort: 10901
- name: http
port: 10902
targetPort: 10902
- name: remote-write
port: 19291
targetPort: 19291
selector:
app: thanos-receive
tenant: ab
controller.receive.thanos.io: thanos-receive-controller
controller.receive.thanos.io/hashring: hashring-0
part-of: thanos