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:
@@ -7,6 +7,22 @@ metadata:
|
||||
namespace: longhorn-system
|
||||
annotations:
|
||||
storageclass.kubernetes.io/is-default-class: "false"
|
||||
# StorageClass.parameters is immutable. mkfsParams below was added after
|
||||
# this class already existed, so every sync failed with
|
||||
# parameters: Invalid value: {...}: field is immutable
|
||||
# and the Application sat OutOfSync permanently — ArgoCD retrying a change
|
||||
# the API server can never accept.
|
||||
#
|
||||
# Replace=true makes ArgoCD delete and recreate instead of patching. Safe
|
||||
# for a StorageClass: it is consulted only at provisioning time, so bound
|
||||
# PVs and their data are untouched. New PVCs briefly fail if one is created
|
||||
# during the window.
|
||||
#
|
||||
# Note what this does NOT do: the nine CNPG volumes already provisioned were
|
||||
# formatted without mkfsParams and keep that format. Only volumes created
|
||||
# after this recreate get it. Existing volumes that need to expand still
|
||||
# need handling separately.
|
||||
argocd.argoproj.io/sync-options: Replace=true,Force=true
|
||||
provisioner: driver.longhorn.io
|
||||
allowVolumeExpansion: true
|
||||
parameters:
|
||||
|
||||
Reference in New Issue
Block a user