Skip to content

How to make data persistent #1801

Answered by pmona
pmona asked this question in General
Discussion options

You must be logged in to vote

I finally got this working. Assuming you have a NFS share working already, next it requires you have a storage class setup. In my deployment, I use the k8s-mgmt namespace instead of the default monitoring.
My storage class name is kube-prometheus-storage.

For setting up the storage class I basically followed this tutorial:
https://www.youtube.com/watch?v=DF3v2P8ENEg&t=1359s

My final config:

---
kind: ServiceAccount
apiVersion: v1
metadata:
  name: kube-prometheus-storage
  namespace: k8s-mgmt
---
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: kube-prometheus-storage-runner
  namespace: k8s-mgmt
rules:
  - apiGroups: [""]
	resources: ["persistentvolumes"]
	ver…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by pmona
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant