-
Notifications
You must be signed in to change notification settings - Fork 1
/
grafana-ldap.yaml
94 lines (94 loc) · 2.34 KB
/
grafana-ldap.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
apiVersion: v1
kind: ConfigMap
metadata:
name: grafana-ini
labels:
app: grafana
data:
grafana.ini: |
[auth.ldap]
enabled = true
config_file = /etc/grafana/ldap.toml
allow_sign_up = true
[analytics]
check_for_updates = true
[grafana_net]
url = https://grafana.net
[log]
mode = console
[paths]
data = /var/lib/grafana/data
logs = /var/log/grafana
plugins = /var/lib/grafana/plugins
[users]
default_theme = light
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: grafana
spec:
replicas: 1
selector:
matchLabels:
app: grafana
template:
metadata:
name: grafana
labels:
app: grafana
spec:
serviceAccountName: grafana
containers:
- name: grafana
image: docker.io/grafana/grafana:8.5.13
ports:
- name: grafana
containerPort: 3000
env:
- name: GF_SECURITY_ADMIN_USER
valueFrom:
secretKeyRef:
name: grafana-secrect
key: admin-user
- name: GF_SECURITY_ADMIN_PASSWORD
valueFrom:
secretKeyRef:
name: grafana-secrect
key: admin-password
resources:
volumeMounts:
- name: datasources
mountPath: /etc/grafana/provisioning/datasources
readOnly: false
- name: config
mountPath: /etc/grafana/grafana.ini
subPath: grafana.ini
- name: dashboards
mountPath: /var/lib/grafana/dashboards
- name: dashboardproviders
mountPath: /etc/grafana/provisioning/dashboards/
- name: grafana-storage
mountPath: /var/lib/grafana
- name: grafana-ldap
mountPath: /etc/grafana/ldap.toml
subPath: ldap.toml
volumes:
- name: datasources
configMap:
defaultMode: 420
name: grafana-datasources
- name: config
configMap:
name: grafana-ini
- name: dashboardproviders
configMap:
name: grafana-dashboardproviders
- name: dashboards
configMap:
name: grafana-dashboards
- name: grafana-storage
emptyDir: {}
- name: grafana-ldap
secret:
secretName: grafana-ldap-toml