Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update DOCKER_API_VERSION to latest stable (1.39) #3519

Closed
justinruggles opened this issue Jan 9, 2019 · 5 comments
Closed

Update DOCKER_API_VERSION to latest stable (1.39) #3519

justinruggles opened this issue Jan 9, 2019 · 5 comments
Labels
area/code-deps Code dependencies (guest-vm deps belong in guest-vm) co/runtime/docker Issues specific to a docker runtime help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/feature Categorizes issue or PR as related to a new feature. priority/backlog Higher priority than priority/awaiting-more-evidence.
Milestone

Comments

@justinruggles
Copy link

Is this a BUG REPORT or FEATURE REQUEST? (choose one):

FEATURE REQUEST

The latest stable version of the Docker Engine API is 1.39. It includes some nice features like the docker build --ssh option. Minikube is using latest stable Docker Engine, but it is only using Docker API 1.35.

const DockerAPIVersion = "1.35"

Please provide the following details:

Environment:

minikube version: v0.32.0
OS: MacOS 10.12.6
VM driver: virtualbox
ISO version: v0.28.1

What happened:

Even if I attempt to override DOCKER_API_VERSION with 1.39, it still only uses 1.35.

What you expected to happen:

To be able to use the latest stable API version, or at least allow setting it when starting minikube.

How to reproduce it (as minimally and precisely as possible):

2019-01-09 09:44:53 ~$ minikube start --docker-env DOCKER_API_VERSION=1.39
Starting local Kubernetes v1.12.4 cluster...
Starting VM...
Getting VM IP address...
Moving files into cluster...
Setting up certs...
Connecting to cluster...
Setting up kubeconfig...
Stopping extra container runtimes...
Machine exists, restarting cluster components...
Verifying kubelet health ...
Verifying apiserver health ....Kubectl is now configured to use the cluster.
Loading cached images from config file.


Everything looks great. Please enjoy minikube!
2019-01-09 09:46:23 ~$ eval $(minikube docker-env)
2019-01-09 09:48:33 ~$ export DOCKER_API_VERSION=1.39
2019-01-09 09:48:42 ~$ docker version
Client: Docker Engine - Community
 Version:           18.09.0
 API version:       1.35 (downgraded from 1.39)
 Go version:        go1.10.4
 Git commit:        4d60db4
 Built:             Wed Nov  7 00:47:43 2018
 OS/Arch:           darwin/amd64
 Experimental:      false

Server:
 Engine:
  Version:          17.12.1-ce
  API version:      1.35 (minimum version 1.12)
  Go version:       go1.9.4
  Git commit:       7390fc6
  Built:            Tue Feb 27 22:20:43 2018
  OS/Arch:          linux/amd64
  Experimental:     false

Output of minikube logs (if applicable):

Anything else do we need to know:

@tstromberg tstromberg added area/code-deps Code dependencies (guest-vm deps belong in guest-vm) co/runtime/docker Issues specific to a docker runtime labels Jan 19, 2019
@tstromberg
Copy link
Contributor

Thanks for the feedback! This seems easy enough to address - PR's are welcome!

@tstromberg tstromberg added kind/bug Categorizes issue or PR as related to a bug. kind/feature Categorizes issue or PR as related to a new feature. and removed kind/bug Categorizes issue or PR as related to a bug. labels Jan 19, 2019
@afbjorklund
Copy link
Collaborator

If this constant is needed at all (?), it should probably follow whatever is in minikube.iso

https://github.com/kubernetes/minikube/blob/master/deploy/iso/minikube-iso/package/docker-bin/docker-bin.mk#L7

DOCKER_BIN_VERSION = 18.06.1-ce
(not sure why it was using the ancient ISO above, as the later ones are supposed to use API 38)

https://docs.docker.com/develop/sdk/#api-version-matrix

But best would probably be to remove it altogheter, and let the docker client/server sort it out... ?

$ eval $(minikube docker-env | grep -v DOCKER_API_VERSION)
$ docker version
Client:
 Version:           18.09.1
 API version:       1.38 (downgraded from 1.39)
 Go version:        go1.10.6
 Git commit:        4c52b90
 Built:             Wed Jan  9 19:35:23 2019
 OS/Arch:           linux/amd64
 Experimental:      false

Server:
 Engine:
  Version:          18.06.1-ce
  API version:      1.38 (minimum version 1.12)
  Go version:       go1.10.3
  Git commit:       e68fc7a
  Built:            Tue Aug 21 17:28:38 2018
  OS/Arch:          linux/amd64
  Experimental:     false

It will downgrade gracefully, to whatever least common denominator of API version exists...


It might not even be used at all, if not using docker CRI ?

$ minikube docker-env
# The docker service is currently not active

So minikube probably doesn't need to get involved here ?

@afbjorklund
Copy link
Collaborator

@justinruggles : note that 1.35 is your server API version, so you need to upgrade that (ISO) as well

But that means that kubernetes needs to support it (18.09), which it should do in later versions: #3323

minikube:

  • Upgrade Kubernetes to 1.13 (DONE)
  • Upgrade Docker CE to 18.09 (TODO)

kubeadm: https://kubernetes.io/docs/setup/cri/

The hard-coded API constant should have been 38 already now, and should be 39 (or removed) later.

Workaround is to use a separate docker-machine VM for your builds, instead of the minikube VM

@tstromberg tstromberg changed the title Need to update DOCKER_API_VERSION to latest stable (1.39) Update DOCKER_API_VERSION to latest stable (1.39) Jan 24, 2019
@tstromberg tstromberg added help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. priority/backlog Higher priority than priority/awaiting-more-evidence. and removed good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. labels Jan 24, 2019
@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 29, 2019
@afbjorklund
Copy link
Collaborator

See #4180 (and actually minikube was using API 38, even though the variable said API 35)

@afbjorklund afbjorklund removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 21, 2019
@afbjorklund afbjorklund added this to the v1.1.0 milestone May 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/code-deps Code dependencies (guest-vm deps belong in guest-vm) co/runtime/docker Issues specific to a docker runtime help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/feature Categorizes issue or PR as related to a new feature. priority/backlog Higher priority than priority/awaiting-more-evidence.
Projects
None yet
Development

No branches or pull requests

5 participants