You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@polaris.apache.org by "andrii29 (via GitHub)" <gi...@apache.org> on 2026/04/09 11:04:04 UTC
[PR] feat(helm): add envFrom [polaris]
andrii29 opened a new pull request, #4153:
URL: https://github.com/apache/polaris/pull/4153
<!--
π Describe what changes you're proposing, especially breaking or user-facing changes.
π See https://github.com/apache/polaris/blob/main/CONTRIBUTING.md for more.
-->
This PR introduces Helm chart support for configuring container-level envFrom entries.
The change allows users to bulk import environment variables from Kubernetes Secrets and ConfigMaps.
## Checklist
- [x] π‘οΈ Don't disclose security issues! (contact security@apache.org)
- [x] π Clearly explained why the changes are needed, or linked related issues: Fixes #
- [x] π§ͺ Added/updated tests with good coverage, or manually tested (and explained how)
- [ ] π‘ Added comments for complex logic
- [ ] π§Ύ Updated `CHANGELOG.md` (if needed)
- [ ] π Updated documentation in `site/content/in-dev/unreleased` (if needed)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "adutra (via GitHub)" <gi...@apache.org>.
adutra commented on code in PR #4153:
URL: https://github.com/apache/polaris/pull/4153#discussion_r3058587368
##########
helm/polaris/values.schema.json:
##########
@@ -193,6 +193,13 @@
"type": "string"
}
},
+ "envFrom": {
+ "description": "Bulk import environment variables from Secrets or ConfigMaps. Defines sources to populate environment variables using Kubernetes `envFrom`. Each referenced Secret or ConfigMap will expose all its key-value pairs as environment variables inside the Polaris container. [EnvFrom API](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#envfromsource-v1-core)",
+ "type": "array",
+ "items": {
+ "type": "object"
Review Comment:
Please don't follow this advice, we currently do not import or inline Kubernetes API objects.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "adutra (via GitHub)" <gi...@apache.org>.
adutra commented on PR #4153:
URL: https://github.com/apache/polaris/pull/4153#issuecomment-4215091499
@andrii29 Thank you for your contribution! From a first glance I think you may have forgotten to run `make helm` in order to update the schema AND the docs. Could you do that please and commit the changes?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "andrii29 (via GitHub)" <gi...@apache.org>.
andrii29 commented on code in PR #4153:
URL: https://github.com/apache/polaris/pull/4153#discussion_r3057455648
##########
helm/polaris/templates/deployment.yaml:
##########
@@ -94,6 +94,10 @@ spec:
{{- tpl (toYaml .Values.extraEnv) . | nindent 12 -}}
{{- end -}}
{{- end }}
+ {{- if .Values.envFrom }}
+ envFrom:
+ {{- tpl (toYaml .Values.envFrom) . | nindent 12 }}
Review Comment:
Added similar to already existing extraEnv.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "Copilot (via GitHub)" <gi...@apache.org>.
Copilot commented on code in PR #4153:
URL: https://github.com/apache/polaris/pull/4153#discussion_r3057347207
##########
helm/polaris/values.yaml:
##########
@@ -658,6 +658,20 @@ extraEnv:
# name: aws-secret
# key: secret_access_key
+# @schema item: object
+# -- Bulk import environment variables from Secrets or ConfigMaps.
+# Defines sources to populate environment variables using Kubernetes `envFrom`.
+# Each referenced Secret or ConfigMap will expose all its key-value pairs
+# as environment variables inside the Polaris container.
+# [EnvFrom API](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#envfromsource-v1-core)
+# @section -- Advanced Configuration
+envFrom:
+ []
Review Comment:
The default empty array is expressed in an unusual YAML style (`envFrom:` then `[]` on the next line). Consider using the more conventional `envFrom: []` (single line) to improve readability and reduce the chance of tooling/formatters misinterpreting it.
```suggestion
envFrom: []
```
##########
helm/polaris/values.schema.json:
##########
@@ -193,6 +193,13 @@
"type": "string"
}
},
+ "envFrom": {
+ "description": "Bulk import environment variables from Secrets or ConfigMaps. Defines sources to populate environment variables using Kubernetes `envFrom`. Each referenced Secret or ConfigMap will expose all its key-value pairs as environment variables inside the Polaris container. [EnvFrom API](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#envfromsource-v1-core)",
+ "type": "array",
+ "items": {
+ "type": "object"
Review Comment:
The schema for `envFrom` items is currently unconstrained (`items: { type: object }`), so invalid keys/structures will still pass schema validation. Consider modeling the Kubernetes `EnvFromSource` shape more explicitly (e.g., allow `prefix` plus a `oneOf` for `secretRef` vs `configMapRef`, and restrict ref objects to expected properties like `name`/`optional`). This improves validation, editor autocompletion, and catches chart misconfiguration earlier.
```suggestion
"type": "object",
"additionalProperties": false,
"properties": {
"prefix": {
"type": "string"
},
"secretRef": {
"type": "object",
"additionalProperties": false,
"properties": {
"name": {
"type": "string"
},
"optional": {
"type": "boolean"
}
},
"required": [
"name"
]
},
"configMapRef": {
"type": "object",
"additionalProperties": false,
"properties": {
"name": {
"type": "string"
},
"optional": {
"type": "boolean"
}
},
"required": [
"name"
]
}
},
"oneOf": [
{
"required": [
"secretRef"
]
},
{
"required": [
"configMapRef"
]
}
]
```
##########
helm/polaris/templates/deployment.yaml:
##########
@@ -94,6 +94,10 @@ spec:
{{- tpl (toYaml .Values.extraEnv) . | nindent 12 -}}
{{- end -}}
{{- end }}
+ {{- if .Values.envFrom }}
+ envFrom:
+ {{- tpl (toYaml .Values.envFrom) . | nindent 12 }}
Review Comment:
Using `tpl` evaluates Go templates embedded in user-provided values. If `envFrom` doesnβt need templating, prefer rendering with `toYaml` directly to reduce template-injection surface area and avoid surprises when values contain `{{ ... }}` literally. If templating is intentionally supported here, consider documenting that `envFrom` values are template-evaluated (consistent with `extraEnv`).
```suggestion
{{- toYaml .Values.envFrom | nindent 12 }}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "adutra (via GitHub)" <gi...@apache.org>.
adutra commented on code in PR #4153:
URL: https://github.com/apache/polaris/pull/4153#discussion_r3058587368
##########
helm/polaris/values.schema.json:
##########
@@ -193,6 +193,13 @@
"type": "string"
}
},
+ "envFrom": {
+ "description": "Bulk import environment variables from Secrets or ConfigMaps. Defines sources to populate environment variables using Kubernetes `envFrom`. Each referenced Secret or ConfigMap will expose all its key-value pairs as environment variables inside the Polaris container. [EnvFrom API](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#envfromsource-v1-core)",
+ "type": "array",
+ "items": {
+ "type": "object"
Review Comment:
Please don't follow this advice, we currently do not import or inline Kubernetes API schemas.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "adutra (via GitHub)" <gi...@apache.org>.
adutra commented on PR #4153:
URL: https://github.com/apache/polaris/pull/4153#issuecomment-4223762888
Before I merge: do we need a changelog entry?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "dimas-b (via GitHub)" <gi...@apache.org>.
dimas-b merged PR #4153:
URL: https://github.com/apache/polaris/pull/4153
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "andrii29 (via GitHub)" <gi...@apache.org>.
andrii29 commented on code in PR #4153:
URL: https://github.com/apache/polaris/pull/4153#discussion_r3057452103
##########
helm/polaris/values.yaml:
##########
@@ -658,6 +658,20 @@ extraEnv:
# name: aws-secret
# key: secret_access_key
+# @schema item: object
+# -- Bulk import environment variables from Secrets or ConfigMaps.
+# Defines sources to populate environment variables using Kubernetes `envFrom`.
+# Each referenced Secret or ConfigMap will expose all its key-value pairs
+# as environment variables inside the Polaris container.
+# [EnvFrom API](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#envfromsource-v1-core)
+# @section -- Advanced Configuration
+envFrom:
+ []
Review Comment:
Added similar to already existing extraEnv
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "dimas-b (via GitHub)" <gi...@apache.org>.
dimas-b commented on PR #4153:
URL: https://github.com/apache/polaris/pull/4153#issuecomment-4225055045
Re: CHANGELOG - the new `envFrom` value is option and does not affect existing users, I guess. I'd say adding an entry to "Changes" might be nice as a notification to users, but I do not think it is critical.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "andrii29 (via GitHub)" <gi...@apache.org>.
andrii29 commented on PR #4153:
URL: https://github.com/apache/polaris/pull/4153#issuecomment-4225749641
added to new features, [similar](https://github.com/apache/polaris/blob/1450649aa4ef1f2f419ae294f409a1875f7a499e/CHANGELOG.md?plain=1#L50-L53) to other Helm changelog
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] feat(helm): add envFrom [polaris]
Posted by "andrii29 (via GitHub)" <gi...@apache.org>.
andrii29 commented on PR #4153:
URL: https://github.com/apache/polaris/pull/4153#issuecomment-4215280156
@adutra done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@polaris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org