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

always re-fetch boot2docker, it said 'Default Boot2Docker ISO is out-of-date' #4058

Closed
ronnin opened this Issue Apr 13, 2017 · 5 comments

Comments

Projects
None yet
5 participants
@ronnin

ronnin commented Apr 13, 2017

every time, I create new docker machine, it always takes the existed boot2docker.iso out-of-date, then do re-fetching.

in fact, the boot2docker is up-to-date:
location: $HOME/.docker/machine/cache/boot2docker.iso
version: v17.04.0-ce
size: 38M
sha1: 6ec63a8a659d979fee56bb16b2a31c324baae1aa

$ docker-machine create -d xhyve dev-b
Running pre-create checks...
Creating machine...
(dev-b) Default Boot2Docker ISO is out-of-date, downloading the latest release...
(dev-b) Latest release for github.com/boot2docker/boot2docker is v17.04.0-ce
(dev-b) Downloading /Users/ronnin/.docker/machine/cache/boot2docker.iso from https://github.com/boot2docker/boot2docker/releases/download/v17.04.0-ce/boot2docker.iso...

$ docker-machine version dev-a
17.04.0-ce

$ docker-machine version
docker-machine version 0.10.0, build 76ed2a6

$ uname -a
Darwin ronmac.local 16.5.0 Darwin Kernel Version 16.5.0: Fri Mar 3 16:52:33 PST 2017; root:xnu-3789.51.2~3/RELEASE_X86_64 x86_64

$ brew info docker-machine-driver-xhyve
docker-machine-driver-xhyve: stable 0.3.1 (bottled), HEAD
Docker Machine driver for xhyve
https://github.com/zchee/docker-machine-driver-xhyve

@ronnin

This comment has been minimized.

Show comment
Hide comment
@ronnin

ronnin Apr 13, 2017

because we have trouble with downloading from github-cloud.s3.amazonaws.com, it bothers

ronnin commented Apr 13, 2017

because we have trouble with downloading from github-cloud.s3.amazonaws.com, it bothers

@NoComments

This comment has been minimized.

Show comment
Hide comment
@NoComments

NoComments Apr 26, 2017

so, how to fix it?

NoComments commented Apr 26, 2017

so, how to fix it?

@oceanho

This comment has been minimized.

Show comment
Hide comment
@oceanho

oceanho May 9, 2017

docker-machine will check boot2docker version from
https://api.github.com/repos/boot2docker/boot2docker/releases/latest
when run docker-machine create.

Local boot2docker.iso(C:\Users\Administrator\.docker\machine\cache) will be used if the network is unreachable
so. i'm disconnect network and then execute docker-machine create.

oceanho commented May 9, 2017

docker-machine will check boot2docker version from
https://api.github.com/repos/boot2docker/boot2docker/releases/latest
when run docker-machine create.

Local boot2docker.iso(C:\Users\Administrator\.docker\machine\cache) will be used if the network is unreachable
so. i'm disconnect network and then execute docker-machine create.

@Steven0668

This comment has been minimized.

Show comment
Hide comment
@Steven0668

Steven0668 Aug 4, 2017

@oceanho Thx, It works for me.

Steven0668 commented Aug 4, 2017

@oceanho Thx, It works for me.

@ggrussenmeyer

This comment has been minimized.

Show comment
Hide comment
@ggrussenmeyer

ggrussenmeyer Sep 1, 2017

Contributor

This behaviour is observed because the version encoded within the ISO is not as expected by the code that extracts it, hence letting docker-machine believe that there is a version mismatch between the cached ISO and the latest available one.

As a matter of fact, there are two variations of this anomaly:

  1. one in docker-machine-xhyve-driver (cf. machine-drivers/docker-machine-driver-xhyve#197);
  2. and one in docker-machine,
    where the starting index of the version number is determined using the whole version data
    versionIndex := strings.Index(fullVersion, versionPrefix)

    but used after having trimmed the whole version data
    vers := strings.TrimSpace(fullVersion)[versionIndex+1:]

    which may lead to an inconsistent result if the whole version data starts with spaces (which is the case for v17.07.0-ce ISO).
Contributor

ggrussenmeyer commented Sep 1, 2017

This behaviour is observed because the version encoded within the ISO is not as expected by the code that extracts it, hence letting docker-machine believe that there is a version mismatch between the cached ISO and the latest available one.

As a matter of fact, there are two variations of this anomaly:

  1. one in docker-machine-xhyve-driver (cf. machine-drivers/docker-machine-driver-xhyve#197);
  2. and one in docker-machine,
    where the starting index of the version number is determined using the whole version data
    versionIndex := strings.Index(fullVersion, versionPrefix)

    but used after having trimmed the whole version data
    vers := strings.TrimSpace(fullVersion)[versionIndex+1:]

    which may lead to an inconsistent result if the whole version data starts with spaces (which is the case for v17.07.0-ce ISO).

ggrussenmeyer added a commit to solent/machine that referenced this issue Sep 2, 2017

Fixed incorrect parsing of Boot2Docker ISO version (issue #4058).
Signed-off-by: Guillaume Grussenmeyer <ggrussenmeyer@gmail.com>

shin- added a commit to shin-/machine that referenced this issue Oct 11, 2017

Fixed incorrect parsing of Boot2Docker ISO version (issue #4058).
Signed-off-by: Guillaume Grussenmeyer <ggrussenmeyer@gmail.com>

@shin- shin- closed this in #4278 Oct 11, 2017

shin- added a commit that referenced this issue Oct 11, 2017

Fixed incorrect parsing of Boot2Docker ISO version (issue #4058).
Signed-off-by: Guillaume Grussenmeyer <ggrussenmeyer@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment