feat!(networking): configurable ingress host address and group networking related config options under common networking key#6699
Open
florianzwagemaker wants to merge 7 commits into
Conversation
…rt and group `publicHosts`, `ingressHosts`, `subdomainSeparator`, `enforceHTTPS`, and `traefikVersion` under this common group for improved flexibility.
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
This PR restructures Helm chart configuration related to networking by moving URL/host/ingress-related values under a new .Values.networking object and updating templates/helpers to consume the new structure.
Changes:
- Introduces
.Values.networkingwithpublicHosts,ingressHosts,subdomainSeparator,enforceHTTPS, andtraefikVersion. - Updates multiple Helm templates/helpers to compute hosts/URLs from
.Values.networking.*and optional ingress host overrides. - Updates deployment tooling (
deploy.py) to setnetworking.publicHostsinstead of the previous top-levelpublic.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| kubernetes/loculus/values.yaml | Moves enforceHTTPS, traefikVersion, and subdomainSeparator under networking. |
| kubernetes/loculus/values.schema.json | Adds schema for networking (publicHosts/ingressHosts + related fields) and removes old top-level keys. |
| kubernetes/loculus/templates/lapis-ingress.yaml | Uses networking.ingressHosts + networking.subdomainSeparator + networking.traefikVersion + networking.enforceHTTPS. |
| kubernetes/loculus/templates/keycloak-config-map.yaml | Switches Keycloak host/redirect URIs to use networking.ingressHosts overrides. |
| kubernetes/loculus/templates/ingressroute.yaml | Uses networking.* and introduces overridable website/backend/keycloak/minio ingress hosts. |
| kubernetes/loculus/templates/ingest-config.yaml | Uses the shared loculus.backendUrl helper for server backend URL. |
| kubernetes/loculus/templates/ena-submission-config.yaml | Uses the shared loculus.backendUrl helper for server backend URL. |
| kubernetes/loculus/templates/docs-preview.yaml | Uses networking.ingressHosts.docs override for docs hostname. |
| kubernetes/loculus/templates/autoapprove-config.yaml | Uses the shared loculus.backendUrl helper for server backend URL. |
| kubernetes/loculus/templates/_urls.tpl | Updates URL helpers to read from networking.publicHosts and networking.ingressHosts. |
| kubernetes/loculus/templates/_common-metadata.tpl | Updates runtime config generation to use networking.publicHosts and networking.ingressHosts. |
| deploy.py | Updates Helm --set-json path from public to networking.publicHosts. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…ng.subdomainSeparator
…when values are not set and improve URL construction
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR modifies how networking and public-facing URLs are constructed for Loculus deployments.
New
ingressHostskey in the helm chartThis modification allows for changing of the hostnames for each service Ingress rule (for each public facing service).
Every Ingress host rule was computed from
.Values.hostand.Values.subdomainSeparatorwith a predefined (hardcoded) prefix.i.e.
backend.host.xyz,lapis.host.xyz, orauthentication.host.xyz.The default behavior should be okay for the majority of deployments, however in some environments there might be a requirement for different hostnames either due to security policies, predefined hostname standards or potentially multiple deployments.
This change makes this optionally configurable to allow for compatibility with these potential usecases by introducing a new
ingressHostskey with properties for each ingress resource, allowing ingress hostnames to be set independently of the public urls. An example can be found below.networkingkey and moving of several properties to this groupWith the introduction of the
ingressHostsproperties i figured it would be neater to group all keys together that are involved in URLs and hostnames. Including the keys that are used in the automatic construction of urls. The moved properties arepublic(here renamed topublicHosts),subdomainSeparator,enforceHTTPS, andtraefikVersion.In case the
ingressHostskeys are kept empty, the previously computed default hostnames will be used instead.The chain is as follows:
This means that the
ingressHostskeys will only be used if apublicHostskey is set for the same service.If
ingressHostsis kept empty then the url template files will fall back to the previously computed default values based onsubdomainSeparator+hostThis makes the logic mostly backwards compatible, but i figured it would be better to consider this a breaking change as the moved keys for public urls would require existing deployments to change the helm chart.
Full example of proposed structure:
networkingis just a suggestion of course, if please feel free to suggest another key name if necessary.all URL and host references in templates (such as
_urls.tpl,ingressroute.yaml,lapis-ingress.yaml, etc.) have been changed to use the new.Values.networkingstructureI figured to not move the keys
hostandlocalHostas i believe these are used too broadly throughout the chart, also outside of networking, or are used only in a development setting.Please let me know your opinions on this, happy to make adjustments or to explore a different approach if this is not in line with your roadmap :)
🚀 Preview: Add
previewlabel to enable