apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: helm-longhorn namespace: argocd finalizers: - resources-finalizer.argocd.argoproj.io # Argo CD 3.x adds these for apps with PreDelete hooks (the Longhorn # chart has one). Listed here so the parent app doesn't see a diff. - pre-delete-finalizer.argocd.argoproj.io - pre-delete-finalizer.argocd.argoproj.io/cleanup spec: syncPolicy: syncOptions: - CreateNamespace=true automated: prune: true selfHeal: true project: default sources: - chart: longhorn repoURL: https://charts.longhorn.io/ # One minor at a time; each upgrade moves every volume to the new # engine image before the next. targetRevision: 1.12.1 helm: values: | persistence: defaultClassReplicaCount: 1 preUpgradeChecker: jobEnabled: false # From 1.12 Longhorn adds NetworkPolicies between its components, # and Calico enforces them. The instance-manager one only admits # Longhorn pods, while the iSCSI initiator connects from the host, # so keep them off until that is tested on its own. networkPolicies: restrictInternalTraffic: false # Since 1.8 the backup target is a BackupTarget resource instead of # the backup-target setting. defaultBackupStore: backupTarget: nfs://192.168.1.99:/volume1/microk8s-nfs pollInterval: 300 defaultSettings: # Move volumes to the new engine image after each Longhorn # upgrade, one at a time. At 0 they stayed behind on 1.7.1/1.7.2. concurrentAutomaticEngineUpgradePerNodeLimit: 1 parameters: - name: csi.kubeletRootDir value: "/var/snap/microk8s/common/var/lib/kubelet" destination: server: https://kubernetes.default.svc namespace: longhorn-system