protobuf: remove gogoproto
Removes gogo/protobuf from buildx and updates to a version of moby/buildkit where gogo is removed. This also changes how the proto files are generated. This is because newer versions of protobuf are more strict about name conflicts. If two files have the same name (even if they are relative paths) and are used in different protoc commands, they'll conflict in the registry. Since protobuf file generation doesn't work very well with `paths=source_relative`, this removes the `go:generate` expression and just relies on the dockerfile to perform the generation. Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
This commit is contained in:
+1
-1
@@ -1,3 +1,3 @@
|
||||
package moby_buildkit_v1_sourcepolicy //nolint:revive
|
||||
|
||||
//go:generate protoc -I=. --gogofaster_out=plugins=grpc:. policy.proto
|
||||
//go:generate protoc -I=. --go_out=paths=source_relative:. --go-grpc_out=paths=source_relative,require_unimplemented_servers=false:. policy.proto
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
package moby_buildkit_v1_sourcepolicy //nolint:revive
|
||||
|
||||
import (
|
||||
"github.com/gogo/protobuf/proto"
|
||||
"github.com/moby/buildkit/util/gogo/proto"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
|
||||
+499
-1430
File diff suppressed because it is too large
Load Diff
+3
-1
@@ -2,6 +2,8 @@ syntax = "proto3";
|
||||
|
||||
package moby.buildkit.v1.sourcepolicy;
|
||||
|
||||
option go_package = "github.com/moby/buildkit/sourcepolicy/pb;moby_buildkit_v1_sourcepolicy";
|
||||
|
||||
// Rule defines the action(s) to take when a source is matched
|
||||
message Rule {
|
||||
PolicyAction action = 1;
|
||||
@@ -61,4 +63,4 @@ enum MatchType {
|
||||
// REGEX treats the source identifier as a regular expression
|
||||
// With regex matching you can also use match groups to replace values in the destination identifier
|
||||
REGEX = 2;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user