Ver Fonte

Add support for specifying update strategy

Waqar Ahmed há 4 anos atrás
pai
commit
4b245b1d09

+ 11 - 0
charts/ix-chart/2009.0.1/questions.yaml

@@ -32,6 +32,17 @@
             - "Always"
             - "Never"
 
+# Update strategy
+- variable: updateStrategy
+  description: "Upgrade Policy"
+  label: "Update Strategy"
+  schema:
+    - type: string
+      default: "RollingUpdate"
+      enum:
+        - "RollingUpdate"
+        - "Recreate"
+
 # Configurable CMD / Entrypoint / Environment Variables
 - variable: containerCommand
   description: "Commands to execute inside container overriding image CMD default"

+ 1 - 0
charts/ix-chart/2009.0.1/templates/deployment.yaml

@@ -18,6 +18,7 @@ spec:
         k8s.v1.cni.cncf.io/networks: {{ join ", " .Values.ixExternalInterfacesConfigurationNames }}
         {{- end }}
     spec:
+      strategy: {{ .Values.updateStrategy }}
       containers:
         - name: {{ .Chart.Name }}
           {{- if or .Values.hostPathVolumes .Values.persistentVolumeClaims }}

+ 4 - 0
charts/ix-chart/2009.0.1/values.yaml

@@ -6,6 +6,10 @@ image:
   # Overrides the image tag whose default is the chart appVersion.
   tag: "testing"
 
+
+# Update strategy
+updateStrategy: "RollingUpdate"
+
 # Container CMD / entrypoint
 containerCommand: []
 containerArgs: []