refactor!: Modernize NetBird helm chart#46
Conversation
There was a problem hiding this comment.
Pull request overview
This PR modernizes the NetBird Helm chart to support newer NetBird server releases and configuration patterns, addressing the chart lag called out in issue #39.
Changes:
- Bumps the chart major version and updates
appVersion(NetBird) and dashboard image tag. - Refactors management to use a
config.yaml-based configuration (with optional envsubst-based secret injection). - Introduces “standalone” toggles for signal/relay resources and updates ingress routing to target either standalone services or management.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| charts/netbird/values.yaml | Switches management to --config /etc/netbird/config.yaml, adds configYaml + envsubst settings, adds standalone toggles, updates ports and dashboard tag. |
| charts/netbird/templates/management-deployment.yaml | Adds envsubst init container + config volume handling; adds STUN UDP port; makes /etc/netbird mount read-only. |
| charts/netbird/templates/management-cm.yaml | Renames management configmap data key to config.yaml and sources from management.configYaml. |
| charts/netbird/templates/_helpers.tpl | Adds helper functions for relay/signal target service routing and adjusts selector label helpers. |
| charts/netbird/templates/signal-*.yaml | Gates signal deployment/service/serviceaccount on signal.standalone; updates ingress backend service selection. |
| charts/netbird/templates/relay-*.yaml | Gates relay deployment/service/serviceaccount on relay.standalone; updates ingress backend service selection. |
| charts/netbird/examples/aws-eks-alb-nlb/values.yaml | Adds a full example values file for AWS EKS ALB/NLB with envsubst-based secret injection. |
| charts/netbird/examples/aws-eks-alb-nlb/README.md | Adds documentation for the AWS EKS ALB/NLB example setup. |
| charts/netbird/README.md | Updates the values table entries for the new/renamed settings and image tags. |
| charts/netbird/Chart.yaml | Bumps chart version to 2.0.0 and updates appVersion to 0.67.1. |
Comments suppressed due to low confidence (1)
charts/netbird/values.yaml:176
management.serviceGrpc.namedefaults togrpc, but the management Deployment no longer exposes any container port namedgrpc(onlyhttp,metrics, andstun). As a result, enablingmanagement.useBackwardsGrpcServicewill create a Service whosetargetPortpoints to a non-existent port name and won't route traffic. Either re-introduce agrpcnamed port on the management container, or change the GRPC Service to target the correct port name (e.g.,http) and update the related defaults/docs accordingly.
serviceGrpc:
## @param management.serviceGrpc.type Service type for the management GRPC component.
##
type: ClusterIP
## @param management.serviceGrpc.port Port for the management GRPC service.
##
port: 80
## @param management.serviceGrpc.name Name for the management GRPC service port.
##
name: grpc
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
A few notes:
|
8ed3e0c to
0235da4
Compare
3125486 to
26527f5
Compare
vehagn
left a comment
There was a problem hiding this comment.
I like the improvements! I opened some PRs which has to be changed if/when this is merged, I'll fix them after that.
I hope that the NetBird team has time to show the Helm chart some love in the coming weeks 😄
| @@ -0,0 +1,158 @@ | |||
| management: | |||
| configYaml: |- | |||
There was a problem hiding this comment.
This YAML is so much nice than the old JSON config imho. It would be nicer if it wasn't a text-block though.
| password=${NETBIRD_STORE_DSN_PASSWORD} | ||
| encryptionKey: "${NETBIRD_DATASTORE_ENC_KEY}" | ||
| activityStore: | ||
| engine: postgres |
There was a problem hiding this comment.
Slightly unrelated: Could we add a PostgreSQL subchart to spin up a separate instance?
There was a problem hiding this comment.
We could - but considering that this chart doesn't get looked at often, I would rather leave it up to Helm users to deploy separately.
|
Any update on this PR? Can we do/help with something to move further with the update of the Helm charts so it doesn't fall behind so much with the app version and available new features? At the moment, this situation is also misleading for users, as the official documentation pages, screenshots will be all inaccurate compared to what the chart installs. Also, the situation might become worse as the NetBird Kubernetes Operator might become out of sync with APIs at some point. |
26527f5 to
d5518d8
Compare
|
Hi @mlsmaycon can you take a look please ? The self-hosted capabilities on Kubernetes lag behind. |
BREAKING CHANGE: Removed the legacy `configmap` value for management.json
d5518d8 to
d4cdfb2
Compare
|
Hi @mlsmaycon is it possible to move forward on this PR ? |
|
I've also asked on the slack channel here : https://app.slack.com/client/T029P50QF09/C07R8SZL82V hopefully we get an answer... |
|
I am using this Helm Chart to run the latest version of the self-hosted management platform and it's working fine: https://github.com/KitStream/helms/tree/main/charts/netbird |
Thanks for the link, will try it, hopefully we might have someone merge this soon so we can keep the upstream tidy |
Does this serve for netbird management? Or is this include its own reverse proxy like current default installation on docker compose? |
phillebaba
left a comment
There was a problem hiding this comment.
While I can understand that people want this merged as the PR has been sitting for a while. I have concerns about the use of the init container to do envsubst. We need to discuss the implications of it and alternative solutions before this can be merged.
| initContainers: | ||
| {{- if .Values.management.envsubst.enabled }} | ||
| - name: envsubst | ||
| image: nginx:stable-alpine-slim |
There was a problem hiding this comment.
I am not a big fan of using an init container to do envsubst on the configuration. This shifts a lot of risk to runtime which can cause errors that are not understood. On top of that we are using a hard coded nginx image for this.
We ned to find a better way for the use case this init container is attempting to solve.
yes it does. It includes Routes for Gateway API and classic Ingress resources. The reverse proxy is something you need to handle on the kubernetes platform layer. |

Fixes #39