diff --git a/inventory.yml b/inventory.yml index b34653a..c0b45b8 100644 --- a/inventory.yml +++ b/inventory.yml @@ -69,15 +69,19 @@ home_k8s: hosts: k8s-node-1: home_network: true + k3s_role: server k8s-node-2: home_network: true + k3s_role: agent k8s-node-3: home_network: true + k3s_role: agent home_k8s_usb: hosts: k8s-node-usb-0: home_network: true + k3s_role: agent forgejo_runners: hosts: diff --git a/k8s/operators/longhorn/config-patches.yaml b/k8s/operators/longhorn/config-patches.yaml index e17e5f8..27005b2 100644 --- a/k8s/operators/longhorn/config-patches.yaml +++ b/k8s/operators/longhorn/config-patches.yaml @@ -1,10 +1,8 @@ - op: replace path: /data/default-setting.yaml 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 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 concurrent-automatic-engine-upgrade-per-node-limit: 1 diff --git a/k8s/operators/longhorn/kustomization.yaml b/k8s/operators/longhorn/kustomization.yaml index f179f37..8b7c88c 100644 --- a/k8s/operators/longhorn/kustomization.yaml +++ b/k8s/operators/longhorn/kustomization.yaml @@ -4,7 +4,6 @@ namespace: longhorn-system resources: - https://github.com/longhorn/longhorn/releases/download/v1.6.2/longhorn.yaml - secrets.yaml - - storage-class.yaml - backup.yaml - ingress.yaml patches: diff --git a/k8s/operators/longhorn/longhorn-storageclass-patches.yaml b/k8s/operators/longhorn/longhorn-storageclass-patches.yaml index 4617c84..f19384c 100644 --- a/k8s/operators/longhorn/longhorn-storageclass-patches.yaml +++ b/k8s/operators/longhorn/longhorn-storageclass-patches.yaml @@ -18,18 +18,15 @@ recurringJobs: | [ { - "name":"snap", - "task":"snapshot", - "cron":"*/1 * * * *", - "retain":1 + "name": "snap", + "task": "snapshot", + "cron": "0 * * * *", + "retain": 24 }, { - "name":"backup", - "task":"backup", - "cron":"*/2 * * * *", - "retain":1, - "labels": { - "interval":"2m" - } + "name": "backup", + "task": "backup", + "cron": "0 0 * * *", + "retain": 7, } ] diff --git a/k8s/operators/longhorn/storage-class.yaml b/k8s/operators/longhorn/storage-class.yaml deleted file mode 100644 index 9e8fc6c..0000000 --- a/k8s/operators/longhorn/storage-class.yaml +++ /dev/null @@ -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" - } - } - ]