grafana-deployment.yaml 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. apiVersion: apps/v1
  2. kind: Deployment
  3. metadata:
  4. labels:
  5. app: grafana
  6. name: grafana
  7. namespace: monitoring
  8. spec:
  9. replicas: 1
  10. selector:
  11. matchLabels:
  12. app: grafana
  13. template:
  14. metadata:
  15. labels:
  16. app: grafana
  17. spec:
  18. containers:
  19. - env: []
  20. image: grafana/grafana:latest
  21. name: grafana
  22. ports:
  23. - containerPort: 3000
  24. name: http
  25. readinessProbe:
  26. httpGet:
  27. path: /api/health
  28. port: http
  29. resources:
  30. limits:
  31. cpu: 200m
  32. memory: 200Mi
  33. requests:
  34. cpu: 100m
  35. memory: 100Mi
  36. volumeMounts:
  37. - mountPath: /var/lib/grafana
  38. name: grafana-storage
  39. readOnly: false
  40. securityContext:
  41. fsGroup: 65534
  42. runAsNonRoot: true
  43. runAsUser: 65534
  44. serviceAccountName: grafana
  45. volumes:
  46. - name: grafana-storage
  47. persistentVolumeClaim:
  48. claimName: grafana-pvc