Log the version used of the two KIC runtimes

pull/7631/head
Anders F Björklund 2020-04-27 21:58:21 +02:00
parent a041f4012a
commit bf4aa78ca6
2 changed files with 5 additions and 1 deletions

View File

@ -83,8 +83,10 @@ func status() registry.State {
// Quickly returns an error code if server is not running
cmd := exec.CommandContext(ctx, oci.Docker, "version", "--format", "{{.Server.Version}}")
_, err = cmd.Output()
o, err := cmd.Output()
output := string(o)
if err == nil {
glog.Infof("docker version: %s", output)
return registry.State{Installed: true, Healthy: true}
}

View File

@ -95,6 +95,8 @@ func status() registry.State {
o, err := cmd.Output()
output := string(o)
if err == nil {
glog.Infof("podman version: %s", output)
v, err := semver.Make(output)
if err != nil {
return registry.State{Error: err, Installed: true, Healthy: false, Fix: "Cant verify minimum required version for podman . See podman website for installation guide.", Doc: "https://podman.io/getting-started/installation.html"}