diff --git a/changelog/v0.40.6/deployment-overrides-docs-change.yaml b/changelog/v0.40.6/deployment-overrides-docs-change.yaml new file mode 100644 index 000000000..0399ed27a --- /dev/null +++ b/changelog/v0.40.6/deployment-overrides-docs-change.yaml @@ -0,0 +1,5 @@ +changelog: + - type: NON_USER_FACING + description: > + "Change the helm docs description for deploymentOverrides." + skipCI: "false" diff --git a/codegen/cmd_test.go b/codegen/cmd_test.go index 4ef0948e8..b14c129f9 100644 --- a/codegen/cmd_test.go +++ b/codegen/cmd_test.go @@ -599,7 +599,7 @@ var _ = Describe("Cmd", func() { painterNode := node.Content[0].Content[1] enabledMapField := painterNode.Content[0] - Expect(enabledMapField.HeadComment).To(Equal("# Arbitrary overrides for the component's [deployment\n# template](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/deployment-v1/).")) + Expect(enabledMapField.HeadComment).To(ContainSubstring("Arbitrary overrides for the component's [deployment")) }) It("generates from templates using a name override", func() { diff --git a/codegen/model/values/helm_chart_values.go b/codegen/model/values/helm_chart_values.go index d77891917..2ad4166c3 100644 --- a/codegen/model/values/helm_chart_values.go +++ b/codegen/model/values/helm_chart_values.go @@ -64,8 +64,8 @@ type UserValues struct { PodSecurityContext *v1.PodSecurityContext `json:"podSecurityContext,omitempty" desc:"Pod-level security context. For more info, see the [Kubernetes documentation](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.26/#podsecuritycontext-v1-core)." omitChildren:"true"` // Overrides which can be set by the user - DeploymentOverrides *appsv1.Deployment `json:"deploymentOverrides" desc:"Arbitrary overrides for the component's [deployment template](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/deployment-v1/)." omitChildren:"true"` - ServiceOverrides *v1.Service `json:"serviceOverrides" desc:"Arbitrary overrides for the component's [service template](https://kubernetes.io/docs/reference/kubernetes-api/service-resources/service-v1/)." omitChildren:"true"` + DeploymentOverrides *appsv1.Deployment `json:"deploymentOverrides" desc:"Arbitrary overrides for the component's [deployment spec](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/deployment-v1/), such as to set resource limits and requests. Format the overrides as YAML or JSON." omitChildren:"true"` + ServiceOverrides *v1.Service `json:"serviceOverrides" desc:"Arbitrary overrides for the component's [service spec](https://kubernetes.io/docs/reference/kubernetes-api/service-resources/service-v1/)." omitChildren:"true"` } // document values structure for a container diff --git a/codegen/test/name_override_chart/name_override_chart_reference.md b/codegen/test/name_override_chart/name_override_chart_reference.md index 2a220e598..2f72f427b 100755 --- a/codegen/test/name_override_chart/name_override_chart_reference.md +++ b/codegen/test/name_override_chart/name_override_chart_reference.md @@ -9,7 +9,7 @@ weight: 2 |------|----|-----------|-------------| |overrideName|struct|| | |overrideName|struct|Configuration for the overrideName deployment.| | -|overrideName.deploymentOverrides|struct|Arbitrary overrides for the component's [deployment template](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/deployment-v1/).| | +|overrideName.deploymentOverrides|struct|Arbitrary overrides for the component's [deployment spec](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/deployment-v1/), such as to set resource limits and requests. Format the overrides as YAML or JSON.| | |overrideName.env[]|slice|Environment variables for the container. For more info, see the [Kubernetes documentation](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.26/#envvarsource-v1-core).|null| |overrideName.extraEnvs|struct|Extra environment variables for the container| | |overrideName.floatingUserId|bool|Allow the pod to be assigned a dynamic user ID. Required for OpenShift installations.|false| @@ -25,7 +25,7 @@ weight: 2 |overrideName.resources|struct|Container resource requirements. For more info, see the [Kubernetes documentation](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.26/#resourcerequirements-v1-core).| | |overrideName.runAsUser|uint32|Static user ID to run the containers as. Unused if floatingUserId is 'true'.|10101| |overrideName.securityContext|struct|Container security context. Set to 'false' to omit the security context entirely. For more info, see the [Kubernetes documentation](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.26/#securitycontext-v1-core).| | -|overrideName.serviceOverrides|struct|Arbitrary overrides for the component's [service template](https://kubernetes.io/docs/reference/kubernetes-api/service-resources/service-v1/).| | +|overrideName.serviceOverrides|struct|Arbitrary overrides for the component's [service spec](https://kubernetes.io/docs/reference/kubernetes-api/service-resources/service-v1/).| | |overrideName.serviceType|string|Kubernetes service type. Can be either "ClusterIP", "NodePort", "LoadBalancer", or "ExternalName".| | |overrideName.sidecars|map[string, struct]|Optional configuration for the deployed containers.|{}| |overrideName.sidecars.|struct|Optional configuration for the deployed containers.| | diff --git a/codegen/test/name_override_chart/values.yaml b/codegen/test/name_override_chart/values.yaml index e00f43b41..59c708700 100644 --- a/codegen/test/name_override_chart/values.yaml +++ b/codegen/test/name_override_chart/values.yaml @@ -2,7 +2,9 @@ overrideName: # Arbitrary overrides for the component's [deployment - # template](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/deployment-v1/). + # spec](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/deployment-v1/), + # such as to set resource limits and requests. Format the overrides as YAML or + # JSON. deploymentOverrides: null # Environment variables for the container. For more info, see the [Kubernetes # documentation](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.26/#envvarsource-v1-core). @@ -27,7 +29,7 @@ overrideName: # Static user ID to run the containers as. Unused if floatingUserId is 'true'. runAsUser: 10101 # Arbitrary overrides for the component's [service - # template](https://kubernetes.io/docs/reference/kubernetes-api/service-resources/service-v1/). + # spec](https://kubernetes.io/docs/reference/kubernetes-api/service-resources/service-v1/). serviceOverrides: null # Kubernetes service type. Can be either "ClusterIP", "NodePort", "LoadBalancer", # or "ExternalName".