This repository was archived by the owner on Jun 9, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 123
Expand file tree
/
Copy pathgrafana.StatefulSet.yaml
More file actions
66 lines (66 loc) · 1.85 KB
/
grafana.StatefulSet.yaml
File metadata and controls
66 lines (66 loc) · 1.85 KB
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
apiVersion: apps/v1
kind: StatefulSet
metadata:
annotations:
description: Metrics/monitoring dashboards and alerts.
kubectl.kubernetes.io/default-container: grafana
labels:
deploy: sourcegraph
sourcegraph-resource-requires: no-cluster-admin
app.kubernetes.io/component: grafana
name: grafana
spec:
replicas: 1
revisionHistoryLimit: 10
selector:
matchLabels:
app: grafana
serviceName: grafana
updateStrategy:
type: RollingUpdate
template:
metadata:
labels:
app: grafana
deploy: sourcegraph
spec:
containers:
- name: grafana
image: index.docker.io/sourcegraph/grafana:6.3.2692@sha256:211f46d18176b94eab7a1bce0c98252507b732b2bd329f32e90e9e7439163187
terminationMessagePolicy: FallbackToLogsOnError
ports:
- containerPort: 3370
name: http
volumeMounts:
- mountPath: /var/lib/grafana
name: grafana-data
- mountPath: /sg_config_grafana/provisioning/datasources
name: config
# Grafana is relied upon to send alerts to site admins when something is wrong with
# Sourcegraph, thus its memory requests and limits are the same to guarantee it has enough
# memory to perform its job reliably and prevent conflicts with other pods on the same
# host node.
resources:
limits:
cpu: "1"
memory: 512Mi
requests:
cpu: 100m
memory: 512Mi
serviceAccountName: grafana
securityContext:
runAsUser: 0
volumes:
- name: config
configMap:
defaultMode: 0777
name: grafana
volumeClaimTemplates:
- metadata:
name: grafana-data
spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: 2Gi
storageClassName: sourcegraph