102 lines
2.2 KiB
YAML
102 lines
2.2 KiB
YAML
---
|
|
apiVersion: v1
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: grafana-cm
|
|
data:
|
|
grafana-ini: |-
|
|
app_mode = production
|
|
[server]
|
|
root_url = http://grafana.beaconfireinc.com
|
|
[database]
|
|
type = mysql
|
|
host = mysql-nacos.base.svc:3306
|
|
name = grafana
|
|
user = root
|
|
password = Admin@2099
|
|
[smtp]
|
|
enabled = true
|
|
host = smtp.gmail.com:587
|
|
user = do-not-reply@beaconfireinc.com
|
|
password = Beaconfire2024!
|
|
skip_verify = true
|
|
from_address = do-not-reply@beaconfireinc.com
|
|
from_name = Bfs-Grafana
|
|
;startTLS_policy = NoStartTLS
|
|
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
labels:
|
|
app: grafana
|
|
name: grafana
|
|
spec:
|
|
selector:
|
|
matchLabels:
|
|
app: grafana
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: grafana
|
|
spec:
|
|
securityContext:
|
|
fsGroup: 472
|
|
supplementalGroups:
|
|
- 0
|
|
containers:
|
|
- name: grafana
|
|
image: grafana/grafana:latest
|
|
imagePullPolicy: IfNotPresent
|
|
ports:
|
|
- containerPort: 3000
|
|
name: http-grafana
|
|
protocol: TCP
|
|
readinessProbe:
|
|
failureThreshold: 3
|
|
httpGet:
|
|
path: /robots.txt
|
|
port: 3000
|
|
scheme: HTTP
|
|
initialDelaySeconds: 10
|
|
periodSeconds: 30
|
|
successThreshold: 1
|
|
timeoutSeconds: 2
|
|
livenessProbe:
|
|
failureThreshold: 3
|
|
initialDelaySeconds: 30
|
|
periodSeconds: 10
|
|
successThreshold: 1
|
|
tcpSocket:
|
|
port: 3000
|
|
timeoutSeconds: 1
|
|
resources:
|
|
requests:
|
|
cpu: 50m
|
|
memory: 750Mi
|
|
volumeMounts:
|
|
- name: grafana-cm
|
|
mountPath: /etc/grafana/grafana.ini
|
|
subPath: grafana.ini
|
|
readOnly: true
|
|
volumes:
|
|
- name: grafana-cm
|
|
configMap:
|
|
name: grafana-cm
|
|
items:
|
|
- key: grafana-ini
|
|
path: grafana.ini
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: grafana
|
|
spec:
|
|
ports:
|
|
- port: 3000
|
|
protocol: TCP
|
|
targetPort: http-grafana
|
|
selector:
|
|
app: grafana
|
|
sessionAffinity: None
|
|
type: ClusterIP |