This is an automated email from the ASF dual-hosted git repository.

gyfora pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/flink-kubernetes-operator.git


The following commit(s) were added to refs/heads/main by this push:
     new 332ef267 [FLINK-40155][helm] Run chart CI and e2e tests on Helm 4
332ef267 is described below

commit 332ef2673a5ccf071dc2eb608afefe6a6463aad7
Author: Purushottam Sinha <[email protected]>
AuthorDate: Wed Jul 15 20:24:19 2026 +0530

    [FLINK-40155][helm] Run chart CI and e2e tests on Helm 4
    
    Helm 4 is GA and Helm 3 reaches end-of-life in November 2026, but the
    operator's Helm CI and e2e tests ran only on Helm 3. The chart itself
    needs no changes: it is an apiVersion v2 chart that Helm 4 installs
    natively, so one chart serves both Helm lines. This adds Helm 4 to the
    CI/e2e coverage.
    
    - ci.yml: run the Helm lint/unittest job on both Helm 3 and Helm 4 via a
      matrix. Pass --verify=false to the helm-unittest plugin install on
      Helm 4 (Helm 4 rejects git-based plugin installs without provenance;
      the flag does not exist on Helm 3). Keep helm lint --strict on Helm 3
      but not on Helm 4, where it flags the dev version 1.16-SNAPSHOT (which
      mirrors the Maven X.Y-SNAPSHOT scheme) as non-SemVerV2.
    - e2e.yaml: add a helm-version input and an explicit Helm setup step so
      the install/uninstall lifecycle runs on a chosen Helm version, and add
      a Helm 4 smoke-test leg in ci.yml.
    - docs: note that the chart supports both Helm 3 and Helm 4 (helm.md,
      English and Chinese mirror).
    
    Generated-by: Claude Code (claude-opus-4-8)
---
 .github/workflows/ci.yml                | 31 +++++++++++++++++++++++++++----
 .github/workflows/e2e.yaml              | 13 +++++++++++++
 docs/content.zh/docs/operations/helm.md |  4 ++++
 docs/content/docs/operations/helm.md    |  4 ++++
 4 files changed, 48 insertions(+), 4 deletions(-)

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 69410ce4..f4b3883c 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -40,7 +40,12 @@ jobs:
   helm_lint_test:
     runs-on: ubuntu-latest
 
-    name: Helm Lint Test
+    name: Helm Lint Test (Helm ${{ matrix.helm-version }})
+
+    strategy:
+      fail-fast: false
+      matrix:
+        helm-version: [ "v3.17.3", "v4.1.1" ]
 
     steps:
       - name: Determine branch name
@@ -61,7 +66,7 @@ jobs:
 
       - name: Set up Helm
         run: |
-          HELM_VERSION=v3.17.3
+          HELM_VERSION=${{ matrix.helm-version }}
           curl -fsSLo /tmp/helm.tar.gz 
"https://get.helm.sh/helm-${HELM_VERSION}-linux-amd64.tar.gz";
           echo "$(curl -fsSL 
"https://get.helm.sh/helm-${HELM_VERSION}-linux-amd64.tar.gz.sha256sum"; | cut 
-d' ' -f1)  /tmp/helm.tar.gz" | sha256sum -c -
           mkdir -p /tmp/helm
@@ -69,7 +74,12 @@ jobs:
           sudo mv /tmp/helm/linux-amd64/helm /usr/local/bin/helm
 
       - name: Install Helm unittest plugin
-        run: helm plugin install 
https://github.com/helm-unittest/helm-unittest.git --version 0.8.1
+        run: |
+          # Helm 4 rejects git-based plugin installs without provenance; 
--verify=false
+          # opts out of that check and does not exist on Helm 3.
+          verify_flag=""
+          [[ "${{ matrix.helm-version }}" == v4* ]] && 
verify_flag="--verify=false"
+          helm plugin install 
https://github.com/helm-unittest/helm-unittest.git --version 0.8.1 $verify_flag
 
       - name: Run Helm unittest
         run: helm unittest ${{ env.HELM_CHART_DIR }}/${{ 
env.FLINK_OPERATOR_CHART }} --file "tests/**/*_test.yaml" --strict --debug
@@ -97,7 +107,12 @@ jobs:
       - name: Run Helm lint
         if: steps.list-changed.outputs.changed == 'true'
         run: |
-          helm lint ${{ env.HELM_CHART_DIR }}/${{ env.FLINK_OPERATOR_CHART }} 
--strict --debug
+          # Helm 4's lint enforces SemVerV2 on the chart version, which the dev
+          # version (mirroring the Maven X.Y-SNAPSHOT scheme) is not, so 
--strict
+          # would fail only on Helm 4. Keep --strict on Helm 3.
+          strict_flag="--strict"
+          [[ "${{ matrix.helm-version }}" == v4* ]] && strict_flag=""
+          helm lint ${{ env.HELM_CHART_DIR }}/${{ env.FLINK_OPERATOR_CHART }} 
$strict_flag --debug
 
       - name: Run chart-testing (lint)
         if: steps.list-changed.outputs.changed == 'true'
@@ -155,6 +170,14 @@ jobs:
       flink-version: "v1_20"
       http-client: ${{ matrix.http-client }}
       test: test_application_operations.sh
+  e2e_smoke_test_helm4:
+    name: Smoke test (Helm 4)
+    uses: ./.github/workflows/e2e.yaml
+    with:
+      java-version: "17"
+      flink-version: "v1_20"
+      test: test_application_operations.sh
+      helm-version: "v4.1.1"
   java_runtimes:
     name: Java runtimes smoke test
     needs: e2e_smoke_test
diff --git a/.github/workflows/e2e.yaml b/.github/workflows/e2e.yaml
index 95d30ffb..197ea985 100644
--- a/.github/workflows/e2e.yaml
+++ b/.github/workflows/e2e.yaml
@@ -24,6 +24,10 @@ on:
       test:
         required: true
         type: string
+      helm-version:
+        required: false
+        type: string
+        default: "v3.17.3"
       create-namespace:
         type: boolean
         default: false
@@ -43,6 +47,15 @@ jobs:
           java-version: ${{ inputs.java-version }}
           distribution: 'temurin'
           cache: 'maven'
+      - name: Set up Helm ${{ inputs.helm-version }}
+        run: |
+          HELM_VERSION=${{ inputs.helm-version }}
+          curl -fsSLo /tmp/helm.tar.gz 
"https://get.helm.sh/helm-${HELM_VERSION}-linux-amd64.tar.gz";
+          echo "$(curl -fsSL 
"https://get.helm.sh/helm-${HELM_VERSION}-linux-amd64.tar.gz.sha256sum"; | cut 
-d' ' -f1)  /tmp/helm.tar.gz" | sha256sum -c -
+          mkdir -p /tmp/helm
+          tar -xzf /tmp/helm.tar.gz -C /tmp/helm
+          sudo mv /tmp/helm/linux-amd64/helm /usr/local/bin/helm
+          helm version
       - name: Start minikube
         run: |
           source e2e-tests/utils.sh
diff --git a/docs/content.zh/docs/operations/helm.md 
b/docs/content.zh/docs/operations/helm.md
index 74eb2125..319f87c1 100644
--- a/docs/content.zh/docs/operations/helm.md
+++ b/docs/content.zh/docs/operations/helm.md
@@ -26,6 +26,10 @@ under the License.
 
 # Helm installation
 
+{{< hint info >}}
+The chart supports both **Helm 3 and Helm 4**. It is an `apiVersion: v2` 
chart, which the Helm 4 CLI installs natively, so a single chart works with 
either CLI. When installing the `helm-unittest` plugin under Helm 4, pass 
`--verify=false`.
+{{< /hint >}}
+
 The operator installation is managed by a helm chart. To install with the 
chart bundled in the source code run:
 
 ```
diff --git a/docs/content/docs/operations/helm.md 
b/docs/content/docs/operations/helm.md
index 07678aff..5ba1fa5a 100644
--- a/docs/content/docs/operations/helm.md
+++ b/docs/content/docs/operations/helm.md
@@ -26,6 +26,10 @@ under the License.
 
 # Helm installation
 
+{{< hint info >}}
+The chart supports both **Helm 3 and Helm 4**. It is an `apiVersion: v2` 
chart, which the Helm 4 CLI installs natively, so a single chart works with 
either CLI. When installing the `helm-unittest` plugin under Helm 4, pass 
`--verify=false`.
+{{< /hint >}}
+
 The operator installation is managed by a helm chart. To install with the 
chart bundled in the source code run:
 
 ```

Reply via email to