Skip to content

Rebased Dockerignore#6579

Merged
tiborvass merged 5 commits intomoby:masterfrom
vieux:dockerignore
Jun 27, 2014
Merged

Rebased Dockerignore#6579
tiborvass merged 5 commits intomoby:masterfrom
vieux:dockerignore

Conversation

@vieux
Copy link
Contributor

@vieux vieux commented Jun 20, 2014

Close #4165
Fixes #2224

@unclejack
Copy link
Contributor

LGTM

@vieux
Copy link
Contributor Author

vieux commented Jun 20, 2014

ping @tianon can you please check last one time that is the best .dockerignore we can have in our repo ?

@tianon
Copy link
Member

tianon commented Jun 20, 2014

LGTM ❤️ Do you want to add me to the MAINTAINERS for that file since it dovetails nicely with the Dockerfile?

@crosbymichael
Copy link
Contributor

don't give @tianon the power

Copy link
Contributor

Choose a reason for hiding this comment

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

Why is this ignored if the error is not nil ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's not a problem for me, .dockerignore is just an helper, if we can't read it, it's ok, we ignore it. @unclejack ?

Copy link
Contributor

Choose a reason for hiding this comment

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

We would error out above because of ValidateContextDirectory right now anyway, so I don't think this changes anything. Perhaps we should warn that ValidateContextDirectory will detect the unreadable .dockerignore?

Copy link
Contributor

Choose a reason for hiding this comment

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

I would print out a warning on stderr if err != nil

@adambiggs
Copy link

Another +1 for this.

I'm developing with Vagrant, and deploying via Docker to AWS Elastic Beanstalk. Problem is, AWS needs the Dockerfile to be in the root of the Git repo being deployed. This means the .git and .vagrant directories get copied in the context, and I can't use the current workaround of putting the Docker context in a subdirectory...

Unless there's another workaround I am stuck manually deploying .zip archives to AWS until this feature drops. 😢

@vieux vieux added this to the 1.0.2 milestone Jun 26, 2014
@crosbymichael
Copy link
Contributor

@vieux

+ go test github.com/dotcloud/docker/archive
# github.com/dotcloud/docker/archive
./archive_test.go:180: undefined: TarFilter
FAIL    github.com/dotcloud/docker/archive [build failed]

Tests failed: ./archive

tmc and others added 5 commits June 26, 2014 22:49
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: Victor Vieux <vieux@docker.com> (github: vieux)
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com> (github: vieux)
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com> (github: vieux)
@vieux
Copy link
Contributor Author

vieux commented Jun 26, 2014

@crosbymichael please retry

@vieux
Copy link
Contributor Author

vieux commented Jun 26, 2014

@tmc can you add some docs ?

@crosbymichael
Copy link
Contributor

LGTM

1 similar comment
@tiborvass
Copy link
Contributor

LGTM

tiborvass added a commit that referenced this pull request Jun 27, 2014
@tiborvass tiborvass merged commit 6e3fe93 into moby:master Jun 27, 2014
@tiborvass
Copy link
Contributor

ping @SvenDowideit Sorry I merged a little too quickly. Can we do another PR for the docs?

@benjamine
Copy link

😍 anxious to see that released, thanks!

Copy link
Contributor

Choose a reason for hiding this comment

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

Change to single back-ticks. Also below.

Copy link
Contributor

Choose a reason for hiding this comment

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

I think this has been fixed in #6766

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

Labels

area/builder Build kind/enhancement Enhancements are not bugs or new features but can improve usability or performance.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow files and paths to be ignored when uploading context