Commit 026f444f authored by Thomas Thrainer's avatar Thomas Thrainer
Browse files

Include VCS version in `gnt-cluster version`



Also print the VCS version in the output of `gnt-cluster version`. This
makes the VCS version also available over RAPI, etc.
Signed-off-by: default avatarThomas Thrainer <thomasth@google.com>
Reviewed-by: default avatarHelga Velroyen <helgav@google.com>
parent f2bb6f4f
......@@ -351,6 +351,7 @@ def ShowClusterVersion(opts, args):
ToStdout("Configuration format: %s", result["config_version"])
ToStdout("OS api version: %s", result["os_api_version"])
ToStdout("Export interface: %s", result["export_version"])
ToStdout("VCS version: %s", result["vcs_version"])
return 0
......
......@@ -291,6 +291,7 @@ class LUClusterQuery(NoHooksLU):
"config_version": constants.CONFIG_VERSION,
"os_api_version": max(constants.OS_API_VERSIONS),
"export_version": constants.EXPORT_VERSION,
"vcs_version": constants.VCS_VERSION,
"architecture": runtime.GetArchInfo(),
"name": cluster.cluster_name,
"master": cluster.master_node,
......
......@@ -2549,6 +2549,8 @@ _CLUSTER_VERSION_FIELDS = {
"API version for OS template scripts"),
"export_version": ("ExportVersion", QFT_NUMBER, constants.EXPORT_VERSION,
"Import/export file format version"),
"vcs_version": ("VCSVersion", QFT_TEXT, constants.VCS_VERSION,
"VCS version"),
}
......
......@@ -96,6 +96,7 @@ handleCall cdata QueryClusterInfo =
, ("config_version", showJSON C.configVersion)
, ("os_api_version", showJSON $ maximum C.osApiVersions)
, ("export_version", showJSON C.exportVersion)
, ("vcs_version", showJSON C.vcsVersion)
, ("architecture", showJSON arch_tuple)
, ("name", showJSON $ clusterClusterName cluster)
, ("master", showJSON $ clusterMasterNode cluster)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment