feat(loki): Add volume backup through Longhorn
This commit is contained in:
parent
d84d06d1f5
commit
a51063e828
@ -12,6 +12,10 @@ spec:
|
||||
labels:
|
||||
app: loki
|
||||
spec:
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
fsGroup: 2000
|
||||
runAsUser: 1000
|
||||
containers:
|
||||
- name: loki
|
||||
image: grafana/loki:2.8.2
|
||||
@ -19,10 +23,15 @@ spec:
|
||||
ports:
|
||||
- containerPort: 3100
|
||||
volumeMounts:
|
||||
- name: loki-pv
|
||||
mountPath: /loki
|
||||
- name: loki-config-volume
|
||||
mountPath: /mnt/config/loki-config.yaml
|
||||
subPath: loki-config.yaml
|
||||
volumes:
|
||||
- name: loki-pv
|
||||
persistentVolumeClaim:
|
||||
claimName: loki-pvc
|
||||
- name: loki-config-volume
|
||||
configMap:
|
||||
name: loki-config
|
||||
|
@ -2,6 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- pvc.yaml
|
||||
- configmap.yaml
|
||||
- service.yaml
|
||||
- deployment.yaml
|
||||
|
12
manifests/loki/pvc.yaml
Normal file
12
manifests/loki/pvc.yaml
Normal file
@ -0,0 +1,12 @@
|
||||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: loki-pvc
|
||||
namespace: monitoring
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 5Gi
|
||||
storageClassName: flat-storage-class
|
Loading…
x
Reference in New Issue
Block a user