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

rexxiong pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/celeborn.git


The following commit(s) were added to refs/heads/main by this push:
     new b2c62d406 [CELEBORN-1987][HELM] Split dnsPolicy into master.dnsPolicy 
and worker.dnsPolicy
b2c62d406 is described below

commit b2c62d406eae8557e916430061f9250f8b32c1b4
Author: Yi Chen <[email protected]>
AuthorDate: Fri May 9 10:26:42 2025 +0800

    [CELEBORN-1987][HELM] Split dnsPolicy into master.dnsPolicy and 
worker.dnsPolicy
    
    ### What changes were proposed in this pull request?
    
    - Split `dnsPolicy` into `master.dnsPolicy` and `worker.dnsPolicy`
    
    ### Why are the changes needed?
    
    Unify the values naming by prefixing them with `master` or `worker`.
    
    ### Does this PR introduce _any_ user-facing change?
    
    Yes.
    
    ### How was this patch tested?
    
    Run Helm unit tests by `helm unittest charts/celeborn --file 
"tests/**/*_test.yaml" --strict --debug`.
    
    Closes #3236 from ChenYi015/helm/dns-policy.
    
    Authored-by: Yi Chen <[email protected]>
    Signed-off-by: Shuang <[email protected]>
---
 charts/celeborn/ci/values.yaml                     | 9 ++++++---
 charts/celeborn/templates/master/statefulset.yaml  | 2 +-
 charts/celeborn/templates/worker/statefulset.yaml  | 2 +-
 charts/celeborn/tests/master/statefulset_test.yaml | 5 +++--
 charts/celeborn/tests/worker/statefulset_test.yaml | 5 +++--
 charts/celeborn/values.yaml                        | 9 ++++++---
 6 files changed, 20 insertions(+), 12 deletions(-)

diff --git a/charts/celeborn/ci/values.yaml b/charts/celeborn/ci/values.yaml
index 86b43b7d4..c61c84928 100644
--- a/charts/celeborn/ci/values.yaml
+++ b/charts/celeborn/ci/values.yaml
@@ -77,9 +77,6 @@ celeborn:
   celeborn.application.heartbeat.timeout: 120s
   celeborn.worker.heartbeat.timeout: 120s
 
-# -- Specifies the DNS policy for Celeborn pods to use
-dnsPolicy: ClusterFirstWithHostNet
-
 # -- Specifies whether to use the host's network namespace
 hostNetwork: true
 
@@ -107,6 +104,9 @@ master:
       cpu: 100m
       memory: 800Mi
 
+  # -- DNS policy for Celeborn master pods.
+  dnsPolicy: ClusterFirstWithHostNet
+
 worker:
   # -- Number of Celeborn worker replicas to deploy, should less than node 
number.
   replicas: 1
@@ -133,6 +133,9 @@ worker:
       cpu: 100m
       memory: 1Gi
 
+  # -- DNS policy for Celeborn worker pods.
+  dnsPolicy: ClusterFirstWithHostNet
+
 # -- Container security context
 securityContext:
   # Specifies the user ID to run the entrypoint of the container process
diff --git a/charts/celeborn/templates/master/statefulset.yaml 
b/charts/celeborn/templates/master/statefulset.yaml
index 72899928f..1f71190d5 100644
--- a/charts/celeborn/templates/master/statefulset.yaml
+++ b/charts/celeborn/templates/master/statefulset.yaml
@@ -141,7 +141,7 @@ spec:
       {{- if or .Values.master.priorityClass.name 
.Values.master.priorityClass.create }}
       priorityClassName: {{ include "celeborn.master.priorityClass.name" . }}
       {{- end }}
-      {{- with .Values.dnsPolicy }}
+      {{- with .Values.master.dnsPolicy }}
       dnsPolicy: {{ . }}
       {{- end }}
       {{- with .Values.hostNetwork }}
diff --git a/charts/celeborn/templates/worker/statefulset.yaml 
b/charts/celeborn/templates/worker/statefulset.yaml
index baaba6d08..c915cf10f 100644
--- a/charts/celeborn/templates/worker/statefulset.yaml
+++ b/charts/celeborn/templates/worker/statefulset.yaml
@@ -144,7 +144,7 @@ spec:
       {{- if or .Values.worker.priorityClass.name 
.Values.worker.priorityClass.create }}
       priorityClassName: {{ include "celeborn.worker.priorityClass.name" . }}
       {{- end }}
-      {{- with .Values.dnsPolicy }}
+      {{- with .Values.worker.dnsPolicy }}
       dnsPolicy: {{ . }}
       {{- end }}
       {{- with .Values.hostNetwork }}
diff --git a/charts/celeborn/tests/master/statefulset_test.yaml 
b/charts/celeborn/tests/master/statefulset_test.yaml
index c918213fb..13397881e 100644
--- a/charts/celeborn/tests/master/statefulset_test.yaml
+++ b/charts/celeborn/tests/master/statefulset_test.yaml
@@ -266,9 +266,10 @@ tests:
           path: spec.template.spec.priorityClassName
           value: test-priority-class
 
-  - it: Should use the specified dns policy if `dnsPolicy` is set
+  - it: Should use the specified dns policy if `master.dnsPolicy` is set
     set:
-      dnsPolicy: ClusterFirstWithHostNet
+      master:
+        dnsPolicy: ClusterFirstWithHostNet
     asserts:
       - equal:
           path: spec.template.spec.dnsPolicy
diff --git a/charts/celeborn/tests/worker/statefulset_test.yaml 
b/charts/celeborn/tests/worker/statefulset_test.yaml
index cf7a70b66..ce8e0cf9f 100644
--- a/charts/celeborn/tests/worker/statefulset_test.yaml
+++ b/charts/celeborn/tests/worker/statefulset_test.yaml
@@ -265,9 +265,10 @@ tests:
           path: spec.template.spec.priorityClassName
           value: test-priority-class
 
-  - it: Should use the specified dns policy if `dnsPolicy` is set
+  - it: Should use the specified dns policy if `worker.dnsPolicy` is set
     set:
-      dnsPolicy: ClusterFirstWithHostNet
+      worker:
+        dnsPolicy: ClusterFirstWithHostNet
     asserts:
       - equal:
           path: spec.template.spec.dnsPolicy
diff --git a/charts/celeborn/values.yaml b/charts/celeborn/values.yaml
index d69d680b6..5b26594fb 100644
--- a/charts/celeborn/values.yaml
+++ b/charts/celeborn/values.yaml
@@ -118,9 +118,6 @@ celeborn:
   celeborn.application.heartbeat.timeout: 120s
   celeborn.worker.heartbeat.timeout: 120s
 
-# -- Specifies the DNS policy for Celeborn pods to use
-dnsPolicy: ClusterFirst
-
 # -- Specifies whether to use the host's network namespace
 hostNetwork: false
 
@@ -211,6 +208,9 @@ master:
     # -- Specifies the integer value of this priority class, default is half 
of system-cluster-critical.
     value: 1000000000
 
+  # -- DNS policy for Celeborn master pods.
+  dnsPolicy: ClusterFirst
+
 worker:
   # -- Number of Celeborn worker replicas to deploy, should less than node 
number.
   replicas: 5
@@ -291,6 +291,9 @@ worker:
     # -- Specifies the integer value of this priority class, default is 
Celeborn master value minus 1000
     value: 999999000
 
+  # -- DNS policy for Celeborn worker pods.
+  dnsPolicy: ClusterFirst
+
 podMonitor:
   # -- Specifies whether to enable creating pod monitors for Celeborn pods
   enable: true

Reply via email to