mirror of https://github.com/longhorn/charts.git
Compare commits
34 Commits
longhorn-1
...
v1.9.x
Author | SHA1 | Date |
---|---|---|
|
62263e684b | |
|
418e0e6b79 | |
|
b491dc9651 | |
|
3aaf7ca369 | |
|
6ee9e8aa82 | |
|
ce30e9f5e8 | |
|
911b638562 | |
|
28daa57728 | |
|
34237ddeef | |
|
7ad73690b7 | |
|
c112ff0b8b | |
|
f8dde69c24 | |
|
d5f9fd86ab | |
|
8b3be40310 | |
|
7b7c2b0417 | |
|
d96ae9ee00 | |
|
2cfe155ea8 | |
|
e962c332eb | |
|
4164c991f3 | |
|
11847d8f65 | |
|
ad73dc0123 | |
|
b214ec3d17 | |
|
97fe89d639 | |
|
35833202fc | |
|
ca9f71c730 | |
|
f0041475f7 | |
|
0583abe2de | |
|
18b5340611 | |
|
3e2748d1e8 | |
|
4b43f29b1c | |
|
830c2dc3d8 | |
|
1a4a0fd8f7 | |
|
31076e52f2 | |
|
27d692ab99 |
|
@ -1,8 +1,8 @@
|
|||
apiVersion: v1
|
||||
name: longhorn
|
||||
version: 1.5.2
|
||||
appVersion: v1.5.2
|
||||
kubeVersion: ">=1.21.0-0"
|
||||
version: 1.9.0
|
||||
appVersion: v1.9.0
|
||||
kubeVersion: ">=1.25.0-0"
|
||||
description: Longhorn is a distributed block storage system for Kubernetes.
|
||||
keywords:
|
||||
- longhorn
|
||||
|
|
|
@ -4,6 +4,8 @@
|
|||
|
||||
> **Warning**: Longhorn doesn't support downgrading from a higher version to a lower version.
|
||||
|
||||
> **Note**: Use Helm 3 when installing and upgrading Longhorn. Helm 2 is [no longer supported](https://helm.sh/blog/helm-2-becomes-unsupported/).
|
||||
|
||||
## Source Code
|
||||
|
||||
Longhorn is 100% open source software. Project source code is spread across a number of repos:
|
||||
|
@ -18,7 +20,7 @@ Longhorn is 100% open source software. Project source code is spread across a nu
|
|||
## Prerequisites
|
||||
|
||||
1. A container runtime compatible with Kubernetes (Docker v1.13+, containerd v1.3.7+, etc.)
|
||||
2. Kubernetes >= v1.21
|
||||
2. Kubernetes >= v1.25
|
||||
3. Make sure `bash`, `curl`, `findmnt`, `grep`, `awk` and `blkid` has been installed in all nodes of the Kubernetes cluster.
|
||||
4. Make sure `open-iscsi` has been installed, and the `iscsid` daemon is running on all nodes of the Kubernetes cluster. For GKE, recommended Ubuntu as guest OS image since it contains `open-iscsi` already.
|
||||
|
||||
|
@ -37,6 +39,7 @@ Upon setting `enablePSP` to false, the chart will remove any PSP resources deplo
|
|||
As a replacement for PSPs, [Pod Security Admission](https://kubernetes.io/docs/concepts/security/pod-security-admission/) should be used. Please consult the Longhorn docs for more details on how to configure your chart release namespaces to work with the new Pod Security Admission and apply Pod Security Standards.
|
||||
|
||||
## Installation
|
||||
|
||||
1. Add Longhorn chart repository.
|
||||
```
|
||||
helm repo add longhorn https://charts.longhorn.io
|
||||
|
@ -47,12 +50,7 @@ helm repo add longhorn https://charts.longhorn.io
|
|||
helm repo update
|
||||
```
|
||||
|
||||
3. Install Longhorn chart.
|
||||
- With Helm 2, the following command will create the `longhorn-system` namespace and install the Longhorn chart together.
|
||||
```
|
||||
helm install longhorn/longhorn --name longhorn --namespace longhorn-system
|
||||
```
|
||||
- With Helm 3, the following commands will create the `longhorn-system` namespace first, then install the Longhorn chart.
|
||||
3. Use the following commands to create the `longhorn-system` namespace first, then install the Longhorn chart.
|
||||
|
||||
```
|
||||
kubectl create namespace longhorn-system
|
||||
|
@ -61,18 +59,305 @@ helm install longhorn longhorn/longhorn --namespace longhorn-system
|
|||
|
||||
## Uninstallation
|
||||
|
||||
With Helm 2 to uninstall Longhorn.
|
||||
```
|
||||
kubectl -n longhorn-system patch -p '{"value": "true"}' --type=merge lhs deleting-confirmation-flag
|
||||
helm delete longhorn --purge
|
||||
```
|
||||
|
||||
With Helm 3 to uninstall Longhorn.
|
||||
```
|
||||
kubectl -n longhorn-system patch -p '{"value": "true"}' --type=merge lhs deleting-confirmation-flag
|
||||
helm uninstall longhorn -n longhorn-system
|
||||
kubectl delete namespace longhorn-system
|
||||
```
|
||||
|
||||
## Values
|
||||
|
||||
The `values.yaml` contains items used to tweak a deployment of this chart.
|
||||
|
||||
### Cattle Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| global.cattle.systemDefaultRegistry | string | `""` | Default system registry. |
|
||||
| global.cattle.windowsCluster.defaultSetting.systemManagedComponentsNodeSelector | string | `"kubernetes.io/os:linux"` | Node selector for system-managed Longhorn components. |
|
||||
| global.cattle.windowsCluster.defaultSetting.taintToleration | string | `"cattle.io/os=linux:NoSchedule"` | Toleration for system-managed Longhorn components. |
|
||||
| global.cattle.windowsCluster.enabled | bool | `false` | Setting that allows Longhorn to run on a Rancher Windows cluster. |
|
||||
| global.cattle.windowsCluster.nodeSelector | object | `{"kubernetes.io/os":"linux"}` | Node selector for Linux nodes that can run user-deployed Longhorn components. |
|
||||
| global.cattle.windowsCluster.tolerations | list | `[{"effect":"NoSchedule","key":"cattle.io/os","operator":"Equal","value":"linux"}]` | Toleration for Linux nodes that can run user-deployed Longhorn components. |
|
||||
| global.nodeSelector | object | `{}` | Node selector for nodes allowed to run user-deployed components such as Longhorn Manager, Longhorn UI, and Longhorn Driver Deployer. |
|
||||
| global.tolerations | list | `[]` | Toleration for nodes allowed to run user-deployed components such as Longhorn Manager, Longhorn UI, and Longhorn Driver Deployer. |
|
||||
|
||||
### Network Policies
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| networkPolicies.enabled | bool | `false` | Setting that allows you to enable network policies that control access to Longhorn pods. |
|
||||
| networkPolicies.type | string | `"k3s"` | Distribution that determines the policy for allowing access for an ingress. (Options: "k3s", "rke2", "rke1") |
|
||||
|
||||
### Image Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| image.csi.attacher.repository | string | `"longhornio/csi-attacher"` | Repository for the CSI attacher image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.attacher.tag | string | `"v4.8.1"` | Tag for the CSI attacher image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.livenessProbe.repository | string | `"longhornio/livenessprobe"` | Repository for the CSI liveness probe image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.livenessProbe.tag | string | `"v2.15.0"` | Tag for the CSI liveness probe image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.nodeDriverRegistrar.repository | string | `"longhornio/csi-node-driver-registrar"` | Repository for the CSI Node Driver Registrar image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.nodeDriverRegistrar.tag | string | `"v2.13.0"` | Tag for the CSI Node Driver Registrar image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.provisioner.repository | string | `"longhornio/csi-provisioner"` | Repository for the CSI Provisioner image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.provisioner.tag | string | `"v5.2.0"` | Tag for the CSI Provisioner image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.resizer.repository | string | `"longhornio/csi-resizer"` | Repository for the CSI Resizer image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.resizer.tag | string | `"v1.13.2"` | Tag for the CSI Resizer image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.snapshotter.repository | string | `"longhornio/csi-snapshotter"` | Repository for the CSI Snapshotter image. When unspecified, Longhorn uses the default value. |
|
||||
| image.csi.snapshotter.tag | string | `"v8.2.0"` | Tag for the CSI Snapshotter image. When unspecified, Longhorn uses the default value. |
|
||||
| image.longhorn.backingImageManager.repository | string | `"longhornio/backing-image-manager"` | Repository for the Backing Image Manager image. When unspecified, Longhorn uses the default value. |
|
||||
| image.longhorn.backingImageManager.tag | string | `"v1.9.0"` | Tag for the Backing Image Manager image. When unspecified, Longhorn uses the default value. |
|
||||
| image.longhorn.engine.repository | string | `"longhornio/longhorn-engine"` | Repository for the Longhorn Engine image. |
|
||||
| image.longhorn.engine.tag | string | `"v1.9.0"` | Tag for the Longhorn Engine image. |
|
||||
| image.longhorn.instanceManager.repository | string | `"longhornio/longhorn-instance-manager"` | Repository for the Longhorn Instance Manager image. |
|
||||
| image.longhorn.instanceManager.tag | string | `"v1.9.0"` | Tag for the Longhorn Instance Manager image. |
|
||||
| image.longhorn.manager.repository | string | `"longhornio/longhorn-manager"` | Repository for the Longhorn Manager image. |
|
||||
| image.longhorn.manager.tag | string | `"v1.9.0"` | Tag for the Longhorn Manager image. |
|
||||
| image.longhorn.shareManager.repository | string | `"longhornio/longhorn-share-manager"` | Repository for the Longhorn Share Manager image. |
|
||||
| image.longhorn.shareManager.tag | string | `"v1.9.0"` | Tag for the Longhorn Share Manager image. |
|
||||
| image.longhorn.supportBundleKit.repository | string | `"longhornio/support-bundle-kit"` | Repository for the Longhorn Support Bundle Manager image. |
|
||||
| image.longhorn.supportBundleKit.tag | string | `"v0.0.55"` | Tag for the Longhorn Support Bundle Manager image. |
|
||||
| image.longhorn.ui.repository | string | `"longhornio/longhorn-ui"` | Repository for the Longhorn UI image. |
|
||||
| image.longhorn.ui.tag | string | `"v1.9.0"` | Tag for the Longhorn UI image. |
|
||||
| image.openshift.oauthProxy.repository | string | `""` | Repository for the OAuth Proxy image. Specify the upstream image (for example, "quay.io/openshift/origin-oauth-proxy"). This setting applies only to OpenShift users. |
|
||||
| image.openshift.oauthProxy.tag | string | `""` | Tag for the OAuth Proxy image. Specify OCP/OKD version 4.1 or later (including version 4.15, which is available at quay.io/openshift/origin-oauth-proxy:4.15). This setting applies only to OpenShift users. |
|
||||
| image.pullPolicy | string | `"IfNotPresent"` | Image pull policy that applies to all user-deployed Longhorn components, such as Longhorn Manager, Longhorn driver, and Longhorn UI. |
|
||||
|
||||
### Service Settings
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
| service.manager.nodePort | NodePort port number for Longhorn Manager. When unspecified, Longhorn selects a free port between 30000 and 32767. |
|
||||
| service.manager.type | Service type for Longhorn Manager. |
|
||||
| service.ui.nodePort | NodePort port number for Longhorn UI. When unspecified, Longhorn selects a free port between 30000 and 32767. |
|
||||
| service.ui.type | Service type for Longhorn UI. (Options: "ClusterIP", "NodePort", "LoadBalancer", "Rancher-Proxy") |
|
||||
|
||||
### StorageClass Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| persistence.backingImage.dataSourceParameters | string | `nil` | Data source parameters of a backing image used in a Longhorn StorageClass. You can specify a JSON string of a map. (Example: `'{\"url\":\"https://backing-image-example.s3-region.amazonaws.com/test-backing-image\"}'`) |
|
||||
| persistence.backingImage.dataSourceType | string | `nil` | Data source type of a backing image used in a Longhorn StorageClass. If the backing image exists in the cluster, Longhorn uses this setting to verify the image. If the backing image does not exist, Longhorn creates one using the specified data source type. |
|
||||
| persistence.backingImage.enable | bool | `false` | Setting that allows you to use a backing image in a Longhorn StorageClass. |
|
||||
| persistence.backingImage.expectedChecksum | string | `nil` | Expected SHA-512 checksum of a backing image used in a Longhorn StorageClass. |
|
||||
| persistence.backingImage.name | string | `nil` | Backing image to be used for creating and restoring volumes in a Longhorn StorageClass. When no backing images are available, specify the data source type and parameters that Longhorn can use to create a backing image. |
|
||||
| persistence.backupTargetName | string | `"default"` | Setting that allows you to specify the backup target for the default Longhorn StorageClass. |
|
||||
| persistence.dataEngine | string | `"v1"` | Setting that allows you to specify the data engine version for the default Longhorn StorageClass. (Options: "v1", "v2") |
|
||||
| persistence.defaultClass | bool | `true` | Setting that allows you to specify the default Longhorn StorageClass. |
|
||||
| persistence.defaultClassReplicaCount | int | `3` | Replica count of the default Longhorn StorageClass. |
|
||||
| persistence.defaultDataLocality | string | `"disabled"` | Data locality of the default Longhorn StorageClass. (Options: "disabled", "best-effort") |
|
||||
| persistence.defaultDiskSelector.enable | bool | `false` | Setting that allows you to enable the disk selector for the default Longhorn StorageClass. |
|
||||
| persistence.defaultDiskSelector.selector | string | `""` | Disk selector for the default Longhorn StorageClass. Longhorn uses only disks with the specified tags for storing volume data. (Examples: "nvme,sata") |
|
||||
| persistence.defaultFsType | string | `"ext4"` | Filesystem type of the default Longhorn StorageClass. |
|
||||
| persistence.defaultMkfsParams | string | `""` | mkfs parameters of the default Longhorn StorageClass. |
|
||||
| persistence.defaultNodeSelector.enable | bool | `false` | Setting that allows you to enable the node selector for the default Longhorn StorageClass. |
|
||||
| persistence.defaultNodeSelector.selector | string | `""` | Node selector for the default Longhorn StorageClass. Longhorn uses only nodes with the specified tags for storing volume data. (Examples: "storage,fast") |
|
||||
| persistence.disableRevisionCounter | string | `"true"` | Setting that disables the revision counter and thereby prevents Longhorn from tracking all write operations to a volume. When salvaging a volume, Longhorn uses properties of the volume-head-xxx.img file (the last file size and the last time the file was modified) to select the replica to be used for volume recovery. |
|
||||
| persistence.migratable | bool | `false` | Setting that allows you to enable live migration of a Longhorn volume from one node to another. |
|
||||
| persistence.nfsOptions | string | `""` | Set NFS mount options for Longhorn StorageClass for RWX volumes |
|
||||
| persistence.reclaimPolicy | string | `"Delete"` | Reclaim policy that provides instructions for handling of a volume after its claim is released. (Options: "Retain", "Delete") |
|
||||
| persistence.recurringJobSelector.enable | bool | `false` | Setting that allows you to enable the recurring job selector for a Longhorn StorageClass. |
|
||||
| persistence.recurringJobSelector.jobList | list | `[]` | Recurring job selector for a Longhorn StorageClass. Ensure that quotes are used correctly when specifying job parameters. (Example: `[{"name":"backup", "isGroup":true}]`) |
|
||||
| persistence.removeSnapshotsDuringFilesystemTrim | string | `"ignored"` | Setting that allows you to enable automatic snapshot removal during filesystem trim for a Longhorn StorageClass. (Options: "ignored", "enabled", "disabled") |
|
||||
| persistence.volumeBindingMode | string | `"Immediate"` | VolumeBindingMode controls when volume binding and dynamic provisioning should occur. (Options: "Immediate", "WaitForFirstConsumer") (Defaults to "Immediate") |
|
||||
|
||||
### CSI Settings
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
| csi.attacherReplicaCount | Replica count of the CSI Attacher. When unspecified, Longhorn uses the default value ("3"). |
|
||||
| csi.kubeletRootDir | kubelet root directory. When unspecified, Longhorn uses the default value. |
|
||||
| csi.provisionerReplicaCount | Replica count of the CSI Provisioner. When unspecified, Longhorn uses the default value ("3"). |
|
||||
| csi.resizerReplicaCount | Replica count of the CSI Resizer. When unspecified, Longhorn uses the default value ("3"). |
|
||||
| csi.snapshotterReplicaCount | Replica count of the CSI Snapshotter. When unspecified, Longhorn uses the default value ("3"). |
|
||||
|
||||
### Longhorn Manager Settings
|
||||
|
||||
Longhorn consists of user-deployed components (for example, Longhorn Manager, Longhorn Driver, and Longhorn UI) and system-managed components (for example, Instance Manager, Backing Image Manager, Share Manager, CSI Driver, and Engine Image). The following settings only apply to Longhorn Manager.
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| longhornManager.log.format | string | `"plain"` | Format of Longhorn Manager logs. (Options: "plain", "json") |
|
||||
| longhornManager.nodeSelector | object | `{}` | Node selector for Longhorn Manager. Specify the nodes allowed to run Longhorn Manager. |
|
||||
| longhornManager.priorityClass | string | `"longhorn-critical"` | PriorityClass for Longhorn Manager. |
|
||||
| longhornManager.serviceAnnotations | object | `{}` | Annotation for the Longhorn Manager service. |
|
||||
| longhornManager.tolerations | list | `[]` | Toleration for Longhorn Manager on nodes allowed to run Longhorn components. |
|
||||
|
||||
### Longhorn Driver Settings
|
||||
|
||||
Longhorn consists of user-deployed components (for example, Longhorn Manager, Longhorn Driver, and Longhorn UI) and system-managed components (for example, Instance Manager, Backing Image Manager, Share Manager, CSI Driver, and Engine Image). The following settings only apply to Longhorn Driver.
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| longhornDriver.log.format | string | `"plain"` | Format of longhorn-driver logs. (Options: "plain", "json") |
|
||||
| longhornDriver.nodeSelector | object | `{}` | Node selector for Longhorn Driver. Specify the nodes allowed to run Longhorn Driver. |
|
||||
| longhornDriver.priorityClass | string | `"longhorn-critical"` | PriorityClass for Longhorn Driver. |
|
||||
| longhornDriver.tolerations | list | `[]` | Toleration for Longhorn Driver on nodes allowed to run Longhorn components. |
|
||||
|
||||
### Longhorn UI Settings
|
||||
|
||||
Longhorn consists of user-deployed components (for example, Longhorn Manager, Longhorn Driver, and Longhorn UI) and system-managed components (for example, Instance Manager, Backing Image Manager, Share Manager, CSI Driver, and Engine Image). The following settings only apply to Longhorn UI.
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| longhornUI.affinity | object | `{"podAntiAffinity":{"preferredDuringSchedulingIgnoredDuringExecution":[{"podAffinityTerm":{"labelSelector":{"matchExpressions":[{"key":"app","operator":"In","values":["longhorn-ui"]}]},"topologyKey":"kubernetes.io/hostname"},"weight":1}]}}` | Affinity for Longhorn UI pods. Specify the affinity you want to use for Longhorn UI. |
|
||||
| longhornUI.nodeSelector | object | `{}` | Node selector for Longhorn UI. Specify the nodes allowed to run Longhorn UI. |
|
||||
| longhornUI.priorityClass | string | `"longhorn-critical"` | PriorityClass for Longhorn UI. |
|
||||
| longhornUI.replicas | int | `2` | Replica count for Longhorn UI. |
|
||||
| longhornUI.tolerations | list | `[]` | Toleration for Longhorn UI on nodes allowed to run Longhorn components. |
|
||||
|
||||
### Ingress Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| ingress.annotations | string | `nil` | Ingress annotations in the form of key-value pairs. |
|
||||
| ingress.enabled | bool | `false` | Setting that allows Longhorn to generate ingress records for the Longhorn UI service. |
|
||||
| ingress.host | string | `"sslip.io"` | Hostname of the Layer 7 load balancer. |
|
||||
| ingress.ingressClassName | string | `nil` | IngressClass resource that contains ingress configuration, including the name of the Ingress controller. ingressClassName can replace the kubernetes.io/ingress.class annotation used in earlier Kubernetes releases. |
|
||||
| ingress.path | string | `"/"` | Default ingress path. You can access the Longhorn UI by following the full ingress path {{host}}+{{path}}. |
|
||||
| ingress.pathType | string | `"ImplementationSpecific"` | Ingress path type. To maintain backward compatibility, the default value is "ImplementationSpecific". |
|
||||
| ingress.secrets | string | `nil` | Secret that contains a TLS private key and certificate. Use secrets if you want to use your own certificates to secure ingresses. |
|
||||
| ingress.secureBackends | bool | `false` | Setting that allows you to enable secure connections to the Longhorn UI service via port 443. |
|
||||
| ingress.tls | bool | `false` | Setting that allows you to enable TLS on ingress records. |
|
||||
| ingress.tlsSecret | string | `"longhorn.local-tls"` | TLS secret that contains the private key and certificate to be used for TLS. This setting applies only when TLS is enabled on ingress records. |
|
||||
|
||||
### Private Registry Settings
|
||||
|
||||
You can install Longhorn in an air-gapped environment with a private registry. For more information, see the **Air Gap Installation** section of the [documentation](https://longhorn.io/docs).
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
| privateRegistry.createSecret | Setting that allows you to create a private registry secret. |
|
||||
| privateRegistry.registryPasswd | Password for authenticating with a private registry. |
|
||||
| privateRegistry.registrySecret | Kubernetes secret that allows you to pull images from a private registry. This setting applies only when creation of private registry secrets is enabled. You must include the private registry name in the secret name. |
|
||||
| privateRegistry.registryUrl | URL of a private registry. When unspecified, Longhorn uses the default system registry. |
|
||||
| privateRegistry.registryUser | User account used for authenticating with a private registry. |
|
||||
|
||||
### Metrics Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| metrics.serviceMonitor.additionalLabels | object | `{}` | Additional labels for the Prometheus ServiceMonitor resource. |
|
||||
| metrics.serviceMonitor.annotations | object | `{}` | Annotations for the Prometheus ServiceMonitor resource. |
|
||||
| metrics.serviceMonitor.enabled | bool | `false` | Setting that allows the creation of a Prometheus ServiceMonitor resource for Longhorn Manager components. |
|
||||
| metrics.serviceMonitor.interval | string | `""` | Interval at which Prometheus scrapes the metrics from the target. |
|
||||
| metrics.serviceMonitor.metricRelabelings | list | `[]` | Configures the relabeling rules to apply to the samples before ingestion. See the [Prometheus Operator documentation](https://prometheus-operator.dev/docs/api-reference/api/#monitoring.coreos.com/v1.Endpoint) for formatting details. |
|
||||
| metrics.serviceMonitor.relabelings | list | `[]` | Configures the relabeling rules to apply the target’s metadata labels. See the [Prometheus Operator documentation](https://prometheus-operator.dev/docs/api-reference/api/#monitoring.coreos.com/v1.Endpoint) for formatting details. |
|
||||
| metrics.serviceMonitor.scrapeTimeout | string | `""` | Timeout after which Prometheus considers the scrape to be failed. |
|
||||
|
||||
### OS/Kubernetes Distro Settings
|
||||
|
||||
#### OpenShift Settings
|
||||
|
||||
For more details, see the [ocp-readme](https://github.com/longhorn/longhorn/blob/master/chart/ocp-readme.md).
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| openshift.enabled | bool | `false` | Setting that allows Longhorn to integrate with OpenShift. |
|
||||
| openshift.ui.port | int | `443` | Port for accessing the OpenShift web console. |
|
||||
| openshift.ui.proxy | int | `8443` | Port for proxy that provides access to the OpenShift web console. |
|
||||
| openshift.ui.route | string | `"longhorn-ui"` | Route for connections between Longhorn and the OpenShift web console. |
|
||||
|
||||
### Other Settings
|
||||
|
||||
| Key | Default | Description |
|
||||
|-----|---------|-------------|
|
||||
| annotations | `{}` | Annotation for the Longhorn Manager DaemonSet pods. This setting is optional. |
|
||||
| defaultBackupStore | `{"backupTarget":null,"backupTargetCredentialSecret":null,"pollInterval":null}` | Setting that allows you to update the default backupstore. |
|
||||
| defaultBackupStore.backupTarget | `nil` | Endpoint used to access the default backupstore. (Options: "NFS", "CIFS", "AWS", "GCP", "AZURE") |
|
||||
| defaultBackupStore.backupTargetCredentialSecret | `nil` | Name of the Kubernetes secret associated with the default backup target. |
|
||||
| defaultBackupStore.pollInterval | `nil` | Number of seconds that Longhorn waits before checking the default backupstore for new backups. The default value is "300". When the value is "0", polling is disabled. |
|
||||
| enableGoCoverDir | `false` | Setting that allows Longhorn to generate code coverage profiles. |
|
||||
| enablePSP | `false` | Setting that allows you to enable pod security policies (PSPs) that allow privileged Longhorn pods to start. This setting applies only to clusters running Kubernetes 1.25 and earlier, and with the built-in Pod Security admission controller enabled. |
|
||||
| extraObjects | `[]` | Add extra objects manifests |
|
||||
| namespaceOverride | `""` | Specify override namespace, specifically this is useful for using longhorn as sub-chart and its release namespace is not the `longhorn-system`. |
|
||||
| preUpgradeChecker.jobEnabled | `true` | Setting that allows Longhorn to perform pre-upgrade checks. Disable this setting when installing Longhorn using Argo CD or other GitOps solutions. |
|
||||
| preUpgradeChecker.upgradeVersionCheck | `true` | Setting that allows Longhorn to perform upgrade version checks after starting the Longhorn Manager DaemonSet Pods. Disabling this setting also disables `preUpgradeChecker.jobEnabled`. Longhorn recommends keeping this setting enabled. |
|
||||
|
||||
### System Default Settings
|
||||
|
||||
During installation, you can either allow Longhorn to use the default system settings or use specific flags to modify the default values. After installation, you can modify the settings using the Longhorn UI. For more information, see the **Settings Reference** section of the [documentation](https://longhorn.io/docs).
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
| defaultSettings.allowCollectingLonghornUsageMetrics | Setting that allows Longhorn to periodically collect anonymous usage data for product improvement purposes. Longhorn sends collected data to the [Upgrade Responder](https://github.com/longhorn/upgrade-responder) server, which is the data source of the Longhorn Public Metrics Dashboard (https://metrics.longhorn.io). The Upgrade Responder server does not store data that can be used to identify clients, including IP addresses. |
|
||||
| defaultSettings.allowEmptyDiskSelectorVolume | Setting that allows scheduling of empty disk selector volumes to any disk. |
|
||||
| defaultSettings.allowEmptyNodeSelectorVolume | Setting that allows scheduling of empty node selector volumes to any node. |
|
||||
| defaultSettings.allowRecurringJobWhileVolumeDetached | Setting that allows Longhorn to automatically attach a volume and create snapshots or backups when recurring jobs are run. |
|
||||
| defaultSettings.allowVolumeCreationWithDegradedAvailability | Setting that allows you to create and attach a volume without having all replicas scheduled at the time of creation. |
|
||||
| defaultSettings.autoCleanupRecurringJobBackupSnapshot | Setting that allows Longhorn to automatically clean up the snapshot generated by a recurring backup job. |
|
||||
| defaultSettings.autoCleanupSnapshotAfterOnDemandBackupCompleted | Setting that automatically cleans up the snapshot after the on-demand backup is completed. |
|
||||
| defaultSettings.autoCleanupSnapshotWhenDeleteBackup | Setting that automatically cleans up the snapshot when the backup is deleted. |
|
||||
| defaultSettings.autoCleanupSystemGeneratedSnapshot | Setting that allows Longhorn to automatically clean up the system-generated snapshot after replica rebuilding is completed. |
|
||||
| defaultSettings.autoDeletePodWhenVolumeDetachedUnexpectedly | Setting that allows Longhorn to automatically delete a workload pod that is managed by a controller (for example, daemonset) whenever a Longhorn volume is detached unexpectedly (for example, during Kubernetes upgrades). After deletion, the controller restarts the pod and then Kubernetes handles volume reattachment and remounting. |
|
||||
| defaultSettings.autoSalvage | Setting that allows Longhorn to automatically salvage volumes when all replicas become faulty (for example, when the network connection is interrupted). Longhorn determines which replicas are usable and then uses these replicas for the volume. This setting is enabled by default. |
|
||||
| defaultSettings.backingImageCleanupWaitInterval | Number of minutes that Longhorn waits before cleaning up the backing image file when no replicas in the disk are using it. |
|
||||
| defaultSettings.backingImageRecoveryWaitInterval | Number of seconds that Longhorn waits before downloading a backing image file again when the status of all image disk files changes to "failed" or "unknown". |
|
||||
| defaultSettings.backupCompressionMethod | Setting that allows you to specify a backup compression method. |
|
||||
| defaultSettings.backupConcurrentLimit | Maximum number of worker threads that can concurrently run for each backup. |
|
||||
| defaultSettings.backupExecutionTimeout | Number of minutes that Longhorn allows for the backup execution. The default value is "1". |
|
||||
| defaultSettings.concurrentAutomaticEngineUpgradePerNodeLimit | Maximum number of engines that are allowed to concurrently upgrade on each node after Longhorn Manager is upgraded. When the value is "0", Longhorn does not automatically upgrade volume engines to the new default engine image version. |
|
||||
| defaultSettings.concurrentReplicaRebuildPerNodeLimit | Maximum number of replicas that can be concurrently rebuilt on each node. |
|
||||
| defaultSettings.concurrentVolumeBackupRestorePerNodeLimit | Maximum number of volumes that can be concurrently restored on each node using a backup. When the value is "0", restoration of volumes using a backup is disabled. |
|
||||
| defaultSettings.createDefaultDiskLabeledNodes | Setting that allows Longhorn to automatically create a default disk only on nodes with the label "node.longhorn.io/create-default-disk=true" (if no other disks exist). When this setting is disabled, Longhorn creates a default disk on each node that is added to the cluster. |
|
||||
| defaultSettings.defaultDataLocality | Default data locality. A Longhorn volume has data locality if a local replica of the volume exists on the same node as the pod that is using the volume. |
|
||||
| defaultSettings.defaultDataPath | Default path for storing data on a host. The default value is "/var/lib/longhorn/". |
|
||||
| defaultSettings.defaultLonghornStaticStorageClass | Default name of Longhorn static StorageClass. "storageClassName" is assigned to PVs and PVCs that are created for an existing Longhorn volume. "storageClassName" can also be used as a label, so it is possible to use a Longhorn StorageClass to bind a workload to an existing PV without creating a Kubernetes StorageClass object. "storageClassName" needs to be an existing StorageClass. The default value is "longhorn-static". |
|
||||
| defaultSettings.defaultReplicaCount | Default number of replicas for volumes created using the Longhorn UI. For Kubernetes configuration, modify the `numberOfReplicas` field in the StorageClass. The default value is "3". |
|
||||
| defaultSettings.deletingConfirmationFlag | Flag that prevents accidental uninstallation of Longhorn. |
|
||||
| defaultSettings.detachManuallyAttachedVolumesWhenCordoned | Setting that allows automatic detaching of manually-attached volumes when a node is cordoned. |
|
||||
| defaultSettings.disableRevisionCounter | Setting that disables the revision counter and thereby prevents Longhorn from tracking all write operations to a volume. When salvaging a volume, Longhorn uses properties of the "volume-head-xxx.img" file (the last file size and the last time the file was modified) to select the replica to be used for volume recovery. This setting applies only to volumes created using the Longhorn UI. |
|
||||
| defaultSettings.disableSchedulingOnCordonedNode | Setting that prevents Longhorn Manager from scheduling replicas on a cordoned Kubernetes node. This setting is enabled by default. |
|
||||
| defaultSettings.disableSnapshotPurge | Setting that temporarily prevents all attempts to purge volume snapshots. |
|
||||
| defaultSettings.engineReplicaTimeout | Timeout between the Longhorn Engine and replicas. Specify a value between "8" and "30" seconds. The default value is "8". |
|
||||
| defaultSettings.failedBackupTTL | Number of minutes that Longhorn keeps a failed backup resource. When the value is "0", automatic deletion is disabled. |
|
||||
| defaultSettings.fastReplicaRebuildEnabled | Setting that allows fast rebuilding of replicas using the checksum of snapshot disk files. Before enabling this setting, you must set the snapshot-data-integrity value to "enable" or "fast-check". |
|
||||
| defaultSettings.freezeFilesystemForSnapshot | Setting that freezes the filesystem on the root partition before a snapshot is created. |
|
||||
| defaultSettings.guaranteedInstanceManagerCPU | Percentage of the total allocatable CPU resources on each node to be reserved for each instance manager pod when the V1 Data Engine is enabled. The default value is "12". |
|
||||
| defaultSettings.kubernetesClusterAutoscalerEnabled | Setting that notifies Longhorn that the cluster is using the Kubernetes Cluster Autoscaler. |
|
||||
| defaultSettings.logLevel | Log levels that indicate the type and severity of logs in Longhorn Manager. The default value is "Info". (Options: "Panic", "Fatal", "Error", "Warn", "Info", "Debug", "Trace") |
|
||||
| defaultSettings.longGRPCTimeOut | Number of seconds that Longhorn allows for the completion of replica rebuilding and snapshot cloning operations. |
|
||||
| defaultSettings.nodeDownPodDeletionPolicy | Policy that defines the action Longhorn takes when a volume is stuck with a StatefulSet or Deployment pod on a node that failed. |
|
||||
| defaultSettings.nodeDrainPolicy | Policy that defines the action Longhorn takes when a node with the last healthy replica of a volume is drained. |
|
||||
| defaultSettings.offlineRelicaRebuilding | Enables automatic rebuilding of degraded replicas while the volume is detached. This setting only takes effect if the individual volume setting is set to `ignored` or `enabled`. |
|
||||
| defaultSettings.orphanResourceAutoDeletion | Enables Longhorn to automatically delete orphaned resources and their associated data or processes (e.g., stale replicas). Orphaned resources on failed or unknown nodes are not automatically cleaned up. You need to specify the resource types to be deleted using a semicolon-separated list (e.g., `replica-data;instance`). Available items are: `replica-data`, `instance`. |
|
||||
| defaultSettings.orphanResourceAutoDeletionGracePeriod | Specifies the wait time, in seconds, before Longhorn automatically deletes an orphaned Custom Resource (CR) and its associated resources. Note that if a user manually deletes an orphaned CR, the deletion occurs immediately and does not respect this grace period. |
|
||||
| defaultSettings.priorityClass | PriorityClass for system-managed Longhorn components. This setting can help prevent Longhorn components from being evicted under Node Pressure. Notice that this will be applied to Longhorn user-deployed components by default if there are no priority class values set yet, such as `longhornManager.priorityClass`. |
|
||||
| defaultSettings.recurringFailedJobsHistoryLimit | Maximum number of failed recurring backup and snapshot jobs to be retained. When the value is "0", a history of failed recurring jobs is not retained. |
|
||||
| defaultSettings.recurringJobMaxRetention | Maximum number of snapshots or backups to be retained. |
|
||||
| defaultSettings.recurringSuccessfulJobsHistoryLimit | Maximum number of successful recurring backup and snapshot jobs to be retained. When the value is "0", a history of successful recurring jobs is not retained. |
|
||||
| defaultSettings.removeSnapshotsDuringFilesystemTrim | Setting that allows Longhorn to automatically mark the latest snapshot and its parent files as removed during a filesystem trim. Longhorn does not remove snapshots containing multiple child files. |
|
||||
| defaultSettings.replicaAutoBalance | Setting that automatically rebalances replicas when an available node is discovered. |
|
||||
| defaultSettings.replicaDiskSoftAntiAffinity | Setting that allows scheduling on disks with existing healthy replicas of the same volume. This setting is enabled by default. |
|
||||
| defaultSettings.replicaFileSyncHttpClientTimeout | Number of seconds that an HTTP client waits for a response from a File Sync server before considering the connection to have failed. |
|
||||
| defaultSettings.replicaReplenishmentWaitInterval | Number of seconds that Longhorn waits before reusing existing data on a failed replica instead of creating a new replica of a degraded volume. |
|
||||
| defaultSettings.replicaSoftAntiAffinity | Setting that allows scheduling on nodes with healthy replicas of the same volume. This setting is disabled by default. |
|
||||
| defaultSettings.replicaZoneSoftAntiAffinity | Setting that allows Longhorn to schedule new replicas of a volume to nodes in the same zone as existing healthy replicas. Nodes that do not belong to any zone are treated as existing in the zone that contains healthy replicas. When identifying zones, Longhorn relies on the label "topology.kubernetes.io/zone=<Zone name of the node>" in the Kubernetes node object. |
|
||||
| defaultSettings.restoreConcurrentLimit | Maximum number of worker threads that can concurrently run for each restore operation. |
|
||||
| defaultSettings.restoreVolumeRecurringJobs | Setting that restores recurring jobs from a backup volume on a backup target and creates recurring jobs if none exist during backup restoration. |
|
||||
| defaultSettings.rwxVolumeFastFailover | Setting that allows Longhorn to detect node failure and immediately migrate affected RWX volumes. |
|
||||
| defaultSettings.snapshotDataIntegrity | Setting that allows you to enable and disable snapshot hashing and data integrity checks. |
|
||||
| defaultSettings.snapshotDataIntegrityCronjob | Setting that defines when Longhorn checks the integrity of data in snapshot disk files. You must use the Unix cron expression format. |
|
||||
| defaultSettings.snapshotDataIntegrityImmediateCheckAfterSnapshotCreation | Setting that allows disabling of snapshot hashing after snapshot creation to minimize impact on system performance. |
|
||||
| defaultSettings.snapshotMaxCount | Maximum snapshot count for a volume. The value should be between 2 to 250 |
|
||||
| defaultSettings.storageMinimalAvailablePercentage | Percentage of minimum available disk capacity. When the minimum available capacity exceeds the total available capacity, the disk becomes unschedulable until more space is made available for use. The default value is "25". |
|
||||
| defaultSettings.storageNetwork | Storage network for in-cluster traffic. When unspecified, Longhorn uses the Kubernetes cluster network. |
|
||||
| defaultSettings.storageOverProvisioningPercentage | Percentage of storage that can be allocated relative to hard drive capacity. The default value is "100". |
|
||||
| defaultSettings.storageReservedPercentageForDefaultDisk | Percentage of disk space that is not allocated to the default disk on each new Longhorn node. |
|
||||
| defaultSettings.supportBundleFailedHistoryLimit | Maximum number of failed support bundles that can exist in the cluster. When the value is "0", Longhorn automatically purges all failed support bundles. |
|
||||
| defaultSettings.systemManagedComponentsNodeSelector | Node selector for system-managed Longhorn components. |
|
||||
| defaultSettings.systemManagedPodsImagePullPolicy | Image pull policy for system-managed pods, such as Instance Manager, engine images, and CSI Driver. Changes to the image pull policy are applied only after the system-managed pods restart. |
|
||||
| defaultSettings.taintToleration | Taint or toleration for system-managed Longhorn components. Specify values using a semicolon-separated list in `kubectl taint` syntax (Example: key1=value1:effect; key2=value2:effect). |
|
||||
| defaultSettings.upgradeChecker | Upgrade Checker that periodically checks for new Longhorn versions. When a new version is available, a notification appears on the Longhorn UI. This setting is enabled by default |
|
||||
| defaultSettings.upgradeResponderURL | The Upgrade Responder sends a notification whenever a new Longhorn version that you can upgrade to becomes available. The default value is https://longhorn-upgrade-responder.rancher.io/v1/checkupgrade. |
|
||||
| defaultSettings.v1DataEngine | Setting that allows you to enable the V1 Data Engine. |
|
||||
| defaultSettings.v2DataEngine | Setting that allows you to enable the V2 Data Engine, which is based on the Storage Performance Development Kit (SPDK). The V2 Data Engine is an experimental feature and should not be used in production environments. |
|
||||
| defaultSettings.v2DataEngineCPUMask | CPU cores on which the Storage Performance Development Kit (SPDK) target daemon should run. The SPDK target daemon is located in each Instance Manager pod. Ensure that the number of cores is less than or equal to the guaranteed Instance Manager CPUs for the V2 Data Engine. The default value is "0x1". |
|
||||
| defaultSettings.v2DataEngineGuaranteedInstanceManagerCPU | Number of millicpus on each node to be reserved for each Instance Manager pod when the V2 Data Engine is enabled. The default value is "1250". |
|
||||
| defaultSettings.v2DataEngineHugepageLimit | Setting that allows you to configure maximum huge page size (in MiB) for the V2 Data Engine. |
|
||||
| defaultSettings.v2DataEngineLogFlags | Setting that allows you to configure the log flags of the SPDK target daemon (spdk_tgt) of the V2 Data Engine. |
|
||||
| defaultSettings.v2DataEngineLogLevel | Setting that allows you to configure the log level of the SPDK target daemon (spdk_tgt) of the V2 Data Engine. |
|
||||
| defaultSettings.v2DataEngineSnapshotDataIntegrity | Setting allows you to enable or disable snapshot hashing and data integrity checking for the V2 Data Engine. |
|
||||
|
||||
---
|
||||
Please see [link](https://github.com/longhorn/longhorn) for more information.
|
||||
|
|
|
@ -0,0 +1,250 @@
|
|||
# Longhorn Chart
|
||||
|
||||
> **Important**: Please install the Longhorn chart in the `longhorn-system` namespace only.
|
||||
|
||||
> **Warning**: Longhorn doesn't support downgrading from a higher version to a lower version.
|
||||
|
||||
> **Note**: Use Helm 3 when installing and upgrading Longhorn. Helm 2 is [no longer supported](https://helm.sh/blog/helm-2-becomes-unsupported/).
|
||||
|
||||
## Source Code
|
||||
|
||||
Longhorn is 100% open source software. Project source code is spread across a number of repos:
|
||||
|
||||
1. Longhorn Engine -- Core controller/replica logic https://github.com/longhorn/longhorn-engine
|
||||
2. Longhorn Instance Manager -- Controller/replica instance lifecycle management https://github.com/longhorn/longhorn-instance-manager
|
||||
3. Longhorn Share Manager -- NFS provisioner that exposes Longhorn volumes as ReadWriteMany volumes. https://github.com/longhorn/longhorn-share-manager
|
||||
4. Backing Image Manager -- Backing image file lifecycle management. https://github.com/longhorn/backing-image-manager
|
||||
5. Longhorn Manager -- Longhorn orchestration, includes CSI driver for Kubernetes https://github.com/longhorn/longhorn-manager
|
||||
6. Longhorn UI -- Dashboard https://github.com/longhorn/longhorn-ui
|
||||
|
||||
## Prerequisites
|
||||
|
||||
1. A container runtime compatible with Kubernetes (Docker v1.13+, containerd v1.3.7+, etc.)
|
||||
2. Kubernetes >= v1.25
|
||||
3. Make sure `bash`, `curl`, `findmnt`, `grep`, `awk` and `blkid` has been installed in all nodes of the Kubernetes cluster.
|
||||
4. Make sure `open-iscsi` has been installed, and the `iscsid` daemon is running on all nodes of the Kubernetes cluster. For GKE, recommended Ubuntu as guest OS image since it contains `open-iscsi` already.
|
||||
|
||||
## Upgrading to Kubernetes v1.25+
|
||||
|
||||
Starting in Kubernetes v1.25, [Pod Security Policies](https://kubernetes.io/docs/concepts/security/pod-security-policy/) have been removed from the Kubernetes API.
|
||||
|
||||
As a result, **before upgrading to Kubernetes v1.25** (or on a fresh install in a Kubernetes v1.25+ cluster), users are expected to perform an in-place upgrade of this chart with `enablePSP` set to `false` if it has been previously set to `true`.
|
||||
|
||||
> **Note:**
|
||||
> If you upgrade your cluster to Kubernetes v1.25+ before removing PSPs via a `helm upgrade` (even if you manually clean up resources), **it will leave the Helm release in a broken state within the cluster such that further Helm operations will not work (`helm uninstall`, `helm upgrade`, etc.).**
|
||||
>
|
||||
> If your charts get stuck in this state, you may have to clean up your Helm release secrets.
|
||||
Upon setting `enablePSP` to false, the chart will remove any PSP resources deployed on its behalf from the cluster. This is the default setting for this chart.
|
||||
|
||||
As a replacement for PSPs, [Pod Security Admission](https://kubernetes.io/docs/concepts/security/pod-security-admission/) should be used. Please consult the Longhorn docs for more details on how to configure your chart release namespaces to work with the new Pod Security Admission and apply Pod Security Standards.
|
||||
|
||||
## Installation
|
||||
|
||||
1. Add Longhorn chart repository.
|
||||
```
|
||||
helm repo add longhorn https://charts.longhorn.io
|
||||
```
|
||||
|
||||
2. Update local Longhorn chart information from chart repository.
|
||||
```
|
||||
helm repo update
|
||||
```
|
||||
|
||||
3. Use the following commands to create the `longhorn-system` namespace first, then install the Longhorn chart.
|
||||
|
||||
```
|
||||
kubectl create namespace longhorn-system
|
||||
helm install longhorn longhorn/longhorn --namespace longhorn-system
|
||||
```
|
||||
|
||||
## Uninstallation
|
||||
|
||||
```
|
||||
kubectl -n longhorn-system patch -p '{"value": "true"}' --type=merge lhs deleting-confirmation-flag
|
||||
helm uninstall longhorn -n longhorn-system
|
||||
kubectl delete namespace longhorn-system
|
||||
```
|
||||
|
||||
## Values
|
||||
|
||||
The `values.yaml` contains items used to tweak a deployment of this chart.
|
||||
|
||||
### Cattle Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "global" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Network Policies
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "networkPolicies" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Image Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "image" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Service Settings
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if (and (hasPrefix "service" .Key) (not (contains "Account" .Key))) }}
|
||||
| {{ .Key }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### StorageClass Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "persistence" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### CSI Settings
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "csi" .Key }}
|
||||
| {{ .Key }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Longhorn Manager Settings
|
||||
|
||||
Longhorn consists of user-deployed components (for example, Longhorn Manager, Longhorn Driver, and Longhorn UI) and system-managed components (for example, Instance Manager, Backing Image Manager, Share Manager, CSI Driver, and Engine Image). The following settings only apply to Longhorn Manager.
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "longhornManager" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Longhorn Driver Settings
|
||||
|
||||
Longhorn consists of user-deployed components (for example, Longhorn Manager, Longhorn Driver, and Longhorn UI) and system-managed components (for example, Instance Manager, Backing Image Manager, Share Manager, CSI Driver, and Engine Image). The following settings only apply to Longhorn Driver.
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "longhornDriver" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Longhorn UI Settings
|
||||
|
||||
Longhorn consists of user-deployed components (for example, Longhorn Manager, Longhorn Driver, and Longhorn UI) and system-managed components (for example, Instance Manager, Backing Image Manager, Share Manager, CSI Driver, and Engine Image). The following settings only apply to Longhorn UI.
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "longhornUI" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Ingress Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "ingress" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Private Registry Settings
|
||||
|
||||
You can install Longhorn in an air-gapped environment with a private registry. For more information, see the **Air Gap Installation** section of the [documentation](https://longhorn.io/docs).
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "privateRegistry" .Key }}
|
||||
| {{ .Key }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Metrics Settings
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "metrics" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### OS/Kubernetes Distro Settings
|
||||
|
||||
#### OpenShift Settings
|
||||
|
||||
For more details, see the [ocp-readme](https://github.com/longhorn/longhorn/blob/master/chart/ocp-readme.md).
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "openshift" .Key }}
|
||||
| {{ .Key }} | {{ .Type }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### Other Settings
|
||||
|
||||
| Key | Default | Description |
|
||||
|-----|---------|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if not (or (hasPrefix "defaultSettings" .Key)
|
||||
(hasPrefix "networkPolicies" .Key)
|
||||
(hasPrefix "image" .Key)
|
||||
(hasPrefix "service" .Key)
|
||||
(hasPrefix "persistence" .Key)
|
||||
(hasPrefix "csi" .Key)
|
||||
(hasPrefix "longhornManager" .Key)
|
||||
(hasPrefix "longhornDriver" .Key)
|
||||
(hasPrefix "longhornUI" .Key)
|
||||
(hasPrefix "privateRegistry" .Key)
|
||||
(hasPrefix "ingress" .Key)
|
||||
(hasPrefix "metrics" .Key)
|
||||
(hasPrefix "openshift" .Key)
|
||||
(hasPrefix "global" .Key)) }}
|
||||
| {{ .Key }} | {{ if .Default }}{{ .Default }}{{ else }}{{ .AutoDefault }}{{ end }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
### System Default Settings
|
||||
|
||||
During installation, you can either allow Longhorn to use the default system settings or use specific flags to modify the default values. After installation, you can modify the settings using the Longhorn UI. For more information, see the **Settings Reference** section of the [documentation](https://longhorn.io/docs).
|
||||
|
||||
| Key | Description |
|
||||
|-----|-------------|
|
||||
{{- range .Values }}
|
||||
{{- if hasPrefix "defaultSettings" .Key }}
|
||||
| {{ .Key }} | {{ if .Description }}{{ .Description }}{{ else }}{{ .AutoDescription }}{{ end }} |
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
---
|
||||
Please see [link](https://github.com/longhorn/longhorn) for more information.
|
|
@ -0,0 +1,177 @@
|
|||
# OpenShift / OKD Extra Configuration Steps
|
||||
|
||||
- [OpenShift / OKD Extra Configuration Steps](#openshift--okd-extra-configuration-steps)
|
||||
- [Notes](#notes)
|
||||
- [Known Issues](#known-issues)
|
||||
- [Preparing Nodes (Optional)](#preparing-nodes-optional)
|
||||
- [Default /var/lib/longhorn setup](#default-varliblonghorn-setup)
|
||||
- [Separate /var/mnt/longhorn setup](#separate-varmntlonghorn-setup)
|
||||
- [Create Filesystem](#create-filesystem)
|
||||
- [Mounting Disk On Boot](#mounting-disk-on-boot)
|
||||
- [Label and Annotate Nodes](#label-and-annotate-nodes)
|
||||
- [Example values.yaml](#example-valuesyaml)
|
||||
- [Installation](#installation)
|
||||
- [Refs](#refs)
|
||||
|
||||
## Notes
|
||||
|
||||
Main changes and tasks for OCP are:
|
||||
|
||||
- On OCP / OKD, the Operating System is Managed by the Cluster
|
||||
- OCP Imposes [Security Context Constraints](https://docs.openshift.com/container-platform/4.11/authentication/managing-security-context-constraints.html)
|
||||
- This requires everything to run with the least privilege possible. For the moment every component has been given access to run as higher privilege.
|
||||
- Something to circle back on is network polices and which components can have their privileges reduced without impacting functionality.
|
||||
- The UI probably can be for example.
|
||||
- openshift/oauth-proxy for authentication to the Longhorn Ui
|
||||
- **⚠️** Currently Scoped to Authenticated Users that can delete a longhorn settings object.
|
||||
- **⚠️** Since the UI it self is not protected, network policies will need to be created to prevent namespace <--> namespace communication against the pod or service object directly.
|
||||
- Anyone with access to the UI Deployment can remove the route restriction. (Namespace Scoped Admin)
|
||||
- Option to use separate disk in /var/mnt/longhorn & MachineConfig file to mount /var/mnt/longhorn
|
||||
- Adding finalizers for mount propagation
|
||||
|
||||
## Known Issues
|
||||
|
||||
- General Feature/Issue Thread
|
||||
- [[FEATURE] Deploying Longhorn on OKD/Openshift](https://github.com/longhorn/longhorn/issues/1831)
|
||||
- 4.10 / 1.23:
|
||||
- 4.10.0-0.okd-2022-03-07-131213 to 4.10.0-0.okd-2022-07-09-073606
|
||||
- Tested, No Known Issues
|
||||
- 4.11 / 1.24:
|
||||
- 4.11.0-0.okd-2022-07-27-052000 to 4.11.0-0.okd-2022-11-19-050030
|
||||
- Tested, No Known Issues
|
||||
- 4.11.0-0.okd-2022-12-02-145640, 4.11.0-0.okd-2023-01-14-152430:
|
||||
- Workaround: [[BUG] Volumes Stuck in Attach/Detach Loop](https://github.com/longhorn/longhorn/issues/4988)
|
||||
- [MachineConfig Patch](https://github.com/longhorn/longhorn/issues/4988#issuecomment-1345676772)
|
||||
- 4.12 / 1.25:
|
||||
- 4.12.0-0.okd-2022-12-05-210624 to 4.12.0-0.okd-2023-01-20-101927
|
||||
- Tested, No Known Issues
|
||||
- 4.12.0-0.okd-2023-01-21-055900 to 4.12.0-0.okd-2023-02-18-033438:
|
||||
- Workaround: [[BUG] Volumes Stuck in Attach/Detach Loop](https://github.com/longhorn/longhorn/issues/4988)
|
||||
- [MachineConfig Patch](https://github.com/longhorn/longhorn/issues/4988#issuecomment-1345676772)
|
||||
- 4.12.0-0.okd-2023-03-05-022504 - 4.12.0-0.okd-2023-04-16-041331:
|
||||
- Tested, No Known Issues
|
||||
- 4.13 / 1.26:
|
||||
- 4.13.0-0.okd-2023-05-03-001308 - 4.13.0-0.okd-2023-08-18-135805:
|
||||
- Tested, No Known Issues
|
||||
- 4.14 / 1.27:
|
||||
- 4.14.0-0.okd-2023-08-12-022330 - 4.14.0-0.okd-2023-10-28-073550:
|
||||
- Tested, No Known Issues
|
||||
|
||||
## Preparing Nodes (Optional)
|
||||
|
||||
Only required if you require additional customizations, such as storage-less nodes, or secondary disks.
|
||||
|
||||
### Default /var/lib/longhorn setup
|
||||
|
||||
Label each node for storage with:
|
||||
|
||||
```bash
|
||||
oc get nodes --no-headers | awk '{print $1}'
|
||||
|
||||
export NODE="worker-0"
|
||||
oc label node "${NODE}" node.longhorn.io/create-default-disk=true
|
||||
```
|
||||
|
||||
### Separate /var/mnt/longhorn setup
|
||||
|
||||
#### Create Filesystem
|
||||
|
||||
On the storage nodes create a filesystem with the label longhorn:
|
||||
|
||||
```bash
|
||||
oc get nodes --no-headers | awk '{print $1}'
|
||||
|
||||
export NODE="worker-0"
|
||||
oc debug node/${NODE} -t -- chroot /host bash
|
||||
|
||||
# Validate Target Drive is Present
|
||||
lsblk
|
||||
|
||||
export DRIVE="sdb" #vdb
|
||||
sudo mkfs.ext4 -L longhorn /dev/${DRIVE}
|
||||
```
|
||||
|
||||
> ⚠️ Note: If you add New Nodes After the below Machine Config is applied, you will need to also reboot the node.
|
||||
|
||||
#### Mounting Disk On Boot
|
||||
|
||||
The Secondary Drive needs to be mounted on every boot. Save the Concents and Apply the MachineConfig with `oc apply -f`:
|
||||
|
||||
> ⚠️ This will trigger an machine config profile update and reboot all worker nodes on the cluster
|
||||
|
||||
```yaml
|
||||
apiVersion: machineconfiguration.openshift.io/v1
|
||||
kind: MachineConfig
|
||||
metadata:
|
||||
labels:
|
||||
machineconfiguration.openshift.io/role: worker
|
||||
name: 71-mount-storage-worker
|
||||
spec:
|
||||
config:
|
||||
ignition:
|
||||
version: 3.2.0
|
||||
systemd:
|
||||
units:
|
||||
- name: var-mnt-longhorn.mount
|
||||
enabled: true
|
||||
contents: |
|
||||
[Unit]
|
||||
Before=local-fs.target
|
||||
[Mount]
|
||||
Where=/var/mnt/longhorn
|
||||
What=/dev/disk/by-label/longhorn
|
||||
Options=rw,relatime,discard
|
||||
[Install]
|
||||
WantedBy=local-fs.target
|
||||
```
|
||||
|
||||
#### Label and Annotate Nodes
|
||||
|
||||
Label and annotate storage nodes like this:
|
||||
|
||||
```bash
|
||||
oc get nodes --no-headers | awk '{print $1}'
|
||||
|
||||
export NODE="worker-0"
|
||||
oc annotate node ${NODE} --overwrite node.longhorn.io/default-disks-config='[{"path":"/var/mnt/longhorn","allowScheduling":true}]'
|
||||
oc label node ${NODE} node.longhorn.io/create-default-disk=config
|
||||
```
|
||||
|
||||
## Example values.yaml
|
||||
|
||||
Minimum Adjustments Required
|
||||
|
||||
```yaml
|
||||
openshift:
|
||||
oauthProxy:
|
||||
repository: quay.io/openshift/origin-oauth-proxy
|
||||
tag: 4.15 # Use Your OCP/OKD 4.X Version, Current Stable is 4.15
|
||||
|
||||
# defaultSettings: # Preparing nodes (Optional)
|
||||
# createDefaultDiskLabeledNodes: true
|
||||
|
||||
openshift:
|
||||
enabled: true
|
||||
ui:
|
||||
route: "longhorn-ui"
|
||||
port: 443
|
||||
proxy: 8443
|
||||
```
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
# helm template ./chart/ --namespace longhorn-system --values ./chart/values.yaml --no-hooks > longhorn.yaml # Local Testing
|
||||
helm template longhorn --namespace longhorn-system --values values.yaml --no-hooks > longhorn.yaml
|
||||
oc create namespace longhorn-system -o yaml --dry-run=client | oc apply -f -
|
||||
oc apply -f longhorn.yaml -n longhorn-system
|
||||
```
|
||||
|
||||
## Refs
|
||||
|
||||
- <https://docs.openshift.com/container-platform/4.11/storage/persistent_storage/persistent-storage-iscsi.html>
|
||||
- <https://docs.okd.io/4.11/storage/persistent_storage/persistent-storage-iscsi.html>
|
||||
- okd 4.5: <https://github.com/longhorn/longhorn/issues/1831#issuecomment-702690613>
|
||||
- okd 4.6: <https://github.com/longhorn/longhorn/issues/1831#issuecomment-765884631>
|
||||
- oauth-proxy: <https://github.com/openshift/oauth-proxy/blob/master/contrib/sidecar.yaml>
|
||||
- <https://github.com/longhorn/longhorn/issues/1831>
|
File diff suppressed because it is too large
Load Diff
|
@ -11,7 +11,7 @@ rules:
|
|||
verbs:
|
||||
- "*"
|
||||
- apiGroups: [""]
|
||||
resources: ["pods", "events", "persistentvolumes", "persistentvolumeclaims","persistentvolumeclaims/status", "nodes", "proxy/nodes", "pods/log", "secrets", "services", "endpoints", "configmaps", "serviceaccounts"]
|
||||
resources: ["pods", "events", "persistentvolumes", "persistentvolumeclaims", "persistentvolumeclaims/status", "nodes", "proxy/nodes", "pods/log", "secrets", "services", "endpoints", "configmaps", "serviceaccounts"]
|
||||
verbs: ["*"]
|
||||
- apiGroups: [""]
|
||||
resources: ["namespaces"]
|
||||
|
@ -35,14 +35,17 @@ rules:
|
|||
resources: ["volumesnapshotclasses", "volumesnapshots", "volumesnapshotcontents", "volumesnapshotcontents/status"]
|
||||
verbs: ["*"]
|
||||
- apiGroups: ["longhorn.io"]
|
||||
resources: ["volumes", "volumes/status", "engines", "engines/status", "replicas", "replicas/status", "settings",
|
||||
resources: ["volumes", "volumes/status", "engines", "engines/status", "replicas", "replicas/status", "settings", "settings/status",
|
||||
"engineimages", "engineimages/status", "nodes", "nodes/status", "instancemanagers", "instancemanagers/status",
|
||||
{{- if .Values.openshift.enabled }}
|
||||
"engineimages/finalizers", "nodes/finalizers", "instancemanagers/finalizers",
|
||||
{{- end }}
|
||||
"sharemanagers", "sharemanagers/status", "backingimages", "backingimages/status",
|
||||
"backingimagemanagers", "backingimagemanagers/status", "backingimagedatasources", "backingimagedatasources/status",
|
||||
"backuptargets", "backuptargets/status", "backupvolumes", "backupvolumes/status", "backups", "backups/status",
|
||||
"recurringjobs", "recurringjobs/status", "orphans", "orphans/status", "snapshots", "snapshots/status",
|
||||
"supportbundles", "supportbundles/status", "systembackups", "systembackups/status", "systemrestores", "systemrestores/status",
|
||||
"volumeattachments", "volumeattachments/status"]
|
||||
"volumeattachments", "volumeattachments/status", "backupbackingimages", "backupbackingimages/status"]
|
||||
verbs: ["*"]
|
||||
- apiGroups: ["coordination.k8s.io"]
|
||||
resources: ["leases"]
|
||||
|
@ -59,3 +62,16 @@ rules:
|
|||
- apiGroups: ["rbac.authorization.k8s.io"]
|
||||
resources: ["roles", "rolebindings", "clusterrolebindings", "clusterroles"]
|
||||
verbs: ["*"]
|
||||
{{- if .Values.openshift.enabled }}
|
||||
---
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRole
|
||||
metadata:
|
||||
name: longhorn-ocp-privileged-role
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
rules:
|
||||
- apiGroups: ["security.openshift.io"]
|
||||
resources: ["securitycontextconstraints"]
|
||||
resourceNames: ["anyuid", "privileged"]
|
||||
verbs: ["use"]
|
||||
{{- end }}
|
||||
|
|
|
@ -25,3 +25,25 @@ subjects:
|
|||
- kind: ServiceAccount
|
||||
name: longhorn-support-bundle
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
{{- if .Values.openshift.enabled }}
|
||||
---
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRoleBinding
|
||||
metadata:
|
||||
name: longhorn-ocp-privileged-bind
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
roleRef:
|
||||
apiGroup: rbac.authorization.k8s.io
|
||||
kind: ClusterRole
|
||||
name: longhorn-ocp-privileged-role
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: longhorn-service-account
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
- kind: ServiceAccount
|
||||
name: longhorn-ui-service-account
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
- kind: ServiceAccount
|
||||
name: default # supportbundle-agent-support-bundle uses default sa
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
{{- end }}
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -45,6 +45,9 @@ spec:
|
|||
- "{{ template "registry_url" . }}{{ .Values.image.longhorn.manager.repository }}:{{ .Values.image.longhorn.manager.tag }}"
|
||||
- --service-account
|
||||
- longhorn-service-account
|
||||
{{- if .Values.preUpgradeChecker.upgradeVersionCheck}}
|
||||
- --upgrade-version-check
|
||||
{{- end }}
|
||||
ports:
|
||||
- containerPort: 9500
|
||||
name: manager
|
||||
|
@ -60,16 +63,31 @@ spec:
|
|||
port: 9501
|
||||
scheme: HTTPS
|
||||
volumeMounts:
|
||||
- name: boot
|
||||
mountPath: /host/boot/
|
||||
readOnly: true
|
||||
- name: dev
|
||||
mountPath: /host/dev/
|
||||
- name: proc
|
||||
mountPath: /host/proc/
|
||||
readOnly: true
|
||||
- name: etc
|
||||
mountPath: /host/etc/
|
||||
readOnly: true
|
||||
- name: longhorn
|
||||
mountPath: /var/lib/longhorn/
|
||||
mountPropagation: Bidirectional
|
||||
- name: longhorn-grpc-tls
|
||||
mountPath: /tls-files/
|
||||
{{- if .Values.enableGoCoverDir }}
|
||||
- name: go-cover-dir
|
||||
mountPath: /go-cover-dir/
|
||||
{{- end }}
|
||||
env:
|
||||
- name: POD_NAME
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: metadata.name
|
||||
- name: POD_NAMESPACE
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
|
@ -82,16 +100,36 @@ spec:
|
|||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: spec.nodeName
|
||||
{{- if .Values.enableGoCoverDir }}
|
||||
- name: GOCOVERDIR
|
||||
value: /go-cover-dir/
|
||||
{{- end }}
|
||||
- name: pre-pull-share-manager-image
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
image: {{ template "registry_url" . }}{{ .Values.image.longhorn.shareManager.repository }}:{{ .Values.image.longhorn.shareManager.tag }}
|
||||
command: ["sh", "-c", "echo share-manager image pulled && sleep infinity"]
|
||||
volumes:
|
||||
- name: boot
|
||||
hostPath:
|
||||
path: /boot/
|
||||
- name: dev
|
||||
hostPath:
|
||||
path: /dev/
|
||||
- name: proc
|
||||
hostPath:
|
||||
path: /proc/
|
||||
- name: etc
|
||||
hostPath:
|
||||
path: /etc/
|
||||
- name: longhorn
|
||||
hostPath:
|
||||
path: /var/lib/longhorn/
|
||||
{{- if .Values.enableGoCoverDir }}
|
||||
- name: go-cover-dir
|
||||
hostPath:
|
||||
path: /go-cover-dir/
|
||||
type: DirectoryOrCreate
|
||||
{{- end }}
|
||||
- name: longhorn-grpc-tls
|
||||
secret:
|
||||
secretName: longhorn-grpc-tls
|
||||
|
@ -103,22 +141,22 @@ spec:
|
|||
{{- if .Values.longhornManager.priorityClass }}
|
||||
priorityClassName: {{ .Values.longhornManager.priorityClass | quote }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
tolerations:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.tolerations }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.tolerations | indent 6 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.tolerations }}
|
||||
{{ toYaml .Values.longhornManager.tolerations | indent 6 }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations }}
|
||||
{{ default .Values.global.tolerations .Values.longhornManager.tolerations | toYaml | indent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
nodeSelector:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.nodeSelector }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.nodeSelector }}
|
||||
{{ toYaml .Values.longhornManager.nodeSelector | indent 8 }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector }}
|
||||
{{ default .Values.global.nodeSelector .Values.longhornManager.nodeSelector | toYaml | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
serviceAccountName: longhorn-service-account
|
||||
|
@ -139,7 +177,6 @@ metadata:
|
|||
{{- end }}
|
||||
spec:
|
||||
type: {{ .Values.service.manager.type }}
|
||||
sessionAffinity: ClientIP
|
||||
selector:
|
||||
app: longhorn-manager
|
||||
ports:
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: longhorn-default-resource
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
data:
|
||||
default-resource.yaml: |-
|
||||
{{- if not (kindIs "invalid" .Values.defaultBackupStore.backupTarget) }}
|
||||
backup-target: {{ .Values.defaultBackupStore.backupTarget }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultBackupStore.backupTargetCredentialSecret) }}
|
||||
backup-target-credential-secret: {{ .Values.defaultBackupStore.backupTargetCredentialSecret }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultBackupStore.pollInterval) }}
|
||||
backupstore-poll-interval: {{ .Values.defaultBackupStore.pollInterval }}
|
||||
{{- end }}
|
|
@ -6,26 +6,66 @@ metadata:
|
|||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
data:
|
||||
default-setting.yaml: |-
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.backupTarget) }}backup-target: {{ .Values.defaultSettings.backupTarget }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.backupTargetCredentialSecret) }}backup-target-credential-secret: {{ .Values.defaultSettings.backupTargetCredentialSecret }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.allowRecurringJobWhileVolumeDetached) }}allow-recurring-job-while-volume-detached: {{ .Values.defaultSettings.allowRecurringJobWhileVolumeDetached }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.createDefaultDiskLabeledNodes) }}create-default-disk-labeled-nodes: {{ .Values.defaultSettings.createDefaultDiskLabeledNodes }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.defaultDataPath) }}default-data-path: {{ .Values.defaultSettings.defaultDataPath }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.replicaSoftAntiAffinity) }}replica-soft-anti-affinity: {{ .Values.defaultSettings.replicaSoftAntiAffinity }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.replicaAutoBalance) }}replica-auto-balance: {{ .Values.defaultSettings.replicaAutoBalance }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.storageOverProvisioningPercentage) }}storage-over-provisioning-percentage: {{ .Values.defaultSettings.storageOverProvisioningPercentage }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.storageMinimalAvailablePercentage) }}storage-minimal-available-percentage: {{ .Values.defaultSettings.storageMinimalAvailablePercentage }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.storageReservedPercentageForDefaultDisk) }}storage-reserved-percentage-for-default-disk: {{ .Values.defaultSettings.storageReservedPercentageForDefaultDisk }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.upgradeChecker) }}upgrade-checker: {{ .Values.defaultSettings.upgradeChecker }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.defaultReplicaCount) }}default-replica-count: {{ .Values.defaultSettings.defaultReplicaCount }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.defaultDataLocality) }}default-data-locality: {{ .Values.defaultSettings.defaultDataLocality }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.defaultLonghornStaticStorageClass) }}default-longhorn-static-storage-class: {{ .Values.defaultSettings.defaultLonghornStaticStorageClass }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.backupstorePollInterval) }}backupstore-poll-interval: {{ .Values.defaultSettings.backupstorePollInterval }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.failedBackupTTL) }}failed-backup-ttl: {{ .Values.defaultSettings.failedBackupTTL }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.restoreVolumeRecurringJobs) }}restore-volume-recurring-jobs: {{ .Values.defaultSettings.restoreVolumeRecurringJobs }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.recurringSuccessfulJobsHistoryLimit) }}recurring-successful-jobs-history-limit: {{ .Values.defaultSettings.recurringSuccessfulJobsHistoryLimit }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.recurringFailedJobsHistoryLimit) }}recurring-failed-jobs-history-limit: {{ .Values.defaultSettings.recurringFailedJobsHistoryLimit }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.supportBundleFailedHistoryLimit) }}support-bundle-failed-history-limit: {{ .Values.defaultSettings.supportBundleFailedHistoryLimit }}{{ end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.allowRecurringJobWhileVolumeDetached) }}
|
||||
allow-recurring-job-while-volume-detached: {{ .Values.defaultSettings.allowRecurringJobWhileVolumeDetached }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.createDefaultDiskLabeledNodes) }}
|
||||
create-default-disk-labeled-nodes: {{ .Values.defaultSettings.createDefaultDiskLabeledNodes }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.defaultDataPath) }}
|
||||
default-data-path: {{ .Values.defaultSettings.defaultDataPath }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.replicaSoftAntiAffinity) }}
|
||||
replica-soft-anti-affinity: {{ .Values.defaultSettings.replicaSoftAntiAffinity }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.replicaAutoBalance) }}
|
||||
replica-auto-balance: {{ .Values.defaultSettings.replicaAutoBalance }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.storageOverProvisioningPercentage) }}
|
||||
storage-over-provisioning-percentage: {{ .Values.defaultSettings.storageOverProvisioningPercentage }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.storageMinimalAvailablePercentage) }}
|
||||
storage-minimal-available-percentage: {{ .Values.defaultSettings.storageMinimalAvailablePercentage }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.storageReservedPercentageForDefaultDisk) }}
|
||||
storage-reserved-percentage-for-default-disk: {{ .Values.defaultSettings.storageReservedPercentageForDefaultDisk }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.upgradeChecker) }}
|
||||
upgrade-checker: {{ .Values.defaultSettings.upgradeChecker }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.upgradeResponderURL) }}
|
||||
upgrade-responder-url: {{ .Values.defaultSettings.upgradeResponderURL }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.defaultReplicaCount) }}
|
||||
default-replica-count: {{ .Values.defaultSettings.defaultReplicaCount }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.defaultDataLocality) }}
|
||||
default-data-locality: {{ .Values.defaultSettings.defaultDataLocality }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.defaultLonghornStaticStorageClass) }}
|
||||
default-longhorn-static-storage-class: {{ .Values.defaultSettings.defaultLonghornStaticStorageClass }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.failedBackupTTL) }}
|
||||
failed-backup-ttl: {{ .Values.defaultSettings.failedBackupTTL }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.backupExecutionTimeout) }}
|
||||
backup-execution-timeout: {{ .Values.defaultSettings.backupExecutionTimeout }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.restoreVolumeRecurringJobs) }}
|
||||
restore-volume-recurring-jobs: {{ .Values.defaultSettings.restoreVolumeRecurringJobs }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.recurringSuccessfulJobsHistoryLimit) }}
|
||||
recurring-successful-jobs-history-limit: {{ .Values.defaultSettings.recurringSuccessfulJobsHistoryLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.recurringJobMaxRetention) }}
|
||||
recurring-job-max-retention: {{ .Values.defaultSettings.recurringJobMaxRetention }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.recurringFailedJobsHistoryLimit) }}
|
||||
recurring-failed-jobs-history-limit: {{ .Values.defaultSettings.recurringFailedJobsHistoryLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.supportBundleFailedHistoryLimit) }}
|
||||
support-bundle-failed-history-limit: {{ .Values.defaultSettings.supportBundleFailedHistoryLimit }}
|
||||
{{- end }}
|
||||
{{- if or (not (kindIs "invalid" .Values.defaultSettings.taintToleration)) (.Values.global.cattle.windowsCluster.enabled) }}
|
||||
taint-toleration: {{ $windowsDefaultSettingTaintToleration := list }}{{ $defaultSettingTaintToleration := list -}}
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.defaultSetting.taintToleration -}}
|
||||
|
@ -46,38 +86,171 @@ data:
|
|||
{{- end -}}
|
||||
{{- $nodeSelector := list $windowsDefaultSettingNodeSelector $defaultSettingNodeSelector }}{{ join ";" (compact $nodeSelector) -}}
|
||||
{{- end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.priorityClass) }}priority-class: {{ .Values.defaultSettings.priorityClass }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.autoSalvage) }}auto-salvage: {{ .Values.defaultSettings.autoSalvage }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.autoDeletePodWhenVolumeDetachedUnexpectedly) }}auto-delete-pod-when-volume-detached-unexpectedly: {{ .Values.defaultSettings.autoDeletePodWhenVolumeDetachedUnexpectedly }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.disableSchedulingOnCordonedNode) }}disable-scheduling-on-cordoned-node: {{ .Values.defaultSettings.disableSchedulingOnCordonedNode }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.replicaZoneSoftAntiAffinity) }}replica-zone-soft-anti-affinity: {{ .Values.defaultSettings.replicaZoneSoftAntiAffinity }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.nodeDownPodDeletionPolicy) }}node-down-pod-deletion-policy: {{ .Values.defaultSettings.nodeDownPodDeletionPolicy }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.nodeDrainPolicy) }}node-drain-policy: {{ .Values.defaultSettings.nodeDrainPolicy }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.replicaReplenishmentWaitInterval) }}replica-replenishment-wait-interval: {{ .Values.defaultSettings.replicaReplenishmentWaitInterval }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.concurrentReplicaRebuildPerNodeLimit) }}concurrent-replica-rebuild-per-node-limit: {{ .Values.defaultSettings.concurrentReplicaRebuildPerNodeLimit }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.concurrentVolumeBackupRestorePerNodeLimit) }}concurrent-volume-backup-restore-per-node-limit: {{ .Values.defaultSettings.concurrentVolumeBackupRestorePerNodeLimit }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.disableRevisionCounter) }}disable-revision-counter: {{ .Values.defaultSettings.disableRevisionCounter }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.systemManagedPodsImagePullPolicy) }}system-managed-pods-image-pull-policy: {{ .Values.defaultSettings.systemManagedPodsImagePullPolicy }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.allowVolumeCreationWithDegradedAvailability) }}allow-volume-creation-with-degraded-availability: {{ .Values.defaultSettings.allowVolumeCreationWithDegradedAvailability }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.autoCleanupSystemGeneratedSnapshot) }}auto-cleanup-system-generated-snapshot: {{ .Values.defaultSettings.autoCleanupSystemGeneratedSnapshot }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.concurrentAutomaticEngineUpgradePerNodeLimit) }}concurrent-automatic-engine-upgrade-per-node-limit: {{ .Values.defaultSettings.concurrentAutomaticEngineUpgradePerNodeLimit }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.backingImageCleanupWaitInterval) }}backing-image-cleanup-wait-interval: {{ .Values.defaultSettings.backingImageCleanupWaitInterval }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.backingImageRecoveryWaitInterval) }}backing-image-recovery-wait-interval: {{ .Values.defaultSettings.backingImageRecoveryWaitInterval }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.guaranteedInstanceManagerCPU) }}guaranteed-instance-manager-cpu: {{ .Values.defaultSettings.guaranteedInstanceManagerCPU }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.kubernetesClusterAutoscalerEnabled) }}kubernetes-cluster-autoscaler-enabled: {{ .Values.defaultSettings.kubernetesClusterAutoscalerEnabled }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.orphanAutoDeletion) }}orphan-auto-deletion: {{ .Values.defaultSettings.orphanAutoDeletion }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.storageNetwork) }}storage-network: {{ .Values.defaultSettings.storageNetwork }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.deletingConfirmationFlag) }}deleting-confirmation-flag: {{ .Values.defaultSettings.deletingConfirmationFlag }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.engineReplicaTimeout) }}engine-replica-timeout: {{ .Values.defaultSettings.engineReplicaTimeout }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.snapshotDataIntegrity) }}snapshot-data-integrity: {{ .Values.defaultSettings.snapshotDataIntegrity }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.snapshotDataIntegrityImmediateCheckAfterSnapshotCreation) }}snapshot-data-integrity-immediate-check-after-snapshot-creation: {{ .Values.defaultSettings.snapshotDataIntegrityImmediateCheckAfterSnapshotCreation }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.snapshotDataIntegrityCronjob) }}snapshot-data-integrity-cronjob: {{ .Values.defaultSettings.snapshotDataIntegrityCronjob }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.removeSnapshotsDuringFilesystemTrim) }}remove-snapshots-during-filesystem-trim: {{ .Values.defaultSettings.removeSnapshotsDuringFilesystemTrim }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.fastReplicaRebuildEnabled) }}fast-replica-rebuild-enabled: {{ .Values.defaultSettings.fastReplicaRebuildEnabled }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.replicaFileSyncHttpClientTimeout) }}replica-file-sync-http-client-timeout: {{ .Values.defaultSettings.replicaFileSyncHttpClientTimeout }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.logLevel) }}log-level: {{ .Values.defaultSettings.logLevel }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.backupCompressionMethod) }}backup-compression-method: {{ .Values.defaultSettings.backupCompressionMethod }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.backupConcurrentLimit) }}backup-concurrent-limit: {{ .Values.defaultSettings.backupConcurrentLimit }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.restoreConcurrentLimit) }}restore-concurrent-limit: {{ .Values.defaultSettings.restoreConcurrentLimit }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.v2DataEngine) }}v2-data-engine: {{ .Values.defaultSettings.v2DataEngine }}{{ end }}
|
||||
{{ if not (kindIs "invalid" .Values.defaultSettings.offlineReplicaRebuilding) }}offline-replica-rebuilding: {{ .Values.defaultSettings.offlineReplicaRebuilding }}{{ end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.priorityClass) }}
|
||||
priority-class: {{ .Values.defaultSettings.priorityClass }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.autoSalvage) }}
|
||||
auto-salvage: {{ .Values.defaultSettings.autoSalvage }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.autoDeletePodWhenVolumeDetachedUnexpectedly) }}
|
||||
auto-delete-pod-when-volume-detached-unexpectedly: {{ .Values.defaultSettings.autoDeletePodWhenVolumeDetachedUnexpectedly }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.disableSchedulingOnCordonedNode) }}
|
||||
disable-scheduling-on-cordoned-node: {{ .Values.defaultSettings.disableSchedulingOnCordonedNode }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.replicaZoneSoftAntiAffinity) }}
|
||||
replica-zone-soft-anti-affinity: {{ .Values.defaultSettings.replicaZoneSoftAntiAffinity }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.replicaDiskSoftAntiAffinity) }}
|
||||
replica-disk-soft-anti-affinity: {{ .Values.defaultSettings.replicaDiskSoftAntiAffinity }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.nodeDownPodDeletionPolicy) }}
|
||||
node-down-pod-deletion-policy: {{ .Values.defaultSettings.nodeDownPodDeletionPolicy }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.nodeDrainPolicy) }}
|
||||
node-drain-policy: {{ .Values.defaultSettings.nodeDrainPolicy }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.detachManuallyAttachedVolumesWhenCordoned) }}
|
||||
detach-manually-attached-volumes-when-cordoned: {{ .Values.defaultSettings.detachManuallyAttachedVolumesWhenCordoned }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.replicaReplenishmentWaitInterval) }}
|
||||
replica-replenishment-wait-interval: {{ .Values.defaultSettings.replicaReplenishmentWaitInterval }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.concurrentReplicaRebuildPerNodeLimit) }}
|
||||
concurrent-replica-rebuild-per-node-limit: {{ .Values.defaultSettings.concurrentReplicaRebuildPerNodeLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.concurrentVolumeBackupRestorePerNodeLimit) }}
|
||||
concurrent-volume-backup-restore-per-node-limit: {{ .Values.defaultSettings.concurrentVolumeBackupRestorePerNodeLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.disableRevisionCounter) }}
|
||||
disable-revision-counter: {{ .Values.defaultSettings.disableRevisionCounter }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.systemManagedPodsImagePullPolicy) }}
|
||||
system-managed-pods-image-pull-policy: {{ .Values.defaultSettings.systemManagedPodsImagePullPolicy }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.allowVolumeCreationWithDegradedAvailability) }}
|
||||
allow-volume-creation-with-degraded-availability: {{ .Values.defaultSettings.allowVolumeCreationWithDegradedAvailability }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.autoCleanupSystemGeneratedSnapshot) }}
|
||||
auto-cleanup-system-generated-snapshot: {{ .Values.defaultSettings.autoCleanupSystemGeneratedSnapshot }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.autoCleanupRecurringJobBackupSnapshot) }}
|
||||
auto-cleanup-recurring-job-backup-snapshot: {{ .Values.defaultSettings.autoCleanupRecurringJobBackupSnapshot }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.concurrentAutomaticEngineUpgradePerNodeLimit) }}
|
||||
concurrent-automatic-engine-upgrade-per-node-limit: {{ .Values.defaultSettings.concurrentAutomaticEngineUpgradePerNodeLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.backingImageCleanupWaitInterval) }}
|
||||
backing-image-cleanup-wait-interval: {{ .Values.defaultSettings.backingImageCleanupWaitInterval }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.backingImageRecoveryWaitInterval) }}
|
||||
backing-image-recovery-wait-interval: {{ .Values.defaultSettings.backingImageRecoveryWaitInterval }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.guaranteedInstanceManagerCPU) }}
|
||||
guaranteed-instance-manager-cpu: {{ .Values.defaultSettings.guaranteedInstanceManagerCPU }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.kubernetesClusterAutoscalerEnabled) }}
|
||||
kubernetes-cluster-autoscaler-enabled: {{ .Values.defaultSettings.kubernetesClusterAutoscalerEnabled }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.orphanResourceAutoDeletion) }}
|
||||
orphan-resource-auto-deletion: {{ .Values.defaultSettings.orphanResourceAutoDeletion }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.orphanResourceAutoDeletionGracePeriod) }}
|
||||
orphan-resource-auto-deletion-grace-period: {{ .Values.defaultSettings.orphanResourceAutoDeletionGracePeriod }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.storageNetwork) }}
|
||||
storage-network: {{ .Values.defaultSettings.storageNetwork }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.deletingConfirmationFlag) }}
|
||||
deleting-confirmation-flag: {{ .Values.defaultSettings.deletingConfirmationFlag }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.engineReplicaTimeout) }}
|
||||
engine-replica-timeout: {{ .Values.defaultSettings.engineReplicaTimeout }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.snapshotDataIntegrity) }}
|
||||
snapshot-data-integrity: {{ .Values.defaultSettings.snapshotDataIntegrity }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.snapshotDataIntegrityImmediateCheckAfterSnapshotCreation) }}
|
||||
snapshot-data-integrity-immediate-check-after-snapshot-creation: {{ .Values.defaultSettings.snapshotDataIntegrityImmediateCheckAfterSnapshotCreation }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.snapshotDataIntegrityCronjob) }}
|
||||
snapshot-data-integrity-cronjob: {{ .Values.defaultSettings.snapshotDataIntegrityCronjob }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.removeSnapshotsDuringFilesystemTrim) }}
|
||||
remove-snapshots-during-filesystem-trim: {{ .Values.defaultSettings.removeSnapshotsDuringFilesystemTrim }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.fastReplicaRebuildEnabled) }}
|
||||
fast-replica-rebuild-enabled: {{ .Values.defaultSettings.fastReplicaRebuildEnabled }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.replicaFileSyncHttpClientTimeout) }}
|
||||
replica-file-sync-http-client-timeout: {{ .Values.defaultSettings.replicaFileSyncHttpClientTimeout }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.longGRPCTimeOut) }}
|
||||
long-grpc-timeout: {{ .Values.defaultSettings.longGRPCTimeOut }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.logLevel) }}
|
||||
log-level: {{ .Values.defaultSettings.logLevel }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.backupCompressionMethod) }}
|
||||
backup-compression-method: {{ .Values.defaultSettings.backupCompressionMethod }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.backupConcurrentLimit) }}
|
||||
backup-concurrent-limit: {{ .Values.defaultSettings.backupConcurrentLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.restoreConcurrentLimit) }}
|
||||
restore-concurrent-limit: {{ .Values.defaultSettings.restoreConcurrentLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v1DataEngine) }}
|
||||
v1-data-engine: {{ .Values.defaultSettings.v1DataEngine }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v2DataEngine) }}
|
||||
v2-data-engine: {{ .Values.defaultSettings.v2DataEngine }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v2DataEngineHugepageLimit) }}
|
||||
v2-data-engine-hugepage-limit: {{ .Values.defaultSettings.v2DataEngineHugepageLimit }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.allowEmptyNodeSelectorVolume) }}
|
||||
allow-empty-node-selector-volume: {{ .Values.defaultSettings.allowEmptyNodeSelectorVolume }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.allowEmptyDiskSelectorVolume) }}
|
||||
allow-empty-disk-selector-volume: {{ .Values.defaultSettings.allowEmptyDiskSelectorVolume }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.allowCollectingLonghornUsageMetrics) }}
|
||||
allow-collecting-longhorn-usage-metrics: {{ .Values.defaultSettings.allowCollectingLonghornUsageMetrics }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.disableSnapshotPurge) }}
|
||||
disable-snapshot-purge: {{ .Values.defaultSettings.disableSnapshotPurge }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v2DataEngineGuaranteedInstanceManagerCPU) }}
|
||||
v2-data-engine-guaranteed-instance-manager-cpu: {{ .Values.defaultSettings.v2DataEngineGuaranteedInstanceManagerCPU }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.snapshotMaxCount) }}
|
||||
snapshot-max-count: {{ .Values.defaultSettings.snapshotMaxCount }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v2DataEngineLogLevel) }}
|
||||
v2-data-engine-log-level: {{ .Values.defaultSettings.v2DataEngineLogLevel }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v2DataEngineLogFlags) }}
|
||||
v2-data-engine-log-flags: {{ .Values.defaultSettings.v2DataEngineLogFlags }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v2DataEngineSnapshotDataIntegrity) }}
|
||||
v2-data-engine-snapshot-data-integrity: {{ .Values.defaultSettings.v2DataEngineSnapshotDataIntegrity }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.freezeFilesystemForSnapshot) }}
|
||||
freeze-filesystem-for-snapshot: {{ .Values.defaultSettings.freezeFilesystemForSnapshot }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.autoCleanupSnapshotWhenDeleteBackup) }}
|
||||
auto-cleanup-when-delete-backup: {{ .Values.defaultSettings.autoCleanupSnapshotWhenDeleteBackup }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.autoCleanupSnapshotAfterOnDemandBackupCompleted) }}
|
||||
auto-cleanup-snapshot-after-on-demand-backup-completed: {{ .Values.defaultSettings.autoCleanupSnapshotAfterOnDemandBackupCompleted }}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.rwxVolumeFastFailover) }}
|
||||
rwx-volume-fast-failover: {{ .Values.defaultSettings.rwxVolumeFastFailover}}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.offlineRelicaRebuilding) }}
|
||||
offline-replica-rebuilding: {{ .Values.defaultSettings.offlineRelicaRebuilding}}
|
||||
{{- end }}
|
||||
{{- if not (kindIs "invalid" .Values.defaultSettings.v2DataEngineCPUMask) }}
|
||||
v2-data-engine-cpu-mask: {{ .Values.defaultSettings.v2DataEngineCPUMask }}
|
||||
{{- end }}
|
||||
|
|
|
@ -25,6 +25,9 @@ spec:
|
|||
command:
|
||||
- longhorn-manager
|
||||
- -d
|
||||
{{- if eq .Values.longhornDriver.log.format "json" }}
|
||||
- -j
|
||||
{{- end }}
|
||||
- deploy-driver
|
||||
- --manager-image
|
||||
- "{{ template "registry_url" . }}{{ .Values.image.longhorn.manager.repository }}:{{ .Values.image.longhorn.manager.tag }}"
|
||||
|
@ -87,6 +90,13 @@ spec:
|
|||
- name: CSI_SNAPSHOTTER_REPLICA_COUNT
|
||||
value: {{ .Values.csi.snapshotterReplicaCount | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.enableGoCoverDir }}
|
||||
- name: GOCOVERDIR
|
||||
value: /go-cover-dir/
|
||||
volumeMounts:
|
||||
- name: go-cover-dir
|
||||
mountPath: /go-cover-dir/
|
||||
{{- end }}
|
||||
|
||||
{{- if .Values.privateRegistry.registrySecret }}
|
||||
imagePullSecrets:
|
||||
|
@ -95,24 +105,31 @@ spec:
|
|||
{{- if .Values.longhornDriver.priorityClass }}
|
||||
priorityClassName: {{ .Values.longhornDriver.priorityClass | quote }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornDriver.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornDriver.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
tolerations:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.tolerations }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.tolerations | indent 6 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornDriver.tolerations }}
|
||||
{{ toYaml .Values.longhornDriver.tolerations | indent 6 }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornDriver.tolerations }}
|
||||
{{ default .Values.global.tolerations .Values.longhornDriver.tolerations | toYaml | indent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornDriver.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornDriver.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
nodeSelector:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.nodeSelector }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornDriver.nodeSelector }}
|
||||
{{ toYaml .Values.longhornDriver.nodeSelector | indent 8 }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornDriver.nodeSelector }}
|
||||
{{ default .Values.global.nodeSelector .Values.longhornDriver.nodeSelector | toYaml | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
serviceAccountName: longhorn-service-account
|
||||
securityContext:
|
||||
runAsUser: 0
|
||||
{{- if .Values.enableGoCoverDir }}
|
||||
volumes:
|
||||
- name: go-cover-dir
|
||||
hostPath:
|
||||
path: /go-cover-dir/
|
||||
type: DirectoryOrCreate
|
||||
{{- end }}
|
||||
|
|
|
@ -1,3 +1,41 @@
|
|||
{{- if .Values.openshift.enabled }}
|
||||
{{- if .Values.openshift.ui.route }}
|
||||
# https://github.com/openshift/oauth-proxy/blob/master/contrib/sidecar.yaml
|
||||
# Create a proxy service account and ensure it will use the route "proxy"
|
||||
# Create a secure connection to the proxy via a route
|
||||
apiVersion: route.openshift.io/v1
|
||||
kind: Route
|
||||
metadata:
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
app: longhorn-ui
|
||||
name: {{ .Values.openshift.ui.route }}
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
to:
|
||||
kind: Service
|
||||
name: longhorn-ui
|
||||
tls:
|
||||
termination: reencrypt
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
app: longhorn-ui
|
||||
name: longhorn-ui
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
annotations:
|
||||
service.alpha.openshift.io/serving-cert-secret-name: longhorn-ui-tls
|
||||
spec:
|
||||
ports:
|
||||
- name: longhorn-ui
|
||||
port: {{ .Values.openshift.ui.port | default 443 }}
|
||||
targetPort: {{ .Values.openshift.ui.proxy | default 8443 }}
|
||||
selector:
|
||||
app: longhorn-ui
|
||||
---
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
|
@ -15,26 +53,43 @@ spec:
|
|||
labels: {{- include "longhorn.labels" . | nindent 8 }}
|
||||
app: longhorn-ui
|
||||
spec:
|
||||
serviceAccountName: longhorn-ui-service-account
|
||||
affinity:
|
||||
podAntiAffinity:
|
||||
preferredDuringSchedulingIgnoredDuringExecution:
|
||||
- weight: 1
|
||||
podAffinityTerm:
|
||||
labelSelector:
|
||||
matchExpressions:
|
||||
- key: app
|
||||
operator: In
|
||||
values:
|
||||
- longhorn-ui
|
||||
topologyKey: kubernetes.io/hostname
|
||||
{{- toYaml .Values.longhornUI.affinity | nindent 8 }}
|
||||
containers:
|
||||
{{- if .Values.openshift.enabled }}
|
||||
{{- if .Values.openshift.ui.route }}
|
||||
- name: oauth-proxy
|
||||
{{- if .Values.image.openshift.oauthProxy.repository }}
|
||||
image: {{ template "registry_url" . }}{{ .Values.image.openshift.oauthProxy.repository }}:{{ .Values.image.openshift.oauthProxy.tag }}
|
||||
{{- else }}
|
||||
image: ""
|
||||
{{- end }}
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: {{ .Values.openshift.ui.proxy | default 8443 }}
|
||||
name: public
|
||||
args:
|
||||
- --https-address=:{{ .Values.openshift.ui.proxy | default 8443 }}
|
||||
- --provider=openshift
|
||||
- --openshift-service-account=longhorn-ui-service-account
|
||||
- --upstream=http://localhost:8000
|
||||
- --tls-cert=/etc/tls/private/tls.crt
|
||||
- --tls-key=/etc/tls/private/tls.key
|
||||
- --cookie-secret=SECRET
|
||||
- --openshift-sar={"namespace":"{{ include "release_namespace" . }}","group":"longhorn.io","resource":"setting","verb":"delete"}
|
||||
volumeMounts:
|
||||
- mountPath: /etc/tls/private
|
||||
name: longhorn-ui-tls
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
- name: longhorn-ui
|
||||
image: {{ template "registry_url" . }}{{ .Values.image.longhorn.ui.repository }}:{{ .Values.image.longhorn.ui.tag }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
volumeMounts:
|
||||
- name : nginx-cache
|
||||
- name: nginx-cache
|
||||
mountPath: /var/cache/nginx/
|
||||
- name : nginx-config
|
||||
- name: nginx-config
|
||||
mountPath: /var/config/nginx/
|
||||
- name: var-run
|
||||
mountPath: /var/run/
|
||||
|
@ -47,6 +102,13 @@ spec:
|
|||
- name: LONGHORN_UI_PORT
|
||||
value: "8000"
|
||||
volumes:
|
||||
{{- if .Values.openshift.enabled }}
|
||||
{{- if .Values.openshift.ui.route }}
|
||||
- name: longhorn-ui-tls
|
||||
secret:
|
||||
secretName: longhorn-ui-tls
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
- emptyDir: {}
|
||||
name: nginx-cache
|
||||
- emptyDir: {}
|
||||
|
@ -60,22 +122,22 @@ spec:
|
|||
{{- if .Values.longhornUI.priorityClass }}
|
||||
priorityClassName: {{ .Values.longhornUI.priorityClass | quote }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornUI.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornUI.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
tolerations:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.tolerations }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.tolerations | indent 6 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornUI.tolerations }}
|
||||
{{ toYaml .Values.longhornUI.tolerations | indent 6 }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornUI.tolerations }}
|
||||
{{ default .Values.global.tolerations .Values.longhornUI.tolerations | toYaml | indent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornUI.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornUI.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
nodeSelector:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.nodeSelector }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornUI.nodeSelector }}
|
||||
{{ toYaml .Values.longhornUI.nodeSelector | indent 8 }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornUI.nodeSelector }}
|
||||
{{ default .Values.global.nodeSelector .Values.longhornUI.nodeSelector | toYaml | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
---
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
{{- range .Values.extraObjects }}
|
||||
---
|
||||
{{- tpl (toYaml . ) $ }}
|
||||
{{- end }}
|
|
@ -1,9 +1,5 @@
|
|||
{{- if .Values.ingress.enabled }}
|
||||
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}}
|
||||
apiVersion: networking.k8s.io/v1
|
||||
{{- else -}}
|
||||
apiVersion: networking.k8s.io/v1beta1
|
||||
{{- end }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: longhorn-ingress
|
||||
|
@ -18,7 +14,7 @@ metadata:
|
|||
{{ $key }}: {{ $value | quote }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if and .Values.ingress.ingressClassName (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }}
|
||||
{{- if .Values.ingress.ingressClassName }}
|
||||
ingressClassName: {{ .Values.ingress.ingressClassName }}
|
||||
{{- end }}
|
||||
rules:
|
||||
|
@ -26,19 +22,12 @@ spec:
|
|||
http:
|
||||
paths:
|
||||
- path: {{ default "" .Values.ingress.path }}
|
||||
{{- if (semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion) }}
|
||||
pathType: ImplementationSpecific
|
||||
{{- end }}
|
||||
pathType: {{ default "ImplementationSpecific" .Values.ingress.pathType }}
|
||||
backend:
|
||||
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
|
||||
service:
|
||||
name: longhorn-frontend
|
||||
port:
|
||||
number: 80
|
||||
{{- else }}
|
||||
serviceName: longhorn-frontend
|
||||
servicePort: 80
|
||||
{{- end }}
|
||||
{{- if .Values.ingress.tls }}
|
||||
tls:
|
||||
- hosts:
|
||||
|
|
|
@ -3,7 +3,7 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: backing-image-data-source
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
|
|
|
@ -3,7 +3,7 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: backing-image-manager
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
|
|
|
@ -3,7 +3,7 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: instance-manager
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
|
|
|
@ -3,7 +3,7 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: longhorn-manager
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
|
|
|
@ -3,11 +3,11 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: longhorn-recovery-backend
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
app: longhorn-manager
|
||||
longhorn.io/recovery-backend: longhorn-recovery-backend
|
||||
policyTypes:
|
||||
- Ingress
|
||||
ingress:
|
||||
|
|
|
@ -3,7 +3,7 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: longhorn-ui-frontend
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
|
|
|
@ -3,11 +3,11 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: longhorn-conversion-webhook
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
app: longhorn-manager
|
||||
longhorn.io/conversion-webhook: longhorn-conversion-webhook
|
||||
policyTypes:
|
||||
- Ingress
|
||||
ingress:
|
||||
|
@ -19,11 +19,11 @@ apiVersion: networking.k8s.io/v1
|
|||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: longhorn-admission-webhook
|
||||
namespace: longhorn-system
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
app: longhorn-manager
|
||||
longhorn.io/admission-webhook: longhorn-admission-webhook
|
||||
policyTypes:
|
||||
- Ingress
|
||||
ingress:
|
||||
|
|
|
@ -36,21 +36,21 @@ spec:
|
|||
priorityClassName: {{ .Values.longhornManager.priorityClass | quote }}
|
||||
{{- end }}
|
||||
serviceAccountName: longhorn-service-account
|
||||
{{- if or .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
tolerations:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.tolerations }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.tolerations | indent 6 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.tolerations }}
|
||||
{{ toYaml .Values.longhornManager.tolerations | indent 6 }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations }}
|
||||
{{ default .Values.global.tolerations .Values.longhornManager.tolerations | toYaml | indent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
nodeSelector:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.nodeSelector }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.nodeSelector }}
|
||||
{{ toYaml .Values.longhornManager.nodeSelector | indent 8 }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector }}
|
||||
{{ default .Values.global.nodeSelector .Values.longhornManager.nodeSelector | toYaml | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{{- if .Values.helmPreUpgradeCheckerJob.enabled }}
|
||||
{{- if and .Values.preUpgradeChecker.jobEnabled .Values.preUpgradeChecker.upgradeVersionCheck}}
|
||||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
|
@ -20,39 +20,45 @@ spec:
|
|||
- name: longhorn-pre-upgrade
|
||||
image: {{ template "registry_url" . }}{{ .Values.image.longhorn.manager.repository }}:{{ .Values.image.longhorn.manager.tag }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
securityContext:
|
||||
privileged: true
|
||||
command:
|
||||
- longhorn-manager
|
||||
- pre-upgrade
|
||||
volumeMounts:
|
||||
- name: proc
|
||||
mountPath: /host/proc/
|
||||
env:
|
||||
- name: POD_NAMESPACE
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: metadata.namespace
|
||||
volumes:
|
||||
- name: proc
|
||||
hostPath:
|
||||
path: /proc/
|
||||
restartPolicy: OnFailure
|
||||
{{- if .Values.privateRegistry.registrySecret }}
|
||||
imagePullSecrets:
|
||||
- name: {{ .Values.privateRegistry.registrySecret }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.priorityClass }}
|
||||
priorityClassName: {{ .Values.longhornManager.priorityClass | quote }}
|
||||
{{- end }}
|
||||
serviceAccountName: longhorn-service-account
|
||||
{{- if or .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
tolerations:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.tolerations }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.tolerations | indent 6 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.tolerations }}
|
||||
{{ toYaml .Values.longhornManager.tolerations | indent 6 }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations }}
|
||||
{{ default .Values.global.tolerations .Values.longhornManager.tolerations | toYaml | indent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
nodeSelector:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.nodeSelector }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.nodeSelector }}
|
||||
{{ toYaml .Values.longhornManager.nodeSelector | indent 8 }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector }}
|
||||
{{ default .Values.global.nodeSelector .Values.longhornManager.nodeSelector | toYaml | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: scheduling.k8s.io/v1
|
||||
kind: PriorityClass
|
||||
metadata:
|
||||
name: "longhorn-critical"
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
description: "Ensure Longhorn pods have the highest priority to prevent any unexpected eviction by the Kubernetes scheduler under node pressure"
|
||||
globalDefault: false
|
||||
preemptionPolicy: PreemptLowerPriority
|
||||
value: 1000000000
|
|
@ -11,6 +11,25 @@ metadata:
|
|||
---
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: longhorn-ui-service-account
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
{{- with .Values.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.openshift.enabled }}
|
||||
{{- if .Values.openshift.ui.route }}
|
||||
{{- if not .Values.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{- end }}
|
||||
serviceaccounts.openshift.io/oauth-redirectreference.primary: '{"kind":"OAuthRedirectReference","apiVersion":"v1","reference":{"kind":"Route","name":"longhorn-ui"}}'
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: longhorn-support-bundle
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
|
|
|
@ -0,0 +1,40 @@
|
|||
{{- if .Values.metrics.serviceMonitor.enabled -}}
|
||||
apiVersion: monitoring.coreos.com/v1
|
||||
kind: ServiceMonitor
|
||||
metadata:
|
||||
name: longhorn-prometheus-servicemonitor
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
labels:
|
||||
{{- include "longhorn.labels" . | nindent 4 }}
|
||||
name: longhorn-prometheus-servicemonitor
|
||||
{{- with .Values.metrics.serviceMonitor.additionalLabels }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.metrics.serviceMonitor.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: longhorn-manager
|
||||
namespaceSelector:
|
||||
matchNames:
|
||||
- {{ include "release_namespace" . }}
|
||||
endpoints:
|
||||
- port: manager
|
||||
{{- with .Values.metrics.serviceMonitor.interval }}
|
||||
interval: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.metrics.serviceMonitor.scrapeTimeout }}
|
||||
scrapeTimeout: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.metrics.serviceMonitor.relabelings }}
|
||||
relabelings:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.metrics.serviceMonitor.metricRelabelings }}
|
||||
metricRelabelings:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
|
@ -7,9 +7,8 @@ metadata:
|
|||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
type: ClusterIP
|
||||
sessionAffinity: ClientIP
|
||||
selector:
|
||||
app: longhorn-manager
|
||||
longhorn.io/conversion-webhook: longhorn-conversion-webhook
|
||||
ports:
|
||||
- name: conversion-webhook
|
||||
port: 9501
|
||||
|
@ -24,9 +23,8 @@ metadata:
|
|||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
type: ClusterIP
|
||||
sessionAffinity: ClientIP
|
||||
selector:
|
||||
app: longhorn-manager
|
||||
longhorn.io/admission-webhook: longhorn-admission-webhook
|
||||
ports:
|
||||
- name: admission-webhook
|
||||
port: 9502
|
||||
|
@ -41,34 +39,9 @@ metadata:
|
|||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
type: ClusterIP
|
||||
sessionAffinity: ClientIP
|
||||
selector:
|
||||
app: longhorn-manager
|
||||
longhorn.io/recovery-backend: longhorn-recovery-backend
|
||||
ports:
|
||||
- name: recovery-backend
|
||||
port: 9503
|
||||
targetPort: recov-backend
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
name: longhorn-engine-manager
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
clusterIP: None
|
||||
selector:
|
||||
longhorn.io/component: instance-manager
|
||||
longhorn.io/instance-manager-type: engine
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
labels: {{- include "longhorn.labels" . | nindent 4 }}
|
||||
name: longhorn-replica-manager
|
||||
namespace: {{ include "release_namespace" . }}
|
||||
spec:
|
||||
clusterIP: None
|
||||
selector:
|
||||
longhorn.io/component: instance-manager
|
||||
longhorn.io/instance-manager-type: replica
|
||||
|
|
|
@ -15,7 +15,7 @@ data:
|
|||
provisioner: driver.longhorn.io
|
||||
allowVolumeExpansion: true
|
||||
reclaimPolicy: "{{ .Values.persistence.reclaimPolicy }}"
|
||||
volumeBindingMode: Immediate
|
||||
volumeBindingMode: {{ .Values.persistence.volumeBindingMode | default "Immediate" }}
|
||||
parameters:
|
||||
numberOfReplicas: "{{ .Values.persistence.defaultClassReplicaCount }}"
|
||||
staleReplicaTimeout: "30"
|
||||
|
@ -29,6 +29,9 @@ data:
|
|||
{{- if .Values.persistence.migratable }}
|
||||
migratable: "{{ .Values.persistence.migratable }}"
|
||||
{{- end }}
|
||||
{{- if .Values.persistence.nfsOptions }}
|
||||
nfsOptions: "{{ .Values.persistence.nfsOptions }}"
|
||||
{{- end }}
|
||||
{{- if .Values.persistence.backingImage.enable }}
|
||||
backingImage: {{ .Values.persistence.backingImage.name }}
|
||||
backingImageDataSourceType: {{ .Values.persistence.backingImage.dataSourceType }}
|
||||
|
@ -39,6 +42,19 @@ data:
|
|||
recurringJobSelector: '{{ .Values.persistence.recurringJobSelector.jobList }}'
|
||||
{{- end }}
|
||||
dataLocality: {{ .Values.persistence.defaultDataLocality | quote }}
|
||||
{{- if .Values.persistence.defaultDiskSelector.enable }}
|
||||
diskSelector: "{{ .Values.persistence.defaultDiskSelector.selector }}"
|
||||
{{- end }}
|
||||
{{- if .Values.persistence.defaultNodeSelector.enable }}
|
||||
nodeSelector: "{{ .Values.persistence.defaultNodeSelector.selector }}"
|
||||
{{- end }}
|
||||
{{- if .Values.persistence.removeSnapshotsDuringFilesystemTrim }}
|
||||
unmapMarkSnapChainRemoved: "{{ .Values.persistence.removeSnapshotsDuringFilesystemTrim }}"
|
||||
{{- end }}
|
||||
{{- if .Values.persistence.disableRevisionCounter }}
|
||||
disableRevisionCounter: "{{ .Values.persistence.disableRevisionCounter }}"
|
||||
dataEngine: "{{ .Values.persistence.dataEngine }}"
|
||||
{{- end }}
|
||||
{{- if .Values.persistence.backupTargetName }}
|
||||
backupTargetName: "{{ .Values.persistence.backupTargetName }}"
|
||||
{{- end }}
|
||||
|
|
|
@ -37,21 +37,21 @@ spec:
|
|||
priorityClassName: {{ .Values.longhornManager.priorityClass | quote }}
|
||||
{{- end }}
|
||||
serviceAccountName: longhorn-service-account
|
||||
{{- if or .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations .Values.global.cattle.windowsCluster.enabled }}
|
||||
tolerations:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.tolerations }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.tolerations | indent 6 }}
|
||||
{{- end }}
|
||||
{{- if .Values.longhornManager.tolerations }}
|
||||
{{ toYaml .Values.longhornManager.tolerations | indent 6 }}
|
||||
{{- if or .Values.global.tolerations .Values.longhornManager.tolerations }}
|
||||
{{ default .Values.global.tolerations .Values.longhornManager.tolerations | toYaml | indent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector .Values.global.cattle.windowsCluster.enabled }}
|
||||
nodeSelector:
|
||||
{{- if and .Values.global.cattle.windowsCluster.enabled .Values.global.cattle.windowsCluster.nodeSelector }}
|
||||
{{ toYaml .Values.global.cattle.windowsCluster.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if or .Values.longhornManager.nodeSelector }}
|
||||
{{ toYaml .Values.longhornManager.nodeSelector | indent 8 }}
|
||||
{{- if or .Values.global.nodeSelector .Values.longhornManager.nodeSelector }}
|
||||
{{ default .Values.global.nodeSelector .Values.longhornManager.nodeSelector | toYaml | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
|
|
@ -2,186 +2,382 @@
|
|||
# This is a YAML-formatted file.
|
||||
# Declare variables to be passed into your templates.
|
||||
global:
|
||||
# -- Toleration for nodes allowed to run user-deployed components such as Longhorn Manager, Longhorn UI, and Longhorn Driver Deployer.
|
||||
tolerations: []
|
||||
# -- Node selector for nodes allowed to run user-deployed components such as Longhorn Manager, Longhorn UI, and Longhorn Driver Deployer.
|
||||
nodeSelector: {}
|
||||
cattle:
|
||||
# -- Default system registry.
|
||||
systemDefaultRegistry: ""
|
||||
windowsCluster:
|
||||
# Enable this to allow Longhorn to run on the Rancher deployed Windows cluster
|
||||
# -- Setting that allows Longhorn to run on a Rancher Windows cluster.
|
||||
enabled: false
|
||||
# Tolerate Linux node taint
|
||||
# -- Toleration for Linux nodes that can run user-deployed Longhorn components.
|
||||
tolerations:
|
||||
- key: "cattle.io/os"
|
||||
value: "linux"
|
||||
effect: "NoSchedule"
|
||||
operator: "Equal"
|
||||
# Select Linux nodes
|
||||
- key: "cattle.io/os"
|
||||
value: "linux"
|
||||
effect: "NoSchedule"
|
||||
operator: "Equal"
|
||||
# -- Node selector for Linux nodes that can run user-deployed Longhorn components.
|
||||
nodeSelector:
|
||||
kubernetes.io/os: "linux"
|
||||
# Recognize toleration and node selector for Longhorn run-time created components
|
||||
defaultSetting:
|
||||
# -- Toleration for system-managed Longhorn components.
|
||||
taintToleration: cattle.io/os=linux:NoSchedule
|
||||
# -- Node selector for system-managed Longhorn components.
|
||||
systemManagedComponentsNodeSelector: kubernetes.io/os:linux
|
||||
|
||||
networkPolicies:
|
||||
# -- Setting that allows you to enable network policies that control access to Longhorn pods.
|
||||
enabled: false
|
||||
# Available types: k3s, rke2, rke1
|
||||
# -- Distribution that determines the policy for allowing access for an ingress. (Options: "k3s", "rke2", "rke1")
|
||||
type: "k3s"
|
||||
|
||||
image:
|
||||
longhorn:
|
||||
engine:
|
||||
# -- Repository for the Longhorn Engine image.
|
||||
repository: longhornio/longhorn-engine
|
||||
tag: v1.5.2
|
||||
# -- Tag for the Longhorn Engine image.
|
||||
tag: v1.9.0
|
||||
manager:
|
||||
# -- Repository for the Longhorn Manager image.
|
||||
repository: longhornio/longhorn-manager
|
||||
tag: v1.5.2
|
||||
# -- Tag for the Longhorn Manager image.
|
||||
tag: v1.9.0
|
||||
ui:
|
||||
# -- Repository for the Longhorn UI image.
|
||||
repository: longhornio/longhorn-ui
|
||||
tag: v1.5.2
|
||||
# -- Tag for the Longhorn UI image.
|
||||
tag: v1.9.0
|
||||
instanceManager:
|
||||
# -- Repository for the Longhorn Instance Manager image.
|
||||
repository: longhornio/longhorn-instance-manager
|
||||
tag: v1.5.2
|
||||
# -- Tag for the Longhorn Instance Manager image.
|
||||
tag: v1.9.0
|
||||
shareManager:
|
||||
# -- Repository for the Longhorn Share Manager image.
|
||||
repository: longhornio/longhorn-share-manager
|
||||
tag: v1.5.2
|
||||
# -- Tag for the Longhorn Share Manager image.
|
||||
tag: v1.9.0
|
||||
backingImageManager:
|
||||
# -- Repository for the Backing Image Manager image. When unspecified, Longhorn uses the default value.
|
||||
repository: longhornio/backing-image-manager
|
||||
tag: v1.5.2
|
||||
# -- Tag for the Backing Image Manager image. When unspecified, Longhorn uses the default value.
|
||||
tag: v1.9.0
|
||||
supportBundleKit:
|
||||
# -- Repository for the Longhorn Support Bundle Manager image.
|
||||
repository: longhornio/support-bundle-kit
|
||||
tag: v0.0.27
|
||||
# -- Tag for the Longhorn Support Bundle Manager image.
|
||||
tag: v0.0.55
|
||||
csi:
|
||||
attacher:
|
||||
# -- Repository for the CSI attacher image. When unspecified, Longhorn uses the default value.
|
||||
repository: longhornio/csi-attacher
|
||||
tag: v4.2.0
|
||||
# -- Tag for the CSI attacher image. When unspecified, Longhorn uses the default value.
|
||||
tag: v4.8.1
|
||||
provisioner:
|
||||
# -- Repository for the CSI Provisioner image. When unspecified, Longhorn uses the default value.
|
||||
repository: longhornio/csi-provisioner
|
||||
tag: v3.4.1
|
||||
# -- Tag for the CSI Provisioner image. When unspecified, Longhorn uses the default value.
|
||||
tag: v5.2.0
|
||||
nodeDriverRegistrar:
|
||||
# -- Repository for the CSI Node Driver Registrar image. When unspecified, Longhorn uses the default value.
|
||||
repository: longhornio/csi-node-driver-registrar
|
||||
tag: v2.7.0
|
||||
# -- Tag for the CSI Node Driver Registrar image. When unspecified, Longhorn uses the default value.
|
||||
tag: v2.13.0
|
||||
resizer:
|
||||
# -- Repository for the CSI Resizer image. When unspecified, Longhorn uses the default value.
|
||||
repository: longhornio/csi-resizer
|
||||
tag: v1.7.0
|
||||
# -- Tag for the CSI Resizer image. When unspecified, Longhorn uses the default value.
|
||||
tag: v1.13.2
|
||||
snapshotter:
|
||||
# -- Repository for the CSI Snapshotter image. When unspecified, Longhorn uses the default value.
|
||||
repository: longhornio/csi-snapshotter
|
||||
tag: v6.2.1
|
||||
# -- Tag for the CSI Snapshotter image. When unspecified, Longhorn uses the default value.
|
||||
tag: v8.2.0
|
||||
livenessProbe:
|
||||
# -- Repository for the CSI liveness probe image. When unspecified, Longhorn uses the default value.
|
||||
repository: longhornio/livenessprobe
|
||||
tag: v2.9.0
|
||||
# -- Tag for the CSI liveness probe image. When unspecified, Longhorn uses the default value.
|
||||
tag: v2.15.0
|
||||
openshift:
|
||||
oauthProxy:
|
||||
# -- Repository for the OAuth Proxy image. Specify the upstream image (for example, "quay.io/openshift/origin-oauth-proxy"). This setting applies only to OpenShift users.
|
||||
repository: ""
|
||||
# -- Tag for the OAuth Proxy image. Specify OCP/OKD version 4.1 or later (including version 4.15, which is available at quay.io/openshift/origin-oauth-proxy:4.15). This setting applies only to OpenShift users.
|
||||
tag: ""
|
||||
# -- Image pull policy that applies to all user-deployed Longhorn components, such as Longhorn Manager, Longhorn driver, and Longhorn UI.
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
service:
|
||||
ui:
|
||||
# -- Service type for Longhorn UI. (Options: "ClusterIP", "NodePort", "LoadBalancer", "Rancher-Proxy")
|
||||
type: ClusterIP
|
||||
# -- NodePort port number for Longhorn UI. When unspecified, Longhorn selects a free port between 30000 and 32767.
|
||||
nodePort: null
|
||||
manager:
|
||||
# -- Service type for Longhorn Manager.
|
||||
type: ClusterIP
|
||||
# -- NodePort port number for Longhorn Manager. When unspecified, Longhorn selects a free port between 30000 and 32767.
|
||||
nodePort: ""
|
||||
loadBalancerIP: ""
|
||||
loadBalancerSourceRanges: ""
|
||||
|
||||
persistence:
|
||||
# -- Setting that allows you to specify the default Longhorn StorageClass.
|
||||
defaultClass: true
|
||||
# -- Filesystem type of the default Longhorn StorageClass.
|
||||
defaultFsType: ext4
|
||||
# -- mkfs parameters of the default Longhorn StorageClass.
|
||||
defaultMkfsParams: ""
|
||||
# -- Replica count of the default Longhorn StorageClass.
|
||||
defaultClassReplicaCount: 3
|
||||
defaultDataLocality: disabled # best-effort otherwise
|
||||
# -- Data locality of the default Longhorn StorageClass. (Options: "disabled", "best-effort")
|
||||
defaultDataLocality: disabled
|
||||
# -- Reclaim policy that provides instructions for handling of a volume after its claim is released. (Options: "Retain", "Delete")
|
||||
reclaimPolicy: Delete
|
||||
# -- VolumeBindingMode controls when volume binding and dynamic provisioning should occur. (Options: "Immediate", "WaitForFirstConsumer") (Defaults to "Immediate")
|
||||
volumeBindingMode: "Immediate"
|
||||
# -- Setting that allows you to enable live migration of a Longhorn volume from one node to another.
|
||||
migratable: false
|
||||
# -- Setting that disables the revision counter and thereby prevents Longhorn from tracking all write operations to a volume. When salvaging a volume, Longhorn uses properties of the volume-head-xxx.img file (the last file size and the last time the file was modified) to select the replica to be used for volume recovery.
|
||||
disableRevisionCounter: "true"
|
||||
# -- Set NFS mount options for Longhorn StorageClass for RWX volumes
|
||||
nfsOptions: ""
|
||||
recurringJobSelector:
|
||||
# -- Setting that allows you to enable the recurring job selector for a Longhorn StorageClass.
|
||||
enable: false
|
||||
# -- Recurring job selector for a Longhorn StorageClass. Ensure that quotes are used correctly when specifying job parameters. (Example: `[{"name":"backup", "isGroup":true}]`)
|
||||
jobList: []
|
||||
backingImage:
|
||||
# -- Setting that allows you to use a backing image in a Longhorn StorageClass.
|
||||
enable: false
|
||||
# -- Backing image to be used for creating and restoring volumes in a Longhorn StorageClass. When no backing images are available, specify the data source type and parameters that Longhorn can use to create a backing image.
|
||||
name: ~
|
||||
# -- Data source type of a backing image used in a Longhorn StorageClass.
|
||||
# If the backing image exists in the cluster, Longhorn uses this setting to verify the image.
|
||||
# If the backing image does not exist, Longhorn creates one using the specified data source type.
|
||||
dataSourceType: ~
|
||||
# -- Data source parameters of a backing image used in a Longhorn StorageClass.
|
||||
# You can specify a JSON string of a map. (Example: `'{\"url\":\"https://backing-image-example.s3-region.amazonaws.com/test-backing-image\"}'`)
|
||||
dataSourceParameters: ~
|
||||
# -- Expected SHA-512 checksum of a backing image used in a Longhorn StorageClass.
|
||||
expectedChecksum: ~
|
||||
defaultNodeSelector:
|
||||
enable: false # disable by default
|
||||
defaultDiskSelector:
|
||||
# -- Setting that allows you to enable the disk selector for the default Longhorn StorageClass.
|
||||
enable: false
|
||||
# -- Disk selector for the default Longhorn StorageClass. Longhorn uses only disks with the specified tags for storing volume data. (Examples: "nvme,sata")
|
||||
selector: ""
|
||||
removeSnapshotsDuringFilesystemTrim: ignored # "enabled" or "disabled" otherwise
|
||||
|
||||
helmPreUpgradeCheckerJob:
|
||||
enabled: true
|
||||
|
||||
defaultNodeSelector:
|
||||
# -- Setting that allows you to enable the node selector for the default Longhorn StorageClass.
|
||||
enable: false
|
||||
# -- Node selector for the default Longhorn StorageClass. Longhorn uses only nodes with the specified tags for storing volume data. (Examples: "storage,fast")
|
||||
selector: ""
|
||||
# -- Setting that allows you to enable automatic snapshot removal during filesystem trim for a Longhorn StorageClass. (Options: "ignored", "enabled", "disabled")
|
||||
removeSnapshotsDuringFilesystemTrim: ignored
|
||||
# -- Setting that allows you to specify the data engine version for the default Longhorn StorageClass. (Options: "v1", "v2")
|
||||
dataEngine: v1
|
||||
# -- Setting that allows you to specify the backup target for the default Longhorn StorageClass.
|
||||
backupTargetName: default
|
||||
preUpgradeChecker:
|
||||
# -- Setting that allows Longhorn to perform pre-upgrade checks. Disable this setting when installing Longhorn using Argo CD or other GitOps solutions.
|
||||
jobEnabled: true
|
||||
# -- Setting that allows Longhorn to perform upgrade version checks after starting the Longhorn Manager DaemonSet Pods. Disabling this setting also disables `preUpgradeChecker.jobEnabled`. Longhorn recommends keeping this setting enabled.
|
||||
upgradeVersionCheck: true
|
||||
csi:
|
||||
# -- kubelet root directory. When unspecified, Longhorn uses the default value.
|
||||
kubeletRootDir: ~
|
||||
# -- Replica count of the CSI Attacher. When unspecified, Longhorn uses the default value ("3").
|
||||
attacherReplicaCount: ~
|
||||
# -- Replica count of the CSI Provisioner. When unspecified, Longhorn uses the default value ("3").
|
||||
provisionerReplicaCount: ~
|
||||
# -- Replica count of the CSI Resizer. When unspecified, Longhorn uses the default value ("3").
|
||||
resizerReplicaCount: ~
|
||||
# -- Replica count of the CSI Snapshotter. When unspecified, Longhorn uses the default value ("3").
|
||||
snapshotterReplicaCount: ~
|
||||
|
||||
defaultSettings:
|
||||
backupTarget: ~
|
||||
backupTargetCredentialSecret: ~
|
||||
# -- Setting that allows Longhorn to automatically attach a volume and create snapshots or backups when recurring jobs are run.
|
||||
allowRecurringJobWhileVolumeDetached: ~
|
||||
# -- Setting that allows Longhorn to automatically create a default disk only on nodes with the label "node.longhorn.io/create-default-disk=true" (if no other disks exist). When this setting is disabled, Longhorn creates a default disk on each node that is added to the cluster.
|
||||
createDefaultDiskLabeledNodes: ~
|
||||
# -- Default path for storing data on a host. The default value is "/var/lib/longhorn/".
|
||||
defaultDataPath: ~
|
||||
# -- Default data locality. A Longhorn volume has data locality if a local replica of the volume exists on the same node as the pod that is using the volume.
|
||||
defaultDataLocality: ~
|
||||
# -- Setting that allows scheduling on nodes with healthy replicas of the same volume. This setting is disabled by default.
|
||||
replicaSoftAntiAffinity: ~
|
||||
# -- Setting that automatically rebalances replicas when an available node is discovered.
|
||||
replicaAutoBalance: ~
|
||||
# -- Percentage of storage that can be allocated relative to hard drive capacity. The default value is "100".
|
||||
storageOverProvisioningPercentage: ~
|
||||
# -- Percentage of minimum available disk capacity. When the minimum available capacity exceeds the total available capacity, the disk becomes unschedulable until more space is made available for use. The default value is "25".
|
||||
storageMinimalAvailablePercentage: ~
|
||||
# -- Percentage of disk space that is not allocated to the default disk on each new Longhorn node.
|
||||
storageReservedPercentageForDefaultDisk: ~
|
||||
# -- Upgrade Checker that periodically checks for new Longhorn versions. When a new version is available, a notification appears on the Longhorn UI. This setting is enabled by default
|
||||
upgradeChecker: ~
|
||||
# -- The Upgrade Responder sends a notification whenever a new Longhorn version that you can upgrade to becomes available. The default value is https://longhorn-upgrade-responder.rancher.io/v1/checkupgrade.
|
||||
upgradeResponderURL: ~
|
||||
# -- Default number of replicas for volumes created using the Longhorn UI. For Kubernetes configuration, modify the `numberOfReplicas` field in the StorageClass. The default value is "3".
|
||||
defaultReplicaCount: ~
|
||||
# -- Default name of Longhorn static StorageClass. "storageClassName" is assigned to PVs and PVCs that are created for an existing Longhorn volume. "storageClassName" can also be used as a label, so it is possible to use a Longhorn StorageClass to bind a workload to an existing PV without creating a Kubernetes StorageClass object. "storageClassName" needs to be an existing StorageClass. The default value is "longhorn-static".
|
||||
defaultLonghornStaticStorageClass: ~
|
||||
backupstorePollInterval: ~
|
||||
# -- Number of minutes that Longhorn keeps a failed backup resource. When the value is "0", automatic deletion is disabled.
|
||||
failedBackupTTL: ~
|
||||
# -- Number of minutes that Longhorn allows for the backup execution. The default value is "1".
|
||||
backupExecutionTimeout: ~
|
||||
# -- Setting that restores recurring jobs from a backup volume on a backup target and creates recurring jobs if none exist during backup restoration.
|
||||
restoreVolumeRecurringJobs: ~
|
||||
# -- Maximum number of successful recurring backup and snapshot jobs to be retained. When the value is "0", a history of successful recurring jobs is not retained.
|
||||
recurringSuccessfulJobsHistoryLimit: ~
|
||||
# -- Maximum number of failed recurring backup and snapshot jobs to be retained. When the value is "0", a history of failed recurring jobs is not retained.
|
||||
recurringFailedJobsHistoryLimit: ~
|
||||
# -- Maximum number of snapshots or backups to be retained.
|
||||
recurringJobMaxRetention: ~
|
||||
# -- Maximum number of failed support bundles that can exist in the cluster. When the value is "0", Longhorn automatically purges all failed support bundles.
|
||||
supportBundleFailedHistoryLimit: ~
|
||||
# -- Taint or toleration for system-managed Longhorn components.
|
||||
# Specify values using a semicolon-separated list in `kubectl taint` syntax (Example: key1=value1:effect; key2=value2:effect).
|
||||
taintToleration: ~
|
||||
# -- Node selector for system-managed Longhorn components.
|
||||
systemManagedComponentsNodeSelector: ~
|
||||
priorityClass: ~
|
||||
# -- PriorityClass for system-managed Longhorn components.
|
||||
# This setting can help prevent Longhorn components from being evicted under Node Pressure.
|
||||
# Notice that this will be applied to Longhorn user-deployed components by default if there are no priority class values set yet, such as `longhornManager.priorityClass`.
|
||||
priorityClass: &defaultPriorityClassNameRef "longhorn-critical"
|
||||
# -- Setting that allows Longhorn to automatically salvage volumes when all replicas become faulty (for example, when the network connection is interrupted). Longhorn determines which replicas are usable and then uses these replicas for the volume. This setting is enabled by default.
|
||||
autoSalvage: ~
|
||||
# -- Setting that allows Longhorn to automatically delete a workload pod that is managed by a controller (for example, daemonset) whenever a Longhorn volume is detached unexpectedly (for example, during Kubernetes upgrades). After deletion, the controller restarts the pod and then Kubernetes handles volume reattachment and remounting.
|
||||
autoDeletePodWhenVolumeDetachedUnexpectedly: ~
|
||||
# -- Setting that prevents Longhorn Manager from scheduling replicas on a cordoned Kubernetes node. This setting is enabled by default.
|
||||
disableSchedulingOnCordonedNode: ~
|
||||
# -- Setting that allows Longhorn to schedule new replicas of a volume to nodes in the same zone as existing healthy replicas. Nodes that do not belong to any zone are treated as existing in the zone that contains healthy replicas. When identifying zones, Longhorn relies on the label "topology.kubernetes.io/zone=<Zone name of the node>" in the Kubernetes node object.
|
||||
replicaZoneSoftAntiAffinity: ~
|
||||
# -- Setting that allows scheduling on disks with existing healthy replicas of the same volume. This setting is enabled by default.
|
||||
replicaDiskSoftAntiAffinity: ~
|
||||
# -- Policy that defines the action Longhorn takes when a volume is stuck with a StatefulSet or Deployment pod on a node that failed.
|
||||
nodeDownPodDeletionPolicy: ~
|
||||
# -- Policy that defines the action Longhorn takes when a node with the last healthy replica of a volume is drained.
|
||||
nodeDrainPolicy: ~
|
||||
# -- Setting that allows automatic detaching of manually-attached volumes when a node is cordoned.
|
||||
detachManuallyAttachedVolumesWhenCordoned: ~
|
||||
# -- Number of seconds that Longhorn waits before reusing existing data on a failed replica instead of creating a new replica of a degraded volume.
|
||||
replicaReplenishmentWaitInterval: ~
|
||||
# -- Maximum number of replicas that can be concurrently rebuilt on each node.
|
||||
concurrentReplicaRebuildPerNodeLimit: ~
|
||||
# -- Maximum number of volumes that can be concurrently restored on each node using a backup. When the value is "0", restoration of volumes using a backup is disabled.
|
||||
concurrentVolumeBackupRestorePerNodeLimit: ~
|
||||
disableRevisionCounter: ~
|
||||
# -- Setting that disables the revision counter and thereby prevents Longhorn from tracking all write operations to a volume. When salvaging a volume, Longhorn uses properties of the "volume-head-xxx.img" file (the last file size and the last time the file was modified) to select the replica to be used for volume recovery. This setting applies only to volumes created using the Longhorn UI.
|
||||
disableRevisionCounter: "true"
|
||||
# -- Image pull policy for system-managed pods, such as Instance Manager, engine images, and CSI Driver. Changes to the image pull policy are applied only after the system-managed pods restart.
|
||||
systemManagedPodsImagePullPolicy: ~
|
||||
# -- Setting that allows you to create and attach a volume without having all replicas scheduled at the time of creation.
|
||||
allowVolumeCreationWithDegradedAvailability: ~
|
||||
# -- Setting that allows Longhorn to automatically clean up the system-generated snapshot after replica rebuilding is completed.
|
||||
autoCleanupSystemGeneratedSnapshot: ~
|
||||
# -- Setting that allows Longhorn to automatically clean up the snapshot generated by a recurring backup job.
|
||||
autoCleanupRecurringJobBackupSnapshot: ~
|
||||
# -- Maximum number of engines that are allowed to concurrently upgrade on each node after Longhorn Manager is upgraded. When the value is "0", Longhorn does not automatically upgrade volume engines to the new default engine image version.
|
||||
concurrentAutomaticEngineUpgradePerNodeLimit: ~
|
||||
# -- Number of minutes that Longhorn waits before cleaning up the backing image file when no replicas in the disk are using it.
|
||||
backingImageCleanupWaitInterval: ~
|
||||
# -- Number of seconds that Longhorn waits before downloading a backing image file again when the status of all image disk files changes to "failed" or "unknown".
|
||||
backingImageRecoveryWaitInterval: ~
|
||||
# -- Percentage of the total allocatable CPU resources on each node to be reserved for each instance manager pod when the V1 Data Engine is enabled. The default value is "12".
|
||||
guaranteedInstanceManagerCPU: ~
|
||||
# -- Setting that notifies Longhorn that the cluster is using the Kubernetes Cluster Autoscaler.
|
||||
kubernetesClusterAutoscalerEnabled: ~
|
||||
orphanAutoDeletion: ~
|
||||
# -- Enables Longhorn to automatically delete orphaned resources and their associated data or processes (e.g., stale replicas). Orphaned resources on failed or unknown nodes are not automatically cleaned up.
|
||||
# You need to specify the resource types to be deleted using a semicolon-separated list (e.g., `replica-data;instance`). Available items are: `replica-data`, `instance`.
|
||||
orphanResourceAutoDeletion: ~
|
||||
# -- Specifies the wait time, in seconds, before Longhorn automatically deletes an orphaned Custom Resource (CR) and its associated resources.
|
||||
# Note that if a user manually deletes an orphaned CR, the deletion occurs immediately and does not respect this grace period.
|
||||
orphanResourceAutoDeletionGracePeriod: ~
|
||||
# -- Storage network for in-cluster traffic. When unspecified, Longhorn uses the Kubernetes cluster network.
|
||||
storageNetwork: ~
|
||||
# -- Flag that prevents accidental uninstallation of Longhorn.
|
||||
deletingConfirmationFlag: ~
|
||||
# -- Timeout between the Longhorn Engine and replicas. Specify a value between "8" and "30" seconds. The default value is "8".
|
||||
engineReplicaTimeout: ~
|
||||
# -- Setting that allows you to enable and disable snapshot hashing and data integrity checks.
|
||||
snapshotDataIntegrity: ~
|
||||
# -- Setting that allows disabling of snapshot hashing after snapshot creation to minimize impact on system performance.
|
||||
snapshotDataIntegrityImmediateCheckAfterSnapshotCreation: ~
|
||||
# -- Setting that defines when Longhorn checks the integrity of data in snapshot disk files. You must use the Unix cron expression format.
|
||||
snapshotDataIntegrityCronjob: ~
|
||||
# -- Setting that allows Longhorn to automatically mark the latest snapshot and its parent files as removed during a filesystem trim. Longhorn does not remove snapshots containing multiple child files.
|
||||
removeSnapshotsDuringFilesystemTrim: ~
|
||||
# -- Setting that allows fast rebuilding of replicas using the checksum of snapshot disk files. Before enabling this setting, you must set the snapshot-data-integrity value to "enable" or "fast-check".
|
||||
fastReplicaRebuildEnabled: ~
|
||||
# -- Number of seconds that an HTTP client waits for a response from a File Sync server before considering the connection to have failed.
|
||||
replicaFileSyncHttpClientTimeout: ~
|
||||
# -- Number of seconds that Longhorn allows for the completion of replica rebuilding and snapshot cloning operations.
|
||||
longGRPCTimeOut: ~
|
||||
# -- Log levels that indicate the type and severity of logs in Longhorn Manager. The default value is "Info". (Options: "Panic", "Fatal", "Error", "Warn", "Info", "Debug", "Trace")
|
||||
logLevel: ~
|
||||
# -- Setting that allows you to specify a backup compression method.
|
||||
backupCompressionMethod: ~
|
||||
# -- Maximum number of worker threads that can concurrently run for each backup.
|
||||
backupConcurrentLimit: ~
|
||||
# -- Maximum number of worker threads that can concurrently run for each restore operation.
|
||||
restoreConcurrentLimit: ~
|
||||
# -- Setting that allows you to enable the V1 Data Engine.
|
||||
v1DataEngine: ~
|
||||
# -- Setting that allows you to enable the V2 Data Engine, which is based on the Storage Performance Development Kit (SPDK). The V2 Data Engine is an experimental feature and should not be used in production environments.
|
||||
v2DataEngine: ~
|
||||
offlineReplicaRebuilding: ~
|
||||
# -- Setting that allows you to configure maximum huge page size (in MiB) for the V2 Data Engine.
|
||||
v2DataEngineHugepageLimit: ~
|
||||
# -- Number of millicpus on each node to be reserved for each Instance Manager pod when the V2 Data Engine is enabled. The default value is "1250".
|
||||
v2DataEngineGuaranteedInstanceManagerCPU: ~
|
||||
# -- CPU cores on which the Storage Performance Development Kit (SPDK) target daemon should run. The SPDK target daemon is located in each Instance Manager pod. Ensure that the number of cores is less than or equal to the guaranteed Instance Manager CPUs for the V2 Data Engine. The default value is "0x1".
|
||||
v2DataEngineCPUMask: ~
|
||||
# -- Setting that allows scheduling of empty node selector volumes to any node.
|
||||
allowEmptyNodeSelectorVolume: ~
|
||||
# -- Setting that allows scheduling of empty disk selector volumes to any disk.
|
||||
allowEmptyDiskSelectorVolume: ~
|
||||
# -- Setting that allows Longhorn to periodically collect anonymous usage data for product improvement purposes. Longhorn sends collected data to the [Upgrade Responder](https://github.com/longhorn/upgrade-responder) server, which is the data source of the Longhorn Public Metrics Dashboard (https://metrics.longhorn.io). The Upgrade Responder server does not store data that can be used to identify clients, including IP addresses.
|
||||
allowCollectingLonghornUsageMetrics: ~
|
||||
# -- Setting that temporarily prevents all attempts to purge volume snapshots.
|
||||
disableSnapshotPurge: ~
|
||||
# -- Maximum snapshot count for a volume. The value should be between 2 to 250
|
||||
snapshotMaxCount: ~
|
||||
# -- Setting that allows you to configure the log level of the SPDK target daemon (spdk_tgt) of the V2 Data Engine.
|
||||
v2DataEngineLogLevel: ~
|
||||
# -- Setting that allows you to configure the log flags of the SPDK target daemon (spdk_tgt) of the V2 Data Engine.
|
||||
v2DataEngineLogFlags: ~
|
||||
# -- Setting allows you to enable or disable snapshot hashing and data integrity checking for the V2 Data Engine.
|
||||
v2DataEngineSnapshotDataIntegrity: ~
|
||||
# -- Setting that freezes the filesystem on the root partition before a snapshot is created.
|
||||
freezeFilesystemForSnapshot: ~
|
||||
# -- Setting that automatically cleans up the snapshot when the backup is deleted.
|
||||
autoCleanupSnapshotWhenDeleteBackup: ~
|
||||
# -- Setting that automatically cleans up the snapshot after the on-demand backup is completed.
|
||||
autoCleanupSnapshotAfterOnDemandBackupCompleted: ~
|
||||
# -- Setting that allows Longhorn to detect node failure and immediately migrate affected RWX volumes.
|
||||
rwxVolumeFastFailover: ~
|
||||
# -- Enables automatic rebuilding of degraded replicas while the volume is detached. This setting only takes effect if the individual volume setting is set to `ignored` or `enabled`.
|
||||
offlineRelicaRebuilding: ~
|
||||
# -- Setting that allows you to update the default backupstore.
|
||||
defaultBackupStore:
|
||||
# -- Endpoint used to access the default backupstore. (Options: "NFS", "CIFS", "AWS", "GCP", "AZURE")
|
||||
backupTarget: ~
|
||||
# -- Name of the Kubernetes secret associated with the default backup target.
|
||||
backupTargetCredentialSecret: ~
|
||||
# -- Number of seconds that Longhorn waits before checking the default backupstore for new backups. The default value is "300". When the value is "0", polling is disabled.
|
||||
pollInterval: ~
|
||||
privateRegistry:
|
||||
# -- Setting that allows you to create a private registry secret.
|
||||
createSecret: ~
|
||||
# -- URL of a private registry. When unspecified, Longhorn uses the default system registry.
|
||||
registryUrl: ~
|
||||
# -- User account used for authenticating with a private registry.
|
||||
registryUser: ~
|
||||
# -- Password for authenticating with a private registry.
|
||||
registryPasswd: ~
|
||||
# -- Kubernetes secret that allows you to pull images from a private registry. This setting applies only when creation of private registry secrets is enabled. You must include the private registry name in the secret name.
|
||||
registrySecret: ~
|
||||
|
||||
longhornManager:
|
||||
log:
|
||||
## Allowed values are `plain` or `json`.
|
||||
# -- Format of Longhorn Manager logs. (Options: "plain", "json")
|
||||
format: plain
|
||||
priorityClass: ~
|
||||
# -- PriorityClass for Longhorn Manager.
|
||||
priorityClass: *defaultPriorityClassNameRef
|
||||
# -- Toleration for Longhorn Manager on nodes allowed to run Longhorn components.
|
||||
tolerations: []
|
||||
## If you want to set tolerations for Longhorn Manager DaemonSet, delete the `[]` in the line above
|
||||
## and uncomment this example block
|
||||
|
@ -189,19 +385,25 @@ longhornManager:
|
|||
# operator: "Equal"
|
||||
# value: "value"
|
||||
# effect: "NoSchedule"
|
||||
# -- Node selector for Longhorn Manager. Specify the nodes allowed to run Longhorn Manager.
|
||||
nodeSelector: {}
|
||||
## If you want to set node selector for Longhorn Manager DaemonSet, delete the `{}` in the line above
|
||||
## and uncomment this example block
|
||||
# label-key1: "label-value1"
|
||||
# label-key2: "label-value2"
|
||||
# -- Annotation for the Longhorn Manager service.
|
||||
serviceAnnotations: {}
|
||||
## If you want to set annotations for the Longhorn Manager service, delete the `{}` in the line above
|
||||
## and uncomment this example block
|
||||
# annotation-key1: "annotation-value1"
|
||||
# annotation-key2: "annotation-value2"
|
||||
|
||||
longhornDriver:
|
||||
priorityClass: ~
|
||||
log:
|
||||
# -- Format of longhorn-driver logs. (Options: "plain", "json")
|
||||
format: plain
|
||||
# -- PriorityClass for Longhorn Driver.
|
||||
priorityClass: *defaultPriorityClassNameRef
|
||||
# -- Toleration for Longhorn Driver on nodes allowed to run Longhorn components.
|
||||
tolerations: []
|
||||
## If you want to set tolerations for Longhorn Driver Deployer Deployment, delete the `[]` in the line above
|
||||
## and uncomment this example block
|
||||
|
@ -209,15 +411,31 @@ longhornDriver:
|
|||
# operator: "Equal"
|
||||
# value: "value"
|
||||
# effect: "NoSchedule"
|
||||
# -- Node selector for Longhorn Driver. Specify the nodes allowed to run Longhorn Driver.
|
||||
nodeSelector: {}
|
||||
## If you want to set node selector for Longhorn Driver Deployer Deployment, delete the `{}` in the line above
|
||||
## and uncomment this example block
|
||||
# label-key1: "label-value1"
|
||||
# label-key2: "label-value2"
|
||||
|
||||
longhornUI:
|
||||
# -- Replica count for Longhorn UI.
|
||||
replicas: 2
|
||||
priorityClass: ~
|
||||
# -- PriorityClass for Longhorn UI.
|
||||
priorityClass: *defaultPriorityClassNameRef
|
||||
# -- Affinity for Longhorn UI pods. Specify the affinity you want to use for Longhorn UI.
|
||||
affinity:
|
||||
podAntiAffinity:
|
||||
preferredDuringSchedulingIgnoredDuringExecution:
|
||||
- weight: 1
|
||||
podAffinityTerm:
|
||||
labelSelector:
|
||||
matchExpressions:
|
||||
- key: app
|
||||
operator: In
|
||||
values:
|
||||
- longhorn-ui
|
||||
topologyKey: kubernetes.io/hostname
|
||||
# -- Toleration for Longhorn UI on nodes allowed to run Longhorn components.
|
||||
tolerations: []
|
||||
## If you want to set tolerations for Longhorn UI Deployment, delete the `[]` in the line above
|
||||
## and uncomment this example block
|
||||
|
@ -225,36 +443,30 @@ longhornUI:
|
|||
# operator: "Equal"
|
||||
# value: "value"
|
||||
# effect: "NoSchedule"
|
||||
# -- Node selector for Longhorn UI. Specify the nodes allowed to run Longhorn UI.
|
||||
nodeSelector: {}
|
||||
## If you want to set node selector for Longhorn UI Deployment, delete the `{}` in the line above
|
||||
## and uncomment this example block
|
||||
# label-key1: "label-value1"
|
||||
# label-key2: "label-value2"
|
||||
|
||||
ingress:
|
||||
## Set to true to enable ingress record generation
|
||||
# -- Setting that allows Longhorn to generate ingress records for the Longhorn UI service.
|
||||
enabled: false
|
||||
|
||||
## Add ingressClassName to the Ingress
|
||||
## Can replace the kubernetes.io/ingress.class annotation on v1.18+
|
||||
# -- IngressClass resource that contains ingress configuration, including the name of the Ingress controller.
|
||||
# ingressClassName can replace the kubernetes.io/ingress.class annotation used in earlier Kubernetes releases.
|
||||
ingressClassName: ~
|
||||
|
||||
# -- Hostname of the Layer 7 load balancer.
|
||||
host: sslip.io
|
||||
|
||||
## Set this to true in order to enable TLS on the ingress record
|
||||
# -- Setting that allows you to enable TLS on ingress records.
|
||||
tls: false
|
||||
|
||||
## Enable this in order to enable that the backend service will be connected at port 443
|
||||
# -- Setting that allows you to enable secure connections to the Longhorn UI service via port 443.
|
||||
secureBackends: false
|
||||
|
||||
## If TLS is set to true, you must declare what secret will store the key/certificate for TLS
|
||||
# -- TLS secret that contains the private key and certificate to be used for TLS. This setting applies only when TLS is enabled on ingress records.
|
||||
tlsSecret: longhorn.local-tls
|
||||
|
||||
## If ingress is enabled you can set the default ingress path
|
||||
## then you can access the UI by using the following full path {{host}}+{{path}}
|
||||
# -- Default ingress path. You can access the Longhorn UI by following the full ingress path {{host}}+{{path}}.
|
||||
path: /
|
||||
|
||||
## Ingress annotations done as key:value pairs
|
||||
# -- Ingress path type. To maintain backward compatibility, the default value is "ImplementationSpecific".
|
||||
pathType: ImplementationSpecific
|
||||
## If you're using kube-lego, you will want to add:
|
||||
## kubernetes.io/tls-acme: true
|
||||
##
|
||||
|
@ -262,10 +474,12 @@ ingress:
|
|||
## ref: https://github.com/kubernetes/ingress-nginx/blob/master/docs/annotations.md
|
||||
##
|
||||
## If tls is set to true, annotation ingress.kubernetes.io/secure-backends: "true" will automatically be set
|
||||
# -- Ingress annotations in the form of key-value pairs.
|
||||
annotations:
|
||||
# kubernetes.io/ingress.class: nginx
|
||||
# kubernetes.io/tls-acme: true
|
||||
|
||||
# -- Secret that contains a TLS private key and certificate. Use secrets if you want to use your own certificates to secure ingresses.
|
||||
secrets:
|
||||
## If you're providing your own certificates, please use this to add the certificates as secrets
|
||||
## key and certificate should start with -----BEGIN CERTIFICATE----- or
|
||||
|
@ -279,18 +493,47 @@ ingress:
|
|||
# - name: longhorn.local-tls
|
||||
# key:
|
||||
# certificate:
|
||||
|
||||
# For Kubernetes < v1.25, if your cluster enables Pod Security Policy admission controller,
|
||||
# set this to `true` to ship longhorn-psp which allow privileged Longhorn pods to start
|
||||
# -- Setting that allows you to enable pod security policies (PSPs) that allow privileged Longhorn pods to start. This setting applies only to clusters running Kubernetes 1.25 and earlier, and with the built-in Pod Security admission controller enabled.
|
||||
enablePSP: false
|
||||
|
||||
## Specify override namespace, specifically this is useful for using longhorn as sub-chart
|
||||
## and its release namespace is not the `longhorn-system`
|
||||
# -- Specify override namespace, specifically this is useful for using longhorn as sub-chart and its release namespace is not the `longhorn-system`.
|
||||
namespaceOverride: ""
|
||||
|
||||
# Annotations to add to the Longhorn Manager DaemonSet Pods. Optional.
|
||||
# -- Annotation for the Longhorn Manager DaemonSet pods. This setting is optional.
|
||||
annotations: {}
|
||||
|
||||
serviceAccount:
|
||||
# Annotations to add to the service account
|
||||
# -- Annotations to add to the service account
|
||||
annotations: {}
|
||||
metrics:
|
||||
serviceMonitor:
|
||||
# -- Setting that allows the creation of a Prometheus ServiceMonitor resource for Longhorn Manager components.
|
||||
enabled: false
|
||||
# -- Additional labels for the Prometheus ServiceMonitor resource.
|
||||
additionalLabels: {}
|
||||
# -- Annotations for the Prometheus ServiceMonitor resource.
|
||||
annotations: {}
|
||||
# -- Interval at which Prometheus scrapes the metrics from the target.
|
||||
interval: ""
|
||||
# -- Timeout after which Prometheus considers the scrape to be failed.
|
||||
scrapeTimeout: ""
|
||||
# -- Configures the relabeling rules to apply the target’s metadata labels. See the [Prometheus Operator
|
||||
# documentation](https://prometheus-operator.dev/docs/api-reference/api/#monitoring.coreos.com/v1.Endpoint) for
|
||||
# formatting details.
|
||||
relabelings: []
|
||||
# -- Configures the relabeling rules to apply to the samples before ingestion. See the [Prometheus Operator
|
||||
# documentation](https://prometheus-operator.dev/docs/api-reference/api/#monitoring.coreos.com/v1.Endpoint) for
|
||||
# formatting details.
|
||||
metricRelabelings: []
|
||||
## openshift settings
|
||||
openshift:
|
||||
# -- Setting that allows Longhorn to integrate with OpenShift.
|
||||
enabled: false
|
||||
ui:
|
||||
# -- Route for connections between Longhorn and the OpenShift web console.
|
||||
route: "longhorn-ui"
|
||||
# -- Port for accessing the OpenShift web console.
|
||||
port: 443
|
||||
# -- Port for proxy that provides access to the OpenShift web console.
|
||||
proxy: 8443
|
||||
# -- Setting that allows Longhorn to generate code coverage profiles.
|
||||
enableGoCoverDir: false
|
||||
# -- Add extra objects manifests
|
||||
extraObjects: []
|
||||
|
|
Loading…
Reference in New Issue