feat: expose release version as .Release.Version for templating
Signed-off-by: Simske <mail@simske.com>
This commit is contained in:
parent
c03f86de0f
commit
17caf1d3cd
|
|
@ -52,6 +52,7 @@ releases:
|
||||||
- `Release.Labels`: The labels to be applied to the release
|
- `Release.Labels`: The labels to be applied to the release
|
||||||
- `Release.Chart`: The chart name of the release
|
- `Release.Chart`: The chart name of the release
|
||||||
- `Release.KubeContext`: The kube context to be used for the release
|
- `Release.KubeContext`: The kube context to be used for the release
|
||||||
|
- `Release.Version`: The version of the current chart
|
||||||
- `Values`: Values passed into the environment.
|
- `Values`: Values passed into the environment.
|
||||||
- `StateValues`: alias for `Values`.
|
- `StateValues`: alias for `Values`.
|
||||||
- `Environment`: The information about the environment. This is set by the
|
- `Environment`: The information about the environment. This is set by the
|
||||||
|
|
|
||||||
|
|
@ -33,6 +33,7 @@ func (st *HelmState) createReleaseTemplateData(release *ReleaseSpec, vals map[st
|
||||||
Namespace: release.Namespace,
|
Namespace: release.Namespace,
|
||||||
Labels: release.Labels,
|
Labels: release.Labels,
|
||||||
KubeContext: release.KubeContext,
|
KubeContext: release.KubeContext,
|
||||||
|
Version: release.Version,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
tmplData.StateValues = &tmplData.Values
|
tmplData.StateValues = &tmplData.Values
|
||||||
|
|
|
||||||
|
|
@ -64,6 +64,9 @@ type releaseTemplateDataRelease struct {
|
||||||
// Chart is ReleaseSpec.Chart
|
// Chart is ReleaseSpec.Chart
|
||||||
Chart string
|
Chart string
|
||||||
|
|
||||||
|
// Version is ReleaseSpec.Version
|
||||||
|
Version string
|
||||||
|
|
||||||
// KubeContext is ReleaseSpec.KubeContext
|
// KubeContext is ReleaseSpec.KubeContext
|
||||||
KubeContext string
|
KubeContext string
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue