fix(longhorn): clear permanent OutOfSync on longhorn-config

StorageClass.parameters is immutable and mkfsParams was added after creation,
so every sync failed. Replace=true recreates it instead of patching. Existing
volumes keep their format; only new ones get mkfsParams.

Longhorn names its own disk key and writes storageReserved into it, so git's
default-disk never matched and selfHeal kept trying to add a second disk on the
same path. Dropped spec.disks from git, added ignoreDifferences.
This commit is contained in:
Story Crater Bot
2026-08-15 23:07:49 -07:00
parent a005a07648
commit 9b75b15aa3
3 changed files with 34 additions and 12 deletions
@@ -72,6 +72,14 @@ spec:
destination:
server: https://kubernetes.default.svc
namespace: longhorn-system
# Longhorn writes disk state back into its own Node CRs — the disk key it
# generates, storageReserved, diskType, evictionRequested. Git declares only
# allowScheduling; without this the controller's writes read as drift forever.
ignoreDifferences:
- group: longhorn.io
kind: Node
jsonPointers:
- /spec/disks
syncPolicy:
automated:
prune: true