1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-06 16:06:56 +00:00
kyverno/pkg/version/version.go
2019-05-29 15:24:19 -07:00

24 lines
473 B
Go

package version
// These fields are set during an official build
var (
BuildVersion = "--"
BuildHash = "--"
BuildTime = "--"
)
// VersionInfo gets json info about the agent version
type VersionInfo struct {
BuildVersion string
BuildHash string
BuildTime string
}
// GetVersion gets the current agent version
func GetVersion() *VersionInfo {
return &VersionInfo{
BuildVersion: BuildVersion,
BuildHash: BuildHash,
BuildTime: BuildTime,
}
}