fix longhorn config

This commit is contained in:
Finn 2024-07-26 21:50:19 -07:00
parent 89f333ecdd
commit b2691bcec6
5 changed files with 13 additions and 43 deletions

View file

@ -69,15 +69,19 @@ home_k8s:
hosts: hosts:
k8s-node-1: k8s-node-1:
home_network: true home_network: true
k3s_role: server
k8s-node-2: k8s-node-2:
home_network: true home_network: true
k3s_role: agent
k8s-node-3: k8s-node-3:
home_network: true home_network: true
k3s_role: agent
home_k8s_usb: home_k8s_usb:
hosts: hosts:
k8s-node-usb-0: k8s-node-usb-0:
home_network: true home_network: true
k3s_role: agent
forgejo_runners: forgejo_runners:
hosts: hosts:

View file

@ -1,10 +1,8 @@
- op: replace - op: replace
path: /data/default-setting.yaml path: /data/default-setting.yaml
value: | value: |
priority-class: longhorn-critical # default
# reference: https://longhorn.io/docs/1.6.2/advanced-resources/deploy/customizing-default-settings/#using-the-longhorn-deployment-yaml-file # reference: https://longhorn.io/docs/1.6.2/advanced-resources/deploy/customizing-default-settings/#using-the-longhorn-deployment-yaml-file
backup-target: s3://k8s-volume-backups@us-sea-1/k8s-volume-backups backup-target: s3://k8s-volume-backups@us-sea-1/k8s-volume-backups
priority-class: longhorn-critical priority-class: longhorn-critical # default
backup-target-credential-secret: minio-backup-credentials backup-target-credential-secret: minio-backup-credentials
concurrent-automatic-engine-upgrade-per-node-limit: 1 concurrent-automatic-engine-upgrade-per-node-limit: 1

View file

@ -4,7 +4,6 @@ namespace: longhorn-system
resources: resources:
- https://github.com/longhorn/longhorn/releases/download/v1.6.2/longhorn.yaml - https://github.com/longhorn/longhorn/releases/download/v1.6.2/longhorn.yaml
- secrets.yaml - secrets.yaml
- storage-class.yaml
- backup.yaml - backup.yaml
- ingress.yaml - ingress.yaml
patches: patches:

View file

@ -18,18 +18,15 @@
recurringJobs: | recurringJobs: |
[ [
{ {
"name":"snap", "name": "snap",
"task":"snapshot", "task": "snapshot",
"cron":"*/1 * * * *", "cron": "0 * * * *",
"retain":1 "retain": 24
}, },
{ {
"name":"backup", "name": "backup",
"task":"backup", "task": "backup",
"cron":"*/2 * * * *", "cron": "0 0 * * *",
"retain":1, "retain": 7,
"labels": {
"interval":"2m"
}
} }
] ]

View file

@ -1,28 +0,0 @@
kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
name: longhorn
provisioner: driver.longhorn.io
allowVolumeExpansion: true
parameters:
numberOfReplicas: "1"
staleReplicaTimeout: "2880" # 48 hours in minutes
fromBackup: ""
recurringJobs: |
[
{
"name":"snap",
"task":"snapshot",
"cron":"*/1 * * * *",
"retain":1
},
{
"name":"backup",
"task":"backup",
"cron":"*/2 * * * *",
"retain":1,
"labels": {
"interval":"2m"
}
}
]