Add kube version flag (#804)

* add --kube-version flag into template cmd

Signed-off-by: FeLvi-zzz <34182539+FeLvi-zzz@users.noreply.github.com>

* add test

Signed-off-by: FeLvi-zzz <34182539+FeLvi-zzz@users.noreply.github.com>

* modify flag description

Signed-off-by: FeLvi-zzz <34182539+FeLvi-zzz@users.noreply.github.com>

* use switch

Signed-off-by: FeLvi-zzz <34182539+FeLvi-zzz@users.noreply.github.com>

* add comment

Signed-off-by: FeLvi-zzz <34182539+FeLvi-zzz@users.noreply.github.com>

---------

Signed-off-by: FeLvi-zzz <34182539+FeLvi-zzz@users.noreply.github.com>
This commit is contained in:
Soh Takada
2023-04-16 07:05:23 +08:00
committed by GitHub
parent 0012e7e5a1
commit a8a0a33c33
7 changed files with 93 additions and 13 deletions
+7
View File
@@ -34,6 +34,8 @@ type TemplateOptions struct {
SkipCleanup bool
// Propagate '--post-renderer' to helmv3 template and helm install
PostRenderer string
// KubeVersion is the kube-version flag
KubeVersion string
}
// NewTemplateOptions creates a new Apply
@@ -123,3 +125,8 @@ func (t *TemplateImpl) Values() []string {
func (t *TemplateImpl) PostRenderer() string {
return t.TemplateOptions.PostRenderer
}
// KubeVersion returns the the KubeVersion.
func (t *TemplateImpl) KubeVersion() string {
return t.TemplateOptions.KubeVersion
}