depend on nebari-app chart - #162
Conversation
| version: "0.0.0" | ||
| appVersion: "0.0.0" |
dcmcand
left a comment
There was a problem hiding this comment.
Nice cleanup. Deleting 119 lines of hand-transcribed NebariAppSpec in favor of the library chart is the right coupling direction, and both non-obvious upstream patterns (mergeOverwrite for dynamic service values, the thin top/component/spec wrapper) are used correctly. I rendered base and head and compared parsed documents: on default values the output is semantically identical document-for-document, zero diffs. The managed Namespace is correctly retained too.
Two blockers and two questions.
Blockers
helm lint now fails
$ helm lint . --set keycloak.url=... \
--set frontend.nebariApp.hostname=f.example.com --set backend.nebariApp.hostname=b.example.com
[ERROR] templates/nebariapp.yaml: unable to parse YAML: invalid Yaml document separator: apiVersion: reconcilers.nebari.dev/v1
Error: 1 chart(s) linted, 1 chart(s) failed
Base passes. Cause: the --- at nebariapp.yaml:21 and :35 is followed by a left-chomping {{- ... }}, which eats the newline, so the raw bytes are ---apiVersion: .... helm template and helm install are unaffected since Helm's own splitter is lenient, and CI stays green because helm.yml never lints. Dropping the - on those two actions fixes it.
Docs still document the old values key
The rename to nebariApp leaves 36 *.nebariapp.* references across README.md, docs/src/content/docs/{getting-started,helm-values,api-reference}.md, and AGENTS.md. The docs site ships from this repo, so the published quickstart fails on first run. Verified with README.md:68-69 verbatim:
$ helm template chat . --set keycloak.url=... \
--set frontend.nebariapp.hostname=chat.example.com --set backend.nebariapp.hostname=chat-api.example.com
Error: ... spec.hostname is required
Same for the chat-values.yaml block at getting-started.md:61-65. Also getting-started.md:166 quotes the error string frontend.nebariapp.hostname is required, which is now spec.hostname is required, and helm-values.md:121-123 describes a pass-through allowlist that no longer exists.
Questions
Was dropping the frontend.enabled guard intentional?
nebariapp-frontend.yaml:1 had {{- if .Values.frontend.enabled }}. nebariapp.yaml:36-46 has no guard, while frontend-deployment.yaml:1, frontend-service.yaml:1, and frontend-configmap.yaml:1 all still have theirs. Two consequences today:
# backend-only install, no frontend hostname
base: renders OK
head: Error: ... (nebari-chat/templates/nebariapp.yaml:37:4): spec.hostname is required
and with a frontend hostname set, --set frontend.enabled=false emits NebariApp/chat-nebari-chat-frontend pointing at a Service that is not in the manifest set, plus a landing-page tile for a UI that was not deployed. If this was deliberate, what is the intended backend-only story? helm-values.md:77 currently promises no NebariApp for the UI when disabled, so it needs rewording either way.
Why the un-prefixed define "nebariApp"?
0e9ab6c moved the wrapper out of _helpers.tpl and renamed it from nebari-chat.nebariApp to bare nebariApp. Helm's template namespace is shared release-wide across all subcharts and the last define for a name silently wins, so a bare name is a latent collision. Nothing collides today, and ravnar and nebari-app both prefix everything. The library README's own example names the wrapper mychart.nebariApp. Was there a reason to drop the prefix?
Nothing in CI would have caught any of the above: helm.yml on PRs runs only helm dependencies update and helm package, and package never renders templates. A helm lint or helm template step would be cheap insurance.
| repository: oci://quay.io/reiemp/charts | ||
| version: "0.1.1" |
There was a problem hiding this comment.
Dev build of nebari-dev/nebari-operator#184. Move to a released version before merge.
Rendered chart comparisonGenerated using these scripts custom-servicesravnar:
service:
port: 123
keycloak:
url: https://keycloak.example.com
backend:
nebariapp:
hostname: backend.example.com
service:
name: backend-svc
frontend:
enabled: true
service:
port: 456
nebariapp:
hostname: frontend.example.com
service:
name: frontend-svcDiff
*** /tmp/sorted1.yaml 2026-08-31 17:22:37.230507717 +0200
--- /tmp/sorted2.yaml 2026-08-31 17:22:37.252508088 +0200
***************
*** 1,7 ****
---
! # Source: nebari-chat/templates/nebariapp-namespace.yaml
apiVersion: v1
kind: Namespace
metadata:
labels:
app.kubernetes.io/component: nebariapp
--- 1,7 ----
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: v1
kind: Namespace
metadata:
labels:
app.kubernetes.io/component: nebariapp
***************
*** 27,37 ****
name: release-name-ravnar-postgres
namespace: default
stringData:
database: ravnar
host: release-name-ravnar-postgres
! password: xzlgXQ48XWaNsyoeAmFDU6Js
port: "5432"
username: huginn
type: Opaque
---
# Source: nebari-chat/templates/backend-configmap.yaml
--- 27,37 ----
name: release-name-ravnar-postgres
namespace: default
stringData:
database: ravnar
host: release-name-ravnar-postgres
! password: vIFas3KHtH8dkNWpqmhcAy8p
port: "5432"
username: huginn
type: Opaque
---
# Source: nebari-chat/templates/backend-configmap.yaml
***************
*** 446,456 ****
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
! # Source: nebari-chat/templates/nebariapp-backend.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: backend
--- 446,456 ----
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: backend
***************
*** 465,478 ****
routing:
routes:
- pathPrefix: /
pathType: PathPrefix
service:
! name: release-name-ravnar
port: 123
---
! # Source: nebari-chat/templates/nebariapp-frontend.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: frontend
--- 465,478 ----
routing:
routes:
- pathPrefix: /
pathType: PathPrefix
service:
! name: backend-svc
port: 123
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: frontend
***************
*** 508,514 ****
routing:
routes:
- pathPrefix: /
pathType: PathPrefix
service:
! name: release-name-nebari-chat-frontend
port: 456
--- 508,514 ----
routing:
routes:
- pathPrefix: /
pathType: PathPrefix
service:
! name: frontend-svc
port: 456defaultkeycloak:
url: https://keycloak.example.com
backend:
nebariapp:
hostname: backend.example.com
frontend:
enabled: true
nebariapp:
hostname: frontend.example.comDiff
*** /tmp/sorted1.yaml 2026-08-31 17:22:37.183506928 +0200
--- /tmp/sorted2.yaml 2026-08-31 17:22:37.205507297 +0200
***************
*** 1,7 ****
---
! # Source: nebari-chat/templates/nebariapp-namespace.yaml
apiVersion: v1
kind: Namespace
metadata:
labels:
app.kubernetes.io/component: nebariapp
--- 1,7 ----
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: v1
kind: Namespace
metadata:
labels:
app.kubernetes.io/component: nebariapp
***************
*** 27,37 ****
name: release-name-ravnar-postgres
namespace: default
stringData:
database: ravnar
host: release-name-ravnar-postgres
! password: U1dwF7MHadm9GhFnD4UrF6v7
port: "5432"
username: huginn
type: Opaque
---
# Source: nebari-chat/templates/backend-configmap.yaml
--- 27,37 ----
name: release-name-ravnar-postgres
namespace: default
stringData:
database: ravnar
host: release-name-ravnar-postgres
! password: zIiZcsiNRHDRRBxJGmLh15Xn
port: "5432"
username: huginn
type: Opaque
---
# Source: nebari-chat/templates/backend-configmap.yaml
***************
*** 446,456 ****
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
! # Source: nebari-chat/templates/nebariapp-backend.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: backend
--- 446,456 ----
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: backend
***************
*** 468,478 ****
pathType: PathPrefix
service:
name: release-name-ravnar
port: 80
---
! # Source: nebari-chat/templates/nebariapp-frontend.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: frontend
--- 468,478 ----
pathType: PathPrefix
service:
name: release-name-ravnar
port: 80
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: frontendno-frontendkeycloak:
url: https://keycloak.example.com
backend:
nebariapp:
hostname: backend.example.com
frontend:
enabled: falseDiff
*** /tmp/sorted1.yaml 2026-08-31 17:22:37.272508424 +0200
--- /tmp/sorted2.yaml 2026-08-31 17:22:37.288508693 +0200
***************
*** 1,7 ****
---
! # Source: nebari-chat/templates/nebariapp-namespace.yaml
apiVersion: v1
kind: Namespace
metadata:
labels:
app.kubernetes.io/component: nebariapp
--- 1,7 ----
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: v1
kind: Namespace
metadata:
labels:
app.kubernetes.io/component: nebariapp
***************
*** 27,37 ****
name: release-name-ravnar-postgres
namespace: default
stringData:
database: ravnar
host: release-name-ravnar-postgres
! password: YTnDcMoh6EjBq0m26UuUC9PU
port: "5432"
username: huginn
type: Opaque
---
# Source: nebari-chat/templates/backend-configmap.yaml
--- 27,37 ----
name: release-name-ravnar-postgres
namespace: default
stringData:
database: ravnar
host: release-name-ravnar-postgres
! password: SlQZ3XHIUtapcN9VpJvtaA1n
port: "5432"
username: huginn
type: Opaque
---
# Source: nebari-chat/templates/backend-configmap.yaml
***************
*** 308,318 ****
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
! # Source: nebari-chat/templates/nebariapp-backend.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: backend
--- 308,318 ----
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
! # Source: nebari-chat/templates/nebariapp.yaml
apiVersion: reconcilers.nebari.dev/v1
kind: NebariApp
metadata:
labels:
app.kubernetes.io/component: backend |
| service: | ||
| name: {{ $service.name }} | ||
| port: {{ $service.port }} | ||
| {{- with $service.namespace }} | ||
| namespace: {{ . }} | ||
| {{- end }} |
There was a problem hiding this comment.
This meant that the service was not user configurable before and while dynamically computed as part of the template was fixed by the chart. This can be seen in the custom services diff in this comment. With this PR the dynamic default stays, but user override is now possible.
Depend on nebari-dev/nebari-operator#150 instead of rolling our custom nebariApp CR template.