Have .dockerignore support Dockerfile/.dockerignore

If .dockerignore mentions either then the client will send them to the
daemon but the daemon will erase them after the Dockerfile has been parsed
to simulate them never being sent in the first place.

Closes #8330

Signed-off-by: Doug Davis <dug@us.ibm.com>
+1

> On Oct 28, 2014, at 12:28 AM, Tianon Gravi <notifications@github.com> wrote:
> 
> In builder/evaluator.go:
> 
> > @@ -173,6 +179,39 @@ func (b *Builder) Run(context io.Reader) (string, error) {
> >  	return b.image, nil
> >  }
> >  
> > +func (b *Builder) cleanupDockerignore() {
> Why is this function explicitly only handling Dockerfile and .dockerignore instead of just reusing the same logic as the client directly? (via some refactored new function)
> 
> This would then have the benefit of making build more consistent, especially in the case of client implementations that don't yet support .dockerignore.
> 
> —
> Reply to this email directly or view it on GitHub <https://github.com/docker/docker/pull/8748/files#r19455996>.
>