Use remote longhorn yaml

This commit is contained in:
Finn 2024-07-26 15:28:25 -07:00
parent d6fac56f2e
commit 3cd43008f2
6 changed files with 72 additions and 4612 deletions

View file

@ -0,0 +1,10 @@
- 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
backup-target-credential-secret: minio-backup-credentials
concurrent-automatic-engine-upgrade-per-node-limit: 1

View file

@ -1,14 +0,0 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: longhorn-default-setting
labels:
app.kubernetes.io/name: longhorn
app.kubernetes.io/instance: longhorn
app.kubernetes.io/version: v1.6.0
data:
default-setting.yaml: |- # 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
backup-target-credential-secret: minio-backup-credentials
concurrent-automatic-engine-upgrade-per-node-limit: 1

View file

@ -0,0 +1,16 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: longhorn-frontend-internal
spec:
rules:
- host: longhorn.longhorn-system.k8s
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: longhorn-frontend
port:
number: 80

View file

@ -2,9 +2,17 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: longhorn-system
resources:
- namespace.yaml
- config.yaml
- longhorn.yaml
- https://github.com/longhorn/longhorn/releases/download/v1.6.2/longhorn.yaml
- secrets.yaml
- storage-class.yaml
- backup.yaml
- ingress.yaml
patches:
- path: config-patches.yaml
target:
kind: ConfigMap
name: longhorn-default-setting
- path: longhorn-storageclass-patches.yaml
target:
kind: ConfigMap
name: longhorn-storageclass

View file

@ -0,0 +1,35 @@
- op: replace
path: /data/storageclass.yaml
value: |
kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
name: longhorn
annotations:
storageclass.kubernetes.io/is-default-class: "true"
provisioner: driver.longhorn.io
allowVolumeExpansion: true
reclaimPolicy: "Delete"
volumeBindingMode: Immediate
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"
}
}
]

File diff suppressed because it is too large Load diff