diff --git a/Makefile b/Makefile index 9419493..20c3d1b 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ SHELL := /bin/bash ROOT_DIR := $(dir $(realpath $(lastword $(MAKEFILE_LIST)))) -CHART_VER ?= 0.3.4 +CHART_VER ?= 0.3.5 DRBD_VER ?= 9.0.32-1# another tested value is: 9.1.11 DRBD_UTILS_VER ?= 9.12.1# another tested value is: 9.21.4 diff --git a/README.md b/README.md index 4cd6fa3..6430e76 100644 --- a/README.md +++ b/README.md @@ -186,11 +186,11 @@ By default, master nodes are avoided. To deploy on master nodes, modify `values. #### DaemonSet -Remove `nodeAffinity` +Set in `nodeAffinity: {}` in `values.yaml` #### Job -Set `deployOnMasters: "yes"`, and then Remove `nodeAffinity` +Set `deployOnMasters: "yes"` ## Common Issues @@ -208,4 +208,4 @@ Cause: Secure Boot is not supported yet Solution: - Future release will handle kernel module signing. + Future releases will handle kernel module signing. diff --git a/docker-shipper/Dockerfile.shipper b/docker-shipper/Dockerfile.shipper index 344b7d7..e0842f5 100644 --- a/docker-shipper/Dockerfile.shipper +++ b/docker-shipper/Dockerfile.shipper @@ -102,7 +102,7 @@ RUN set -x && \ find ./user -type f -executable -name 'drbd[a-z]*' -exec mv -v {} /utils/ \; # Create shipper -FROM busybox +FROM alpine ARG DRBD_VER diff --git a/helm/drbd-adapter/Chart.yaml b/helm/drbd-adapter/Chart.yaml index 73cffe3..0fa05ae 100644 --- a/helm/drbd-adapter/Chart.yaml +++ b/helm/drbd-adapter/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version: 0.3.4 # to the chart and its templates, including the app version: 0.3.4 # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.3.4 +version: 0.3.5 # This is the version: 0.3.4 # incremented each time you make changes to the application. Versions are not expected to diff --git a/helm/drbd-adapter/templates/job.yaml b/helm/drbd-adapter/templates/job.yaml index a3b5070..f18bacc 100644 --- a/helm/drbd-adapter/templates/job.yaml +++ b/helm/drbd-adapter/templates/job.yaml @@ -17,6 +17,8 @@ {{ else if regexMatch "ubuntu .*22" $osImage }} {{ $distro = "jammy" }} {{ $tag = "v9.1.11" }} +{{ else if regexMatch "kylin .*v10" $osImage }} + {{ $distro = "kylin10" }} {{ end }} {{ if and (ne $.Values.deployOnMasters "yes") (or (hasKey $node.metadata.labels "node-role.kubernetes.io/master") (hasKey $node.metadata.labels "node-role.kubernetes.io/control-plane"))}} {{ else }} @@ -139,9 +141,11 @@ spec: hostPath: path: /etc/sysconfig/modules type: DirectoryOrCreate + {{ if eq $.Values.useAffinity "yes" }} affinity: nodeAffinity: {{- toYaml $.Values.affinity.nodeAffinity | nindent 10 }} + {{ end }} {{ end }} {{ end }} {{ end }} \ No newline at end of file diff --git a/helm/drbd-adapter/values.yaml b/helm/drbd-adapter/values.yaml index 024841b..a80f1ee 100644 --- a/helm/drbd-adapter/values.yaml +++ b/helm/drbd-adapter/values.yaml @@ -21,11 +21,6 @@ upgrade: "no" # by default check hostname: (yes|no) checkHostname: "yes" -# only apply to "deployKind: job" -# by default NOT deploying on masters (yes|no) -deployOnMasters: "no" - -# only apply to "deployKind: daemonset" # by default drop binary files to the host: (yes|no), drop: "yes" @@ -38,4 +33,10 @@ affinity: - key: node-role.kubernetes.io/master operator: DoesNotExist - key: node-role.kubernetes.io/control-plane - operator: DoesNotExist \ No newline at end of file + operator: DoesNotExist + +# only apply to "deployKind: job" +# by default NOT deploying on masters (yes|no) +deployOnMasters: "no" +# by default NOT using Affinity (yes|no) +useAffinity: "no"