2022-04-13 06:02:54 +00:00
|
|
|
local base = import "argo_base.libsonnet";
|
2022-04-04 16:24:35 +00:00
|
|
|
|
|
|
|
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 {}
|
|
|
|
)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|