Skip to content
This repository has been archived by the owner on Nov 5, 2019. It is now read-only.

Changes to dockerfile resulted in build failing on master #30

Open
1 task done
dcwalk opened this issue Oct 28, 2017 · 7 comments
Open
1 task done

Changes to dockerfile resulted in build failing on master #30

dcwalk opened this issue Oct 28, 2017 · 7 comments

Comments

@dcwalk
Copy link
Member

dcwalk commented Oct 28, 2017

  • Is this a bug report (if so, is it something you can debug and fix?
    Send a pull request!)

This was mentioned by @b5 in #29:

somehow @ibnesayeed's dockerfile improvements were merged in with this commit, and we haven't had a proper chance to review yet, which is now breaking our master build.

I'd like to put a pause on any merges to master this repo until we've all had a chance to get our heads around @patcon and @ibnesayeed 's enhancements, so we can bring this sweet sweet stuff to all the other service-oriented repos. Unfortunately, the earliest I'm going to be able to get to it is Tuesday :/

On the upside we now know what happens when we merge the new dockerfile as-is :)

@dcwalk
Copy link
Member Author

dcwalk commented Oct 28, 2017

Copying over my comment from #29--

@b5 -- the dockerfile & makefile changes were merged in via #22 and #23 . Build was failing pre this PR, but agree there should be a pause until build is fixed, made an issue #30.

@dcwalk dcwalk added the bug label Oct 28, 2017
@dcwalk dcwalk changed the title Changes to docker-file resulted in build failing on master Changes to dockerfile resulted in build failing on master Oct 28, 2017
@ibnesayeed
Copy link
Contributor

ibnesayeed commented Oct 28, 2017

Since no details (or logs) were provided about the failure, I am not sure where the build is failing. However, if the failure is in Circle CI then I think I know the reason. The new features of Dockerfile I used were landed in Docker 17.05+ while the build script of CI is using an older version of the Docker client.

VER="17.03.0-ce"

It is worth noting that the currently used version 17.03.0-ce has reached its end of life in July. Changing it to the latest stable release 17.10.0-ce should potentially fix the issue.

Also, note that when #26 will be implemented, this build process will become irrelevant because DockerHub builds images using their latest enterprise edition.

@b5
Copy link
Member

b5 commented Oct 28, 2017

ah amazing! Thanks for such an easy place to start debugging @ibnesayeed

@ibnesayeed
Copy link
Contributor

ibnesayeed commented Oct 28, 2017

I just looked at the Circle CI build logs. I can confirm that my guess was right.

Step 1/16 : ARG GOLANG_TAG=latest
Please provide a source image with `from` prior to commit
Exited with code 1

Two Dockerfile features (build args and multi-stage builds) were not available in post 17.05 versions. At that time FROM was the only valid first instruction in a Dockerfile, but now ARG can precede it.

@ibnesayeed
Copy link
Contributor

This issue would have been caught if CI was triggered when I created the PR (and made any subsequent commits to it). But, for some reason it is setup in a way that I don't see any CI progress on my PRs.

@ibnesayeed
Copy link
Contributor

It looks like Docker now puts pre-built binaries in a different location. Earlier, they were found under https://get.docker.com/, but now https://download.docker.com/ seems to be the place where various binaries are hosted for distribution. This means, the following line also needs to be updated:

curl -L -o /tmp/docker-$VER.tgz https://get.docker.com/builds/Linux/x86_64/docker-$VER.tgz

@b5 b5 added the ready label Nov 2, 2017
@ibnesayeed
Copy link
Contributor

Docker CE 17.12.0 (on stable channel) was released last month. In order to fix this issue following lines should be updated:

VER="17.03.0-ce"
curl -L -o /tmp/docker-$VER.tgz https://get.docker.com/builds/Linux/x86_64/docker-$VER.tgz

To:

              VER="17.12.0-ce"
              curl -L -o /tmp/docker-$VER.tgz https://download.docker.com/linux/static/stable/x86_64/docker-$VER.tgz

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

3 participants