Skip to content

Dockerignore#1

Closed
wyaeld wants to merge 4 commits intotmc:dockerignorefrom
wyaeld:dockerignore
Closed

Dockerignore#1
wyaeld wants to merge 4 commits intotmc:dockerignorefrom
wyaeld:dockerignore

Conversation

@wyaeld
Copy link

@wyaeld wyaeld commented Jun 1, 2014

Added 2 new integration-cli tests for the dockerignore feature

@wyaeld
Copy link
Author

wyaeld commented Jun 1, 2014

I'm having a minor problem with the 2nd test that has stumped me.

The test fails with

--- FAIL: TestDockerignoreWithMultiplePaths (0.01 seconds)
    utils.go:123: build failed to complete: Uploading context  2.56 kB
        Uploading context 
        2014/06/01 08:58:45 Error: Can't build a directory with no Dockerfile
         exit status 1

I cannot work out why its complaining that it can't see the Dockerfile in that dir.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can try file existence just with [ -e file ]

@wyaeld
Copy link
Author

wyaeld commented Jun 1, 2014

updated, my sh skills need work.

@wyaeld
Copy link
Author

wyaeld commented Jun 1, 2014

Added another test, 2/3 are still failing though for reasons I can't figure out.

@wyaeld
Copy link
Author

wyaeld commented Jun 1, 2014

now rebased on dotcloud/docker

@wyaeld
Copy link
Author

wyaeld commented Jun 1, 2014

I managed to screw this up with the rebase, going to close and do it again cleanly

@wyaeld wyaeld closed this Jun 1, 2014
@tmc
Copy link
Owner

tmc commented Jun 1, 2014

Cool, no problem

tmc and others added 4 commits June 2, 2014 12:38
Docker-DCO-1.1-Signed-off-by: Travis Cline <travis.cline@gmail.com> (github: tmc)
Fixes moby#2224

Docker-DCO-1.1-Signed-off-by: Travis Cline <travis.cline@gmail.com> (github: tmc)
Docker-DCO-1.1-Signed-off-by: Brad Murray <wyaeld@gmail.com> (github: wyaeld)
Docker-DCO-1.1-Signed-off-by: Brad Murray <wyaeld@gmail.com> (github: wyaeld)
@wyaeld wyaeld reopened this Jun 2, 2014
@wyaeld
Copy link
Author

wyaeld commented Jun 2, 2014

This time its the correct commits, without any mistakes in the rebase.

Still 2 problems.

TestDockerignoreCanIgnoreDockerfile fails, but looking closer at the interaction of the builder, it actually builds using the tar that it receives from archive? That would mean dockerignoring the actual Dockerfile is never going to work.

TestDockerignoreWithMultiplePaths fails too, but this one I can't understand. The dockerignore doesn't mention the Dockerfile at all, but the builder still complains that it didn't get a Dockerfile in the archive.

@LK4D4
Copy link

LK4D4 commented Jun 2, 2014

@wyaeld Yeah, ignoring Dockerfile doesn't make sense, I think we should put check about it in api.
I don't see also what the problem with multiple paths, but if you have time you can put some debug messages to archive and see what's really going on. Feel free ask me for help.

@wyaeld
Copy link
Author

wyaeld commented Jun 4, 2014

Ok, so the TestDockerignoreCanIgnoreDockerfile isn't valid, and needs to be removed and the behaviour documented, plus probably a check as you say.

TestDockerignoreWithMultiplePaths still a problem. I haven't had much time yet, will have some in a couple of days, but any assistance appreciated

tmc pushed a commit that referenced this pull request Jun 12, 2014
Move environment loading to nsenter
@wyaeld wyaeld closed this Mar 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants