1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Merge pull request #37688 from tiborvass/features-not-flat

Fix logic when enabling buildkit
This commit is contained in:
Tibor Vass 2018-08-21 18:56:41 -07:00 committed by GitHub
commit ef50da44b3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 1 deletions

View file

@ -231,7 +231,7 @@ func (br *buildRouter) postBuild(ctx context.Context, w http.ResponseWriter, r *
}
// check if the builder feature has been enabled from daemon as well.
if buildOptions.Version == types.BuilderBuildKit && br.builderVersion != types.BuilderBuildKit {
if buildOptions.Version == types.BuilderBuildKit && br.builderVersion != "" && br.builderVersion != types.BuilderBuildKit {
return errdefs.InvalidParameter(errors.New("buildkit is not enabled on daemon"))
}

View file

@ -54,6 +54,7 @@ var flatOptions = map[string]bool{
"log-opts": true,
"runtimes": true,
"default-ulimits": true,
"features": true,
}
// skipValidateOptions contains configuration keys