fix(kube-prometheus-stack): switch to openebs-hostpath and dynamic provisioning prometheus volume

This commit is contained in:
SeanOMik 2024-06-15 16:01:21 -04:00
parent 309dea1760
commit 135beb61fe
Signed by: SeanOMik
GPG Key ID: FEC9E2FC15235964
3 changed files with 6 additions and 26 deletions

View File

@ -1,4 +1,4 @@
apiVersion: helm.toolkit.fluxcd.io/v2beta2
apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
name: kube-prometheus-stack
@ -68,18 +68,15 @@ spec:
storageSpec:
volumeClaimTemplate:
spec:
storageClassName: longhorn
selector:
matchLabels:
app.kubernetes.io/name: kube-prometheus-stack-pv
storageClassName: openebs-hostpath
resources:
requests:
storage: 15Gi
storage: 40Gi
kubeControllerManager:
enabled: true
endpoints:
- 192.168.87.250
- 192.168.10.40
service:
enabled: true
port: 10257
@ -92,7 +89,7 @@ spec:
kubeScheduler:
enabled: true
endpoints:
- 192.168.87.250
- 192.168.10.40
service:
enabled: true
port: 10259
@ -105,7 +102,7 @@ spec:
kubeProxy:
enabled: true
endpoints:
- 192.168.87.250
- 192.168.10.40
service:
enabled: true
port: 10249

View File

@ -1,7 +1,6 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./prom-pv.yaml
- ./helm-repository.yaml
- ./helm-release.yaml
- ./alertmanager-config.yaml

View File

@ -1,16 +0,0 @@
apiVersion: v1
kind: PersistentVolume
metadata:
name: prometheus-pv
namespace: monitoring
labels:
app.kubernetes.io/name: kube-prometheus-stack-pv
spec:
storageClassName: hostpath
persistentVolumeReclaimPolicy: Retain
capacity:
storage: 30Gi
accessModes:
- ReadWriteOnce
hostPath:
path: "/mnt/MainPool/Kubernetes/prometheus"