Metrics-server: /version doesn't return anymore version in v0.3.7

Created on 14 Aug 2020  路  3Comments  路  Source: kubernetes-sigs/metrics-server

What happened:
In the latest docker image k8s.gcr.io/metrics-server/metrics-server:v0.3.7 it's not returned the version by the binary
so cannot identify which one is running.

# wget -qO- https://metrics-server/version
{
  "major": "",
  "minor": "",
  "gitVersion": "v0.0.0-master+$Format:%h$",
  "gitCommit": "$Format:%H$",
  "gitTreeState": "",
  "buildDate": "1970-01-01T00:00:00Z",
  "goVersion": "go1.12.12",
  "compiler": "gc",
  "platform": "linux/amd64"
}

What you expected to happen:
To return version like in previous v.0.3.6:

wget -qO- https://metrics-server/version
{
  "major": "",
  "minor": "",
  "gitVersion": "v0.3.6-1+d1f4f6fc09cd31-dirty",
  "gitCommit": "d1f4f6fc09cd3134e8ea5ba4e0bd2db4e8002ed8",
  "gitTreeState": "dirty",
  "buildDate": "2019-10-14T12:43:57Z",
  "goVersion": "go1.10.8",
  "compiler": "gc",
  "platform": "linux/amd64"
}

Anything else we need to know?:
This info is useful for testing which version of binary is running in the system.

Environment:

  • Kubernetes distribution: Kubeadm
  • Container Network Setup: Calico
  • Kubernetes version: 1.18.6


/king bug

kinbug

All 3 comments

Is there any flag available for version checking ?

Looks like this was broken during https://github.com/kubernetes-sigs/metrics-server/pull/480
Flag --version can be used for version checking, but it shares source with gitVersion from /version endpoint. This means it will also not work on 0.3.7
I will start discussion about cutting new release either 0.3.7 or 0.4.0 with a fix

Tested v0.4.0

{
  "major": "",
  "minor": "",
  "gitVersion": "v0.4.0",
  "gitCommit": "4ae05bdf59af95e6309cc426ed10f5c93816261d",
  "gitTreeState": "",
  "buildDate": "2020-11-12T23:22:42Z",
  "goVersion": "go1.14.2",
  "compiler": "gc",
  "platform": "linux/amd64"
}

Please upgrade

Was this page helpful?
0 / 5 - 0 ratings

Related issues

serathius picture serathius  路  9Comments

gkarthiks picture gkarthiks  路  9Comments

Sh4d1 picture Sh4d1  路  6Comments

shiveshabhishek picture shiveshabhishek  路  8Comments

nikhilkhanna picture nikhilkhanna  路  8Comments