FORMAT: use jsonnet for templating

* add jsonnet templates
* rewrite all charts to jsonnet
This commit is contained in:
Sebastian Mark 2022-04-04 18:24:35 +02:00
parent bf2aa26963
commit e2fe9bb682
19 changed files with 244 additions and 237 deletions

View file

@ -0,0 +1,30 @@
# vim:ft=jsonnet:
local base = import "argo_base.template";
base + {
repo:: error "repo must be defined",
chart:: $.name,
version:: error "version must be defined",
skipCrds:: false,
values:: "",
spec+: {
source+: {
repoURL: $.repo,
chart: $.chart,
targetRevision: $.version,
}
+ (
if std.length($.values) > 0 then
{ helm+: { values: $.values } } else {}
)
+ (
if $.skipCrds then
{ helm+: { skipCrds: true } } else {}
)
}
}