chart: refuse to render without an explicit namespace
Helm falls back to the "default" namespace when --namespace is omitted, so a forgotten flag (or a Kustomize helmCharts entry without namespace) silently deployed into the wrong place. Render the namespace through one helper that fails on an empty or implicit "default" namespace, with allowDefaultNamespace as an explicit opt-in. scripts/check-chart.sh lints the chart, asserts every namespaced resource carries the passed namespace, and checks both failure and opt-in paths. CI runs it instead of the plain template call. Bump the chart to 0.2.1.
This commit is contained in:
1 parent
0cd0b9582d
commit
8e87fed93f
11 files changed
+120
-10
No files matched your search
@@ -3,7 +3,7 @@ apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: {{ include "audiomanager.fullname" . }}-data
|
||||
namespace: {{ .Release.Namespace }}
|
||||
namespace: {{ include "audiomanager.namespace" . }}
|
||||
labels:
|
||||
{{- include "audiomanager.labels" . | nindent 4 }}
|
||||
spec:
|
||||
|
||||
Reference in new issue
Block a user