dockerfile: change output when loading Dockerfile

Previously, the output said "load Dockerfile from " + filename when the
file is not named Dockerfile. With this patch, it is changed to always
show "load build definition from " + filename.

This is because `# syntax = ...` can be put in non-Dockerfiles.

Signed-off-by: Tibor Vass <tibor@docker.com>
docker-18.09
Tibor Vass 2018-10-04 20:52:13 +00:00
parent f07efb78e3
commit ef99a677c5
1 changed files with 1 additions and 4 deletions

View File

@ -96,10 +96,7 @@ func Build(ctx context.Context, c client.Client) (*client.Result, error) {
}
}
name := "load Dockerfile"
if filename != "Dockerfile" {
name += " from " + filename
}
name := "load build definition from " + filename
src := llb.Local(LocalNameDockerfile,
llb.IncludePatterns([]string{filename}),