Skip to content

Commit

Permalink
release(chart/docs/changelog/ci): update CI to use latest k8s version…
Browse files Browse the repository at this point in the history
…, update docs, add helm chart changes for 3.1.0 (#126)

* add helm chart, docs, ci, README.md, developer docs, changelog changes for 3.1.0 release

Signed-off-by: Niladri Halder <[email protected]>

* label typo in ndm-cluster-exporter-service

Signed-off-by: Niladri Halder <[email protected]>

* Fix operator file comment indentation

Signed-off-by: Niladri Halder <[email protected]>

* Fix localpv provisioner file comment indentation

Signed-off-by: Niladri Halder <[email protected]>

* Update Changelog entry date to 3rd January 2022

Signed-off-by: Niladri Halder <[email protected]>

* Fix indentation for BDC_BD_BIND_RETRIES env

Signed-off-by: Niladri Halder <[email protected]>

* Update Changelog entry date to 6th January 2022

Signed-off-by: Niladri Halder <[email protected]>

* Remove trailing whitespaces

Signed-off-by: Niladri Halder <[email protected]>
  • Loading branch information
niladrih authored Jan 11, 2022
1 parent fd3f73e commit f62ccd2
Show file tree
Hide file tree
Showing 24 changed files with 390 additions and 124 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ on:
- 'develop'
- 'v*'
paths-ignore:
- '*.md'
- '**.md'
- 'changelogs/**'
- 'deploy/helm/**'
- 'docs/**'
Expand Down Expand Up @@ -161,6 +161,9 @@ jobs:
integration-test:
runs-on: ubuntu-latest
needs: ['lint', 'unit-test']
strategy:
matrix:
kubernetes: [v1.23.1]
steps:
- name: Set up Go 1.16
uses: actions/setup-go@v2
Expand Down Expand Up @@ -188,10 +191,10 @@ jobs:
openebs/provisioner-localpv:ci
- name: Set up Minikube
uses: manusa/[email protected].2
uses: manusa/[email protected].3
with:
minikube version: 'v1.23.2'
kubernetes version: 'v1.22.3'
minikube version: 'v1.24.0'
kubernetes version: '${{ matrix.kubernetes }}'
driver: none
start args: '--install-addons=false'

Expand Down Expand Up @@ -234,3 +237,4 @@ jobs:
platforms: linux/amd64
tags: |
${{ env.IMAGE_ORG }}/localpv-e2e:ci
12 changes: 8 additions & 4 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ on:
- 'develop'
- 'v*'
paths-ignore:
- '*.md'
- '**.md'
- 'changelogs/**'
- 'deploy/helm/**'
- 'docs/**'
Expand Down Expand Up @@ -96,6 +96,9 @@ jobs:
integration-test:
runs-on: ubuntu-latest
needs: ['lint', 'unit-test']
strategy:
matrix:
kubernetes: [v1.23.1]
steps:
- name: Set up Go 1.16
uses: actions/setup-go@v2
Expand Down Expand Up @@ -123,10 +126,10 @@ jobs:
openebs/provisioner-localpv:ci
- name: Set up Minikube
uses: manusa/[email protected].2
uses: manusa/[email protected].3
with:
minikube version: 'v1.23.2'
kubernetes version: 'v1.22.3'
minikube version: 'v1.24.0'
kubernetes version: '${{ matrix.kubernetes }}'
driver: none
start args: '--install-addons=false'

Expand Down Expand Up @@ -156,3 +159,4 @@ jobs:
platforms: linux/amd64
tags: |
openebs/localpv-e2e:ci
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
v3.1.0 / 2022-01-06
========================
* add support for multiple Node Affinity Labels for both hostpath and device volumes. ([#102](https://github.com/openebs/dynamic-localpv-provisioner/pull/102),[@Ab-hishek](https://https://github.com/Ab-hishek))
* add support for BlockDevice label selectors with device volumes. ([#106](https://github.com/openebs/dynamic-localpv-provisioner/pull/106),[@Ab-hishek](https://https://github.com/Ab-hishek))


v3.0.0 / 2021-09-22
========================
* add support for enabling XFS project quota in hostpath volumes. ([#78](https://github.com/openebs/dynamic-localpv-provisioner/pull/78),[@almas33](https://github.com/almas33))
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,12 @@ differences include:

## Kubernetes Compatibity Matrix

| | Kubernetes <= 1.15 | Kubernetes 1.16 | Kubernetes 1.17 | Kubernetes 1.18 | Kubernetes 1.19 | Kubernetes 1.20 | Kubernetes 1.21 | Kubernetes 1.22 |
|-------------------------------|-----------------|-----------------|-----------------|-----------------|-----------------|-----------------|-----------------|-----------------|
| `localpv-provisioner-2.11.x`/`v2.11.x` |||||||||
| `localpv-provisioner-2.12.x`/`v2.12.x` |||||||||
| `localpv-provisioner-3.0.x`/`v3.0.x` |||||||||
| `HEAD` | ||||||||
| | Kubernetes <= 1.15 | Kubernetes 1.16 | Kubernetes 1.17 | Kubernetes 1.18 | Kubernetes 1.19 | Kubernetes 1.20 | Kubernetes 1.21 | Kubernetes 1.22 | Kubernetes 1.23 |
|-------------------------------|-----------------|-----------------|-----------------|-----------------|-----------------|-----------------|-----------------|-----------------|-----------------|
| `v2.12.x` | | ||||||||
| `v3.0.x` | | ||||||||
| `v3.1.x` | | ||||||||
| `HEAD` | | ||||||||


## Install
Expand All @@ -66,7 +66,7 @@ Please refer to our [Quickstart](https://github.com/openebs/dynamic-localpv-prov

## Contributing

Head over to the [CONTRIBUTING.md](./CONTRIBUTING.md).
Head over to the [CONTRIBUTING.md](./CONTRIBUTING.md) page.

## Roadmap

Expand Down
1 change: 1 addition & 0 deletions changelogs/released/v3.1.0/102-Ab-hishek
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
add support for multiple Node Affinity Labels for both hostpath and device volumes
1 change: 1 addition & 0 deletions changelogs/released/v3.1.0/106-Ab-hishek
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
add support for BlockDevice label selectors with device volumes
6 changes: 3 additions & 3 deletions deploy/helm/charts/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ description: Helm chart for OpenEBS Dynamic Local PV. For instructions to instal
type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
version: 3.0.1
version: 3.1.0
# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application.
appVersion: 3.0.0
appVersion: 3.1.0
icon: https://raw.githubusercontent.com/cncf/artwork/master/projects/openebs/icon/color/openebs-icon-color.png
home: http://www.openebs.io/
keywords:
Expand All @@ -19,7 +19,7 @@ sources:

dependencies:
- name: openebs-ndm
version: "1.7.1"
version: "1.8.0"
repository: "https://openebs.github.io/node-disk-manager"
condition: openebsNDM.enabled

Expand Down
26 changes: 20 additions & 6 deletions deploy/helm/charts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ By default this chart installs additional, dependent charts:

| Repository | Name | Version |
|------------|------|---------|
| https://openebs.github.io/node-disk-manager | openebs-ndm | 1.7.1 |
| https://openebs.github.io/node-disk-manager | openebs-ndm | 1.8.0 |

**Note:** Find detailed Node Disk Manager Helm chart configuration options [here](https://github.com/openebs/node-disk-manager/blob/master/deploy/helm/charts/README.md).

Expand Down Expand Up @@ -90,32 +90,46 @@ helm install openebs-localpv openebs-localpv/localpv-provisioner --namespace ope
--set openebs-ndm.featureGates.UseOSDisk.enabled=true
```

Sample command to install the provisioner with nodeAffinityLabels "openebs.io/node-affinity-key-1" and "openebs.io/node-affinity-key-2" on the hostpath StorageClass:
```console
helm install openebs-localpv openebs-localpv/localpv-provisioner --namespace openebs --create-namespace \
--set-string hostpathClass.nodeAffinityLabels="{openebs.io/node-affinity-key-1,openebs.io/node-affinity-key-2}"
```

Sample command to install the provisioner with blockDeviceSelectors "openebs.io/block-device-tag=mongo" and "ndm.io/fsType=ext4":
```console
helm install openebs-localpv openebs-localpv/localpv-provisioner --namespace openebs --create-namespace \
--set-string deviceClass.blockDeviceSelectors."openebs\.io/block-device-tag"="mongo" \
--set-string deviceClass.blockDeviceSelectors."ndm\.io/fsType"="ext4"
```

| Parameter | Description | Default |
| ------------------------------------------- | --------------------------------------------- | ----------------------------------------- |
| `release.version` | LocalPV Provisioner release version | `3.0.0` |
| `release.version` | LocalPV Provisioner release version | `3.1.0` |
| `analytics.enabled` | Enable sending stats to Google Analytics | `true` |
| `analytics.pingInterval` | Duration(hours) between sending ping stat | `24h` |
| `deviceClass.blockDeviceTag` | Value of `openebs.io/block-device-tag` BD label | `""` |
| `deviceClass.blockDeviceSelectors` | Label key value pairs based on which BlockDevices on the node will be selected for provisioning | `{}` |
| `deviceClass.enabled` | Enables creation of default Device StorageClass | `true` |
| `deviceClass.fsType` | Filesystem type for openebs-device StorageClass | `"ext4"` |
| `deviceClass.isDefaultClass` | Make openebs-device the default StorageClass | `"false"` |
| `deviceClass.nodeAffinityLabels` | Custom node label(or labels) key to uniquely identify nodes. `kubernetes.io/hostname` is the default label key for node selection. | `[]` |
| `deviceClass.reclaimPolicy` | ReclaimPolicy for Device PVs | `"Delete"` |
| `helperPod.image.registry` | Registry for helper image | `""` |
| `helperPod.image.repository` | Image for helper pod | `"openebs/linux-utils"` |
| `helperPod.image.pullPolicy` | Pull policy for helper pod | `"IfNotPresent"` |
| `helperPod.image.tag` | Image tag for helper image | `3.0.0` |
| `helperPod.image.tag` | Image tag for helper image | `3.1.0` |
| `hostpathClass.basePath` | BasePath for openebs-hostpath StorageClass | `"/var/openebs/local"` |
| `hostpathClass.enabled` | Enables creation of default Hostpath StorageClass | `true` |
| `hostpathClass.isDefaultClass` | Make openebs-hostpath the default StorageClass | `"false"` |
| `hostpathClass.nodeAffinityLabel` | Custom node label key to uniquely identify nodes. `kubernetes.io/hostname` is the default label key for node selection. | `""` |
| `hostpathClass.nodeAffinityLabels` | Custom node label(or labels) key to uniquely identify nodes. `kubernetes.io/hostname` is the default label key for node selection. | `[]` |
| `hostpathClass.xfsQuota.enabled` | Enable XFS Quota (requires XFS filesystem) | `false` |
| `hostpathClass.reclaimPolicy` | ReclaimPolicy for Hostpath PVs | `"Delete"` |
| `imagePullSecrets` | Provides image pull secrect | `""` |
| `localpv.enabled` | Enable LocalPV Provisioner | `true` |
| `localpv.image.registry` | Registry for LocalPV Provisioner image | `""` |
| `localpv.image.repository` | Image repository for LocalPV Provisioner | `openebs/localpv-provisioner` |
| `localpv.image.pullPolicy` | Image pull policy for LocalPV Provisioner | `IfNotPresent` |
| `localpv.image.tag` | Image tag for LocalPV Provisioner | `3.0.0` |
| `localpv.image.tag` | Image tag for LocalPV Provisioner | `3.1.0` |
| `localpv.updateStrategy.type` | Update strategy for LocalPV Provisioner | `RollingUpdate` |
| `localpv.annotations` | Annotations for LocalPV Provisioner metadata | `""` |
| `localpv.podAnnotations` | Annotations for LocalPV Provisioner pods metadata | `""` |
Expand Down
2 changes: 1 addition & 1 deletion deploy/helm/charts/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ Get started with the Dynamic LocalPV Provisioner Quickstart guide at:
https://github.com/openebs/dynamic-localpv-provisioner/blob/develop/docs/quickstart.md

For more information, visit our Slack at https://openebs.io/community or view
the OpenEBS documentation online at https://docs.openebs.io.
the OpenEBS documentation online at https://openebs.io/docs
8 changes: 4 additions & 4 deletions deploy/helm/charts/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ spec:
# This is supported for openebs provisioner version 0.5.2 onwards
#- name: OPENEBS_IO_KUBE_CONFIG
# value: "/home/ubuntu/.kube/config"
# This sets the number of times the provisioner should try
# with a polling interval of 5 seconds, to get the Blockdevice
# Name from a BlockDeviceClaim, before the BlockDeviceClaim
# is deleted. E.g. 12 * 5 seconds = 60 seconds timeout
# This sets the number of times the provisioner should try
# with a polling interval of 5 seconds, to get the Blockdevice
# Name from a BlockDeviceClaim, before the BlockDeviceClaim
# is deleted. E.g. 12 * 5 seconds = 60 seconds timeout
- name: BDC_BD_BIND_RETRIES
value: "{{ .Values.localpv.waitForBDBindTimeoutRetryCount }}"
- name: OPENEBS_NAMESPACE
Expand Down
14 changes: 10 additions & 4 deletions deploy/helm/charts/templates/device-class.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,17 @@ metadata:
value: "device"
{{- if .Values.deviceClass.fsType }}
- name: FSType
value: "{{ .Values.deviceClass.fsType }}"
value: {{ .Values.deviceClass.fsType | quote }}
{{- end }}
{{- if .Values.deviceClass.blockDeviceTag }}
- name: BlockDeviceTag
value: "{{ .Values.deviceClass.blockDeviceTag }}"
{{- if .Values.deviceClass.blockDeviceSelectors }}
- name: BlockDeviceSelectors
data:
{{ toYaml .Values.deviceClass.blockDeviceSelectors | indent 10 }}
{{- end }}
{{- if .Values.deviceClass.nodeAffinityLabels }}
- name: NodeAffinityLabels
list:
{{ toYaml .Values.deviceClass.nodeAffinityLabels | indent 10 }}
{{- end }}
{{- if .Values.deviceClass.isDefaultClass }}
storageclass.kubernetes.io/is-default-class: "true"
Expand Down
11 changes: 6 additions & 5 deletions deploy/helm/charts/templates/hostpath-class.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@ metadata:
cas.openebs.io/config: |
- name: StorageType
value: "hostpath"
{{- if .Values.hostpathClass.basePath }}
{{- if or .Values.localpv.basePath .Values.hostpathClass.basePath }}
- name: BasePath
value: "{{ .Values.hostpathClass.basePath }}"
value: {{ .Values.hostpathClass.basePath | default .Values.localpv.basePath | quote }}
{{- end }}
{{- if .Values.hostpathClass.nodeAffinityLabel }}
- name: NodeAffinityLabel
value: "{{ .Values.hostpathClass.nodeAffinityLabel }}"
{{- if .Values.hostpathClass.nodeAffinityLabels }}
- name: NodeAffinityLabels
list:
{{ toYaml .Values.hostpathClass.nodeAffinityLabels | indent 10 }}
{{- end }}
{{- if .Values.hostpathClass.xfsQuota.enabled }}
- name: XFSQuota
Expand Down
43 changes: 34 additions & 9 deletions deploy/helm/charts/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Declare variables to be passed into your templates.

release:
version: "3.0.0"
version: "3.1.0"

rbac:
# rbac.create: `true` if rbac resources should be created
Expand All @@ -23,7 +23,7 @@ localpv:
# For example : quay.io/ is a correct value here and quay.io is incorrect
registry:
repository: openebs/provisioner-localpv
tag: 3.0.0
tag: 3.1.0
pullPolicy: IfNotPresent
updateStrategy:
type: RollingUpdate
Expand Down Expand Up @@ -88,12 +88,32 @@ deviceClass:
reclaimPolicy: Delete
# If true, sets the openebs-device StorageClass as the default StorageClass
isDefaultClass: false
# Custom node affinity label(s) for example "openebs.io/node-affinity-value"
# that will be used instead of hostnames
# This helps in cases where the hostname changes when the node is removed and
# added back with the disks still intact.
# Example:
# nodeAffinityLabels:
# - "openebs.io/node-affinity-key-1"
# - "openebs.io/node-affinity-key-2"
nodeAffinityLabels: []
# Sets the filesystem to be written to the blockdevice before
# mounting (filesystem volumes)
# This is only usable if the selected BlockDevice does not already
# have a filesystem
# Valid values: "ext4", "xfs"
fsType: "ext4"
# Label block devices in the cluster that you would like the openEBS localPV
# Provisioner to pick up those specific block devices available on the node.
# Set the label key and value as shown in the example below.
#
# To read more: https://docs.openebs.io/docs/next/uglocalpv-device.html#optional-block-device-tagging
blockDeviceTag: ""
# To read more: https://github.com/openebs/dynamic-localpv-provisioner/blob/develop/docs/tutorials/device/blockdeviceselectors.md
#
# Example:
# blockDeviceSelectors:
# ndm.io/driveType: "SSD"
# ndm.io/fsType: "none"
blockDeviceSelectors: {}

hostpathClass:
# Name of the default hostpath StorageClass
Expand All @@ -105,12 +125,17 @@ hostpathClass:
# If true, sets the openebs-hostpath StorageClass as the default StorageClass
isDefaultClass: false
# Path on the host where local volumes of this storage class are mounted under.
basePath: "/var/openebs/local"
# Custom node affinity label for example "openebs.io/node-affinity-value" that will be
# used instead of hostnames
# NOTE: If not specified, this defaults to the value of localpv.basePath.
basePath: ""
# Custom node affinity label(s) for example "openebs.io/node-affinity-value"
# that will be used instead of hostnames
# This helps in cases where the hostname changes when the node is removed and
# added back with the disks still intact.
nodeAffinityLabel: ""
# Example:
# nodeAffinityLabels:
# - "openebs.io/node-affinity-key-1"
# - "openebs.io/node-affinity-key-2"
nodeAffinityLabels: []
# Prerequisite: XFS Quota requires an XFS filesystem mounted with
# the 'pquota' or 'prjquota' mount option.
xfsQuota:
Expand All @@ -128,7 +153,7 @@ helperPod:
repository: openebs/linux-utils
pullPolicy: IfNotPresent
# Overrides the image tag whose default is the chart appVersion.
tag: 3.0.0
tag: 3.1.0

analytics:
enabled: true
Expand Down
8 changes: 4 additions & 4 deletions deploy/kubectl/hostpath-operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ spec:
# This is supported for openebs provisioner version 0.5.2 onwards
#- name: OPENEBS_IO_KUBE_CONFIG
# value: "/home/ubuntu/.kube/config"
# This sets the number of times the provisioner should try
# with a polling interval of 5 seconds, to get the Blockdevice
# Name from a BlockDeviceClaim, before the BlockDeviceClaim
# is deleted. E.g. 12 * 5 seconds = 60 seconds timeout
# This sets the number of times the provisioner should try
# with a polling interval of 5 seconds, to get the Blockdevice
# Name from a BlockDeviceClaim, before the BlockDeviceClaim
# is deleted. E.g. 12 * 5 seconds = 60 seconds timeout
- name: BDC_BD_BIND_RETRIES
value: "12"
- name: NODE_NAME
Expand Down
5 changes: 3 additions & 2 deletions deploy/kubectl/openebs-hostpath-sc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@ metadata:
#Specify the node affinity label
# to be added to the PV
#Default: kubernetes.io/hostname
#- name: NodeAffinityLabel
# value: "openebs.io/stg-node-name"
#- name: NodeAffinityLabels
# list:
# - "openebs.io/stg-node-name"
provisioner: openebs.io/local
volumeBindingMode: WaitForFirstConsumer
reclaimPolicy: Delete
Loading

0 comments on commit f62ccd2

Please sign in to comment.