Update Helm chart templates for Longhorn v1.1.0

Longhorn #1906

Signed-off-by: Phan Le <phan.le@rancher.com>
This commit is contained in:
Phan Le 2020-10-23 16:39:05 -07:00 committed by Sheng Yang
parent c2753700b0
commit 9c3ae72954
5 changed files with 182 additions and 18 deletions

View File

@ -22,16 +22,25 @@ rules:
- apiGroups: ["batch"]
resources: ["jobs", "cronjobs"]
verbs: ["*"]
- apiGroups: ["policy"]
resources: ["poddisruptionbudgets"]
verbs: ["*"]
- apiGroups: ["scheduling.k8s.io"]
resources: ["priorityclasses"]
verbs: ["watch", "list"]
- apiGroups: ["storage.k8s.io"]
resources: ["storageclasses", "volumeattachments", "csinodes", "csidrivers"]
verbs: ["*"]
- apiGroups: ["coordination.k8s.io"]
resources: ["leases"]
- apiGroups: ["snapshot.storage.k8s.io"]
resources: ["volumesnapshotclasses", "volumesnapshots", "volumesnapshotcontents", "volumesnapshotcontents/status"]
verbs: ["*"]
- apiGroups: ["longhorn.io"]
resources: ["volumes", "volumes/status", "engines", "engines/status", "replicas", "replicas/status", "settings",
"engineimages", "engineimages/status", "nodes", "nodes/status", "instancemanagers", "instancemanagers/status"]
verbs: ["*"]
- apiGroups: ["coordination.k8s.io"]
resources: ["leases"]
verbs: ["*"]
- apiGroups: ["metrics.k8s.io"]
resources: ["pods", "nodes"]
verbs: ["get", "list"]

View File

@ -17,6 +17,26 @@ spec:
singular: engine
scope: Namespaced
version: v1beta1
additionalPrinterColumns:
- name: State
type: string
description: The current state of the engine
JSONPath: .status.currentState
- name: Node
type: string
description: The node that the engine is on
JSONPath: .spec.nodeID
- name: InstanceManager
type: string
description: The instance manager of the engine
JSONPath: .status.instanceManagerName
- name: Image
type: string
description: The current image of the engine
JSONPath: .status.currentImage
- name: Age
type: date
JSONPath: .metadata.creationTimestamp
subresources:
status: {}
---
@ -39,6 +59,30 @@ spec:
singular: replica
scope: Namespaced
version: v1beta1
additionalPrinterColumns:
- name: State
type: string
description: The current state of the replica
JSONPath: .status.currentState
- name: Node
type: string
description: The node that the replica is on
JSONPath: .spec.nodeID
- name: Disk
type: string
description: The disk that the replica is on
JSONPath: .spec.diskID
- name: InstanceManager
type: string
description: The instance manager of the replica
JSONPath: .status.instanceManagerName
- name: Image
type: string
description: The current image of the replica
JSONPath: .status.currentImage
- name: Age
type: date
JSONPath: .metadata.creationTimestamp
subresources:
status: {}
---
@ -61,6 +105,14 @@ spec:
singular: setting
scope: Namespaced
version: v1beta1
additionalPrinterColumns:
- name: Value
type: string
description: The value of the setting
JSONPath: .value
- name: Age
type: date
JSONPath: .metadata.creationTimestamp
---
apiVersion: apiextensions.k8s.io/v1beta1
kind: CustomResourceDefinition
@ -81,6 +133,30 @@ spec:
singular: volume
scope: Namespaced
version: v1beta1
additionalPrinterColumns:
- name: State
type: string
description: The state of the volume
JSONPath: .status.state
- name: Robustness
type: string
description: The robustness of the volume
JSONPath: .status.robustness
- name: Scheduled
type: string
description: The scheduled condition of the volume
JSONPath: .status.conditions['scheduled']['status']
- name: Size
type: string
description: The size of the volume
JSONPath: .spec.size
- name: Node
type: string
description: The node that the volume is currently attaching to
JSONPath: .status.currentNodeID
- name: Age
type: date
JSONPath: .metadata.creationTimestamp
subresources:
status: {}
---
@ -103,6 +179,26 @@ spec:
singular: engineimage
scope: Namespaced
version: v1beta1
additionalPrinterColumns:
- name: State
type: string
description: State of the engine image
JSONPath: .status.state
- name: Image
type: string
description: The Longhorn engine image
JSONPath: .spec.image
- name: RefCount
type: integer
description: Number of volumes are using the engine image
JSONPath: .status.refCount
- name: BuildDate
type: date
description: The build date of the engine image
JSONPath: .status.buildDate
- name: Age
type: date
JSONPath: .metadata.creationTimestamp
subresources:
status: {}
---
@ -125,6 +221,22 @@ spec:
singular: node
scope: Namespaced
version: v1beta1
additionalPrinterColumns:
- name: Ready
type: string
description: Indicate whether the node is ready
JSONPath: .status.conditions['Ready']['status']
- name: AllowScheduling
type: boolean
description: Indicate whether the user disabled/enabled replica scheduling for the node
JSONPath: .spec.allowScheduling
- name: Schedulable
type: string
description: Indicate whether Longhorn can schedule replicas on the node
JSONPath: .status.conditions['Schedulable']['status']
- name: Age
type: date
JSONPath: .metadata.creationTimestamp
subresources:
status: {}
---
@ -147,5 +259,21 @@ spec:
singular: instancemanager
scope: Namespaced
version: v1beta1
additionalPrinterColumns:
- name: State
type: string
description: The state of the instance manager
JSONPath: .status.currentState
- name: Type
type: string
description: The type of the instance manager (engine or replica)
JSONPath: .spec.type
- name: Node
type: string
description: The node that the instance manager is running on
JSONPath: .spec.nodeID
- name: Age
type: date
JSONPath: .metadata.creationTimestamp
subresources:
status: {}

View File

@ -8,6 +8,7 @@ data:
default-setting.yaml: |-
backup-target: {{ .Values.defaultSettings.backupTarget }}
backup-target-credential-secret: {{ .Values.defaultSettings.backupTargetCredentialSecret }}
allow-recurring-job-while-volume-detached: {{ .Values.defaultSettings.allowRecurringJobWhileVolumeDetached }}
create-default-disk-labeled-nodes: {{ .Values.defaultSettings.createDefaultDiskLabeledNodes }}
default-data-path: {{ .Values.defaultSettings.defaultDataPath }}
replica-soft-anti-affinity: {{ .Values.defaultSettings.replicaSoftAntiAffinity }}
@ -22,7 +23,15 @@ data:
priority-class: {{ .Values.defaultSettings.priorityClass }}
registry-secret: {{ .Values.defaultSettings.registrySecret }}
auto-salvage: {{ .Values.defaultSettings.autoSalvage }}
auto-delete-pod-when-volume-detached-unexpectedly: {{ .Values.defaultSettings.autoDeletePodWhenVolumeDetachedUnexpectedly }}
disable-scheduling-on-cordoned-node: {{ .Values.defaultSettings.disableSchedulingOnCordonedNode }}
replica-zone-soft-anti-affinity: {{ .Values.defaultSettings.replicaZoneSoftAntiAffinity }}
volume-attachment-recovery-policy: {{ .Values.defaultSettings.volumeAttachmentRecoveryPolicy }}
node-down-pod-deletion-policy: {{ .Values.defaultSettings.nodeDownPodDeletionPolicy }}
allow-node-drain-with-last-healthy-replica: {{ .Values.defaultSettings.allowNodeDrainWithLastHealthyReplica }}
mkfs-ext4-parameters: {{ .Values.defaultSettings.mkfsExt4Parameters }}
disable-replica-rebuild: {{ .Values.defaultSettings.disableReplicaRebuild }}
disable-revision-counter: {{ .Values.defaultSettings.disableRevisionCounter }}
system-managed-pods-image-pull-policy: {{ .Values.defaultSettings.systemManagedPodsImagePullPolicy }}
allow-volume-creation-with-degraded-availability: {{ .Values.defaultSettings.allowVolumeCreationWithDegradedAvailability }}
auto-cleanup-system-generated-snapshot: {{ .Values.defaultSettings.autoCleanupSystemGeneratedSnapshot }}

View File

@ -1,18 +1,27 @@
kind: StorageClass
apiVersion: storage.k8s.io/v1
apiVersion: v1
kind: ConfigMap
metadata:
name: longhorn
annotations:
storageclass.kubernetes.io/is-default-class: {{ .Values.persistence.defaultClass | quote }}
name: longhorn-storageclass
namespace: {{ .Release.Namespace }}
labels: {{- include "longhorn.labels" . | nindent 4 }}
provisioner: driver.longhorn.io
allowVolumeExpansion: true
reclaimPolicy: "{{ .Values.persistence.reclaimPolicy }}"
parameters:
numberOfReplicas: "{{ .Values.persistence.defaultClassReplicaCount }}"
staleReplicaTimeout: "30"
fromBackup: ""
baseImage: ""
{{- if .Values.recurringJobs.enable }}
recurringJobs: '{{ .Values.recurringJobs.jobsList | toPrettyJson | indent 2 | trim }}'
{{- end }}
data:
storageclass.yaml: |
kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
name: longhorn
annotations:
storageclass.kubernetes.io/is-default-class: {{ .Values.persistence.defaultClass | quote }}
labels: {{- include "longhorn.labels" . | nindent 4 }}
provisioner: driver.longhorn.io
allowVolumeExpansion: true
reclaimPolicy: "{{ .Values.persistence.reclaimPolicy }}"
volumeBindingMode: Immediate
parameters:
numberOfReplicas: "{{ .Values.persistence.defaultClassReplicaCount }}"
staleReplicaTimeout: "30"
fromBackup: ""
baseImage: ""
{{- if .Values.recurringJobs.enable }}
recurringJobs: '{{ .Values.recurringJobs.jobsList | toPrettyJson | indent 2 | trim }}'
{{- end }}

View File

@ -68,6 +68,7 @@ csi:
defaultSettings:
backupTarget: ~
backupTargetCredentialSecret: ~
allowRecurringJobWhileVolumeDetached: ~
createDefaultDiskLabeledNodes: ~
defaultDataPath: ~
replicaSoftAntiAffinity: ~
@ -82,10 +83,18 @@ defaultSettings:
priorityClass: ~
registrySecret: ~
autoSalvage: ~
autoDeletePodWhenVolumeDetachedUnexpectedly: ~
disableSchedulingOnCordonedNode: ~
replicaZoneSoftAntiAffinity: ~
volumeAttachmentRecoveryPolicy: ~
nodeDownPodDeletionPolicy: ~
allowNodeDrainWithLastHealthyReplica: ~
mkfsExt4Parameters: ~
disableReplicaRebuild: ~
disableRevisionCounter: ~
systemManagedPodsImagePullPolicy: ~
allowVolumeCreationWithDegradedAvailability: ~
autoCleanupSystemGeneratedSnapshot: ~
privateRegistry:
registryUrl: ~