hack: generate vtproto files for buildx

Integrates vtproto into buildx. The generated files dockerfile has been
modified to copy the buildkit equivalent file to ensure files are laid
out in the appropriate way for imports.

An import has also been included to change the grpc codec to the version
in buildkit that supports vtproto. This will allow buildx to utilize the
speed and memory improvements from that.

Also updates the gc control options for prune.

Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
This commit is contained in:
Jonathan A. Sternberg
2024-10-08 13:35:06 -05:00
parent d353f5f6ba
commit 64c5139ab6
109 changed files with 68070 additions and 2941 deletions

View File

@ -1,3 +0,0 @@
package moby_buildkit_v1_sourcepolicy //nolint:revive
//go:generate protoc -I=. --go_out=paths=source_relative:. --go-grpc_out=paths=source_relative,require_unimplemented_servers=false:. policy.proto

View File

@ -2,7 +2,7 @@
// versions:
// protoc-gen-go v1.34.1
// protoc v3.11.4
// source: policy.proto
// source: github.com/moby/buildkit/sourcepolicy/pb/policy.proto
package moby_buildkit_v1_sourcepolicy
@ -54,11 +54,11 @@ func (x PolicyAction) String() string {
}
func (PolicyAction) Descriptor() protoreflect.EnumDescriptor {
return file_policy_proto_enumTypes[0].Descriptor()
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[0].Descriptor()
}
func (PolicyAction) Type() protoreflect.EnumType {
return &file_policy_proto_enumTypes[0]
return &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[0]
}
func (x PolicyAction) Number() protoreflect.EnumNumber {
@ -67,7 +67,7 @@ func (x PolicyAction) Number() protoreflect.EnumNumber {
// Deprecated: Use PolicyAction.Descriptor instead.
func (PolicyAction) EnumDescriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{0}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{0}
}
// AttrMatch defines the condition to match a source attribute
@ -104,11 +104,11 @@ func (x AttrMatch) String() string {
}
func (AttrMatch) Descriptor() protoreflect.EnumDescriptor {
return file_policy_proto_enumTypes[1].Descriptor()
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[1].Descriptor()
}
func (AttrMatch) Type() protoreflect.EnumType {
return &file_policy_proto_enumTypes[1]
return &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[1]
}
func (x AttrMatch) Number() protoreflect.EnumNumber {
@ -117,7 +117,7 @@ func (x AttrMatch) Number() protoreflect.EnumNumber {
// Deprecated: Use AttrMatch.Descriptor instead.
func (AttrMatch) EnumDescriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{1}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{1}
}
// Match type is used to determine how a rule source is matched
@ -160,11 +160,11 @@ func (x MatchType) String() string {
}
func (MatchType) Descriptor() protoreflect.EnumDescriptor {
return file_policy_proto_enumTypes[2].Descriptor()
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[2].Descriptor()
}
func (MatchType) Type() protoreflect.EnumType {
return &file_policy_proto_enumTypes[2]
return &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[2]
}
func (x MatchType) Number() protoreflect.EnumNumber {
@ -173,7 +173,7 @@ func (x MatchType) Number() protoreflect.EnumNumber {
// Deprecated: Use MatchType.Descriptor instead.
func (MatchType) EnumDescriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{2}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{2}
}
// Rule defines the action(s) to take when a source is matched
@ -190,7 +190,7 @@ type Rule struct {
func (x *Rule) Reset() {
*x = Rule{}
if protoimpl.UnsafeEnabled {
mi := &file_policy_proto_msgTypes[0]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -203,7 +203,7 @@ func (x *Rule) String() string {
func (*Rule) ProtoMessage() {}
func (x *Rule) ProtoReflect() protoreflect.Message {
mi := &file_policy_proto_msgTypes[0]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -216,7 +216,7 @@ func (x *Rule) ProtoReflect() protoreflect.Message {
// Deprecated: Use Rule.ProtoReflect.Descriptor instead.
func (*Rule) Descriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{0}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{0}
}
func (x *Rule) GetAction() PolicyAction {
@ -253,7 +253,7 @@ type Update struct {
func (x *Update) Reset() {
*x = Update{}
if protoimpl.UnsafeEnabled {
mi := &file_policy_proto_msgTypes[1]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -266,7 +266,7 @@ func (x *Update) String() string {
func (*Update) ProtoMessage() {}
func (x *Update) ProtoReflect() protoreflect.Message {
mi := &file_policy_proto_msgTypes[1]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -279,7 +279,7 @@ func (x *Update) ProtoReflect() protoreflect.Message {
// Deprecated: Use Update.ProtoReflect.Descriptor instead.
func (*Update) Descriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{1}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{1}
}
func (x *Update) GetIdentifier() string {
@ -311,7 +311,7 @@ type Selector struct {
func (x *Selector) Reset() {
*x = Selector{}
if protoimpl.UnsafeEnabled {
mi := &file_policy_proto_msgTypes[2]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -324,7 +324,7 @@ func (x *Selector) String() string {
func (*Selector) ProtoMessage() {}
func (x *Selector) ProtoReflect() protoreflect.Message {
mi := &file_policy_proto_msgTypes[2]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -337,7 +337,7 @@ func (x *Selector) ProtoReflect() protoreflect.Message {
// Deprecated: Use Selector.ProtoReflect.Descriptor instead.
func (*Selector) Descriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{2}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{2}
}
func (x *Selector) GetIdentifier() string {
@ -375,7 +375,7 @@ type AttrConstraint struct {
func (x *AttrConstraint) Reset() {
*x = AttrConstraint{}
if protoimpl.UnsafeEnabled {
mi := &file_policy_proto_msgTypes[3]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -388,7 +388,7 @@ func (x *AttrConstraint) String() string {
func (*AttrConstraint) ProtoMessage() {}
func (x *AttrConstraint) ProtoReflect() protoreflect.Message {
mi := &file_policy_proto_msgTypes[3]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -401,7 +401,7 @@ func (x *AttrConstraint) ProtoReflect() protoreflect.Message {
// Deprecated: Use AttrConstraint.ProtoReflect.Descriptor instead.
func (*AttrConstraint) Descriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{3}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{3}
}
func (x *AttrConstraint) GetKey() string {
@ -438,7 +438,7 @@ type Policy struct {
func (x *Policy) Reset() {
*x = Policy{}
if protoimpl.UnsafeEnabled {
mi := &file_policy_proto_msgTypes[4]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@ -451,7 +451,7 @@ func (x *Policy) String() string {
func (*Policy) ProtoMessage() {}
func (x *Policy) ProtoReflect() protoreflect.Message {
mi := &file_policy_proto_msgTypes[4]
mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@ -464,7 +464,7 @@ func (x *Policy) ProtoReflect() protoreflect.Message {
// Deprecated: Use Policy.ProtoReflect.Descriptor instead.
func (*Policy) Descriptor() ([]byte, []int) {
return file_policy_proto_rawDescGZIP(), []int{4}
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{4}
}
func (x *Policy) GetVersion() int64 {
@ -481,94 +481,97 @@ func (x *Policy) GetRules() []*Rule {
return nil
}
var File_policy_proto protoreflect.FileDescriptor
var File_github_com_moby_buildkit_sourcepolicy_pb_policy_proto protoreflect.FileDescriptor
var file_policy_proto_rawDesc = []byte{
0x0a, 0x0c, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1d,
0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31,
0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x22, 0xd1, 0x01,
0x0a, 0x04, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x43, 0x0a, 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e,
0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2b, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75,
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc = []byte{
0x0a, 0x35, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6d, 0x6f, 0x62,
0x79, 0x2f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2f, 0x73, 0x6f, 0x75, 0x72, 0x63,
0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2f, 0x70, 0x62, 0x2f, 0x70, 0x6f, 0x6c, 0x69, 0x63,
0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1d, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75,
0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65,
0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x63, 0x74,
0x69, 0x6f, 0x6e, 0x52, 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x43, 0x0a, 0x08, 0x73,
0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e,
0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31,
0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x53, 0x65,
0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72,
0x12, 0x3f, 0x0a, 0x07, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28,
0x0b, 0x32, 0x25, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69,
0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63,
0x79, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x52, 0x07, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65,
0x73, 0x22, 0xaa, 0x01, 0x0a, 0x06, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a,
0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
0x52, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x12, 0x46, 0x0a, 0x05,
0x61, 0x74, 0x74, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x6d, 0x6f,
0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73,
0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x55, 0x70, 0x64, 0x61,
0x74, 0x65, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x61,
0x74, 0x74, 0x72, 0x73, 0x1a, 0x38, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x73, 0x45, 0x6e, 0x74,
0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20,
0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xc4,
0x01, 0x0a, 0x08, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x69,
0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x12, 0x47, 0x0a, 0x0a, 0x6d,
0x61, 0x74, 0x63, 0x68, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32,
0x28, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e,
0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x22, 0xd1, 0x01, 0x0a, 0x04, 0x52, 0x75, 0x6c, 0x65, 0x12,
0x43, 0x0a, 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32,
0x2b, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e,
0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e,
0x4d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79, 0x70, 0x65, 0x52, 0x09, 0x6d, 0x61, 0x74, 0x63, 0x68,
0x54, 0x79, 0x70, 0x65, 0x12, 0x4f, 0x0a, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69,
0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6d, 0x6f, 0x62, 0x79,
0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75,
0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x43, 0x6f,
0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72,
0x61, 0x69, 0x6e, 0x74, 0x73, 0x22, 0x80, 0x01, 0x0a, 0x0e, 0x41, 0x74, 0x74, 0x72, 0x43, 0x6f,
0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18,
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61,
0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
0x12, 0x46, 0x0a, 0x09, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20,
0x01, 0x28, 0x0e, 0x32, 0x28, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64,
0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c,
0x69, 0x63, 0x79, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x52, 0x09, 0x63,
0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x5d, 0x0a, 0x06, 0x50, 0x6f, 0x6c, 0x69,
0x63, 0x79, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20,
0x01, 0x28, 0x03, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x39, 0x0a, 0x05,
0x72, 0x75, 0x6c, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x6d, 0x6f,
0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73,
0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x52, 0x75, 0x6c, 0x65,
0x52, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73, 0x2a, 0x30, 0x0a, 0x0c, 0x50, 0x6f, 0x6c, 0x69, 0x63,
0x79, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x09, 0x0a, 0x05, 0x41, 0x4c, 0x4c, 0x4f, 0x57,
0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x44, 0x45, 0x4e, 0x59, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07,
0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x54, 0x10, 0x02, 0x2a, 0x31, 0x0a, 0x09, 0x41, 0x74, 0x74,
0x72, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x12, 0x09, 0x0a, 0x05, 0x45, 0x51, 0x55, 0x41, 0x4c, 0x10,
0x00, 0x12, 0x0c, 0x0a, 0x08, 0x4e, 0x4f, 0x54, 0x45, 0x51, 0x55, 0x41, 0x4c, 0x10, 0x01, 0x12,
0x0b, 0x0a, 0x07, 0x4d, 0x41, 0x54, 0x43, 0x48, 0x45, 0x53, 0x10, 0x02, 0x2a, 0x2f, 0x0a, 0x09,
0x4d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0c, 0x0a, 0x08, 0x57, 0x49, 0x4c,
0x44, 0x43, 0x41, 0x52, 0x44, 0x10, 0x00, 0x12, 0x09, 0x0a, 0x05, 0x45, 0x58, 0x41, 0x43, 0x54,
0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x52, 0x45, 0x47, 0x45, 0x58, 0x10, 0x02, 0x42, 0x48, 0x5a,
0x46, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6d, 0x6f, 0x62, 0x79,
0x2f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2f, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65,
0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2f, 0x70, 0x62, 0x3b, 0x6d, 0x6f, 0x62, 0x79, 0x5f, 0x62,
0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x5f, 0x76, 0x31, 0x5f, 0x73, 0x6f, 0x75, 0x72, 0x63,
0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x06, 0x61, 0x63,
0x74, 0x69, 0x6f, 0x6e, 0x12, 0x43, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72,
0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75,
0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65,
0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52,
0x08, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x3f, 0x0a, 0x07, 0x75, 0x70, 0x64,
0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6d, 0x6f, 0x62,
0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f,
0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74,
0x65, 0x52, 0x07, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x22, 0xaa, 0x01, 0x0a, 0x06, 0x55,
0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66,
0x69, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74,
0x69, 0x66, 0x69, 0x65, 0x72, 0x12, 0x46, 0x0a, 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x18, 0x02,
0x20, 0x03, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c,
0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f,
0x6c, 0x69, 0x63, 0x79, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x2e, 0x41, 0x74, 0x74, 0x72,
0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x1a, 0x38, 0x0a,
0x0a, 0x41, 0x74, 0x74, 0x72, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b,
0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a,
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61,
0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xc4, 0x01, 0x0a, 0x08, 0x53, 0x65, 0x6c, 0x65,
0x63, 0x74, 0x6f, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69,
0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69,
0x66, 0x69, 0x65, 0x72, 0x12, 0x47, 0x0a, 0x0a, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x74, 0x79,
0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x28, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e,
0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72,
0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79,
0x70, 0x65, 0x52, 0x09, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79, 0x70, 0x65, 0x12, 0x4f, 0x0a,
0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03,
0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b,
0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69,
0x63, 0x79, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e,
0x74, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x22, 0x80,
0x01, 0x0a, 0x0e, 0x41, 0x74, 0x74, 0x72, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e,
0x74, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01,
0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x46, 0x0a, 0x09, 0x63, 0x6f, 0x6e,
0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x28, 0x2e, 0x6d,
0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e,
0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x41, 0x74, 0x74,
0x72, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x52, 0x09, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f,
0x6e, 0x22, 0x5d, 0x0a, 0x06, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x18, 0x0a, 0x07, 0x76,
0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x76, 0x65,
0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x39, 0x0a, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73, 0x18, 0x02,
0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c,
0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f,
0x6c, 0x69, 0x63, 0x79, 0x2e, 0x52, 0x75, 0x6c, 0x65, 0x52, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73,
0x2a, 0x30, 0x0a, 0x0c, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e,
0x12, 0x09, 0x0a, 0x05, 0x41, 0x4c, 0x4c, 0x4f, 0x57, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x44,
0x45, 0x4e, 0x59, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x54,
0x10, 0x02, 0x2a, 0x31, 0x0a, 0x09, 0x41, 0x74, 0x74, 0x72, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x12,
0x09, 0x0a, 0x05, 0x45, 0x51, 0x55, 0x41, 0x4c, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x4e, 0x4f,
0x54, 0x45, 0x51, 0x55, 0x41, 0x4c, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x4d, 0x41, 0x54, 0x43,
0x48, 0x45, 0x53, 0x10, 0x02, 0x2a, 0x2f, 0x0a, 0x09, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79,
0x70, 0x65, 0x12, 0x0c, 0x0a, 0x08, 0x57, 0x49, 0x4c, 0x44, 0x43, 0x41, 0x52, 0x44, 0x10, 0x00,
0x12, 0x09, 0x0a, 0x05, 0x45, 0x58, 0x41, 0x43, 0x54, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x52,
0x45, 0x47, 0x45, 0x58, 0x10, 0x02, 0x42, 0x48, 0x5a, 0x46, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62,
0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6d, 0x6f, 0x62, 0x79, 0x2f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b,
0x69, 0x74, 0x2f, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2f,
0x70, 0x62, 0x3b, 0x6d, 0x6f, 0x62, 0x79, 0x5f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74,
0x5f, 0x76, 0x31, 0x5f, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79,
0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
file_policy_proto_rawDescOnce sync.Once
file_policy_proto_rawDescData = file_policy_proto_rawDesc
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescOnce sync.Once
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData = file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc
)
func file_policy_proto_rawDescGZIP() []byte {
file_policy_proto_rawDescOnce.Do(func() {
file_policy_proto_rawDescData = protoimpl.X.CompressGZIP(file_policy_proto_rawDescData)
func file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP() []byte {
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescOnce.Do(func() {
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData = protoimpl.X.CompressGZIP(file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData)
})
return file_policy_proto_rawDescData
return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData
}
var file_policy_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
var file_policy_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
var file_policy_proto_goTypes = []interface{}{
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_goTypes = []interface{}{
(PolicyAction)(0), // 0: moby.buildkit.v1.sourcepolicy.PolicyAction
(AttrMatch)(0), // 1: moby.buildkit.v1.sourcepolicy.AttrMatch
(MatchType)(0), // 2: moby.buildkit.v1.sourcepolicy.MatchType
@ -579,7 +582,7 @@ var file_policy_proto_goTypes = []interface{}{
(*Policy)(nil), // 7: moby.buildkit.v1.sourcepolicy.Policy
nil, // 8: moby.buildkit.v1.sourcepolicy.Update.AttrsEntry
}
var file_policy_proto_depIdxs = []int32{
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_depIdxs = []int32{
0, // 0: moby.buildkit.v1.sourcepolicy.Rule.action:type_name -> moby.buildkit.v1.sourcepolicy.PolicyAction
5, // 1: moby.buildkit.v1.sourcepolicy.Rule.selector:type_name -> moby.buildkit.v1.sourcepolicy.Selector
4, // 2: moby.buildkit.v1.sourcepolicy.Rule.updates:type_name -> moby.buildkit.v1.sourcepolicy.Update
@ -595,13 +598,13 @@ var file_policy_proto_depIdxs = []int32{
0, // [0:8] is the sub-list for field type_name
}
func init() { file_policy_proto_init() }
func file_policy_proto_init() {
if File_policy_proto != nil {
func init() { file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_init() }
func file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_init() {
if File_github_com_moby_buildkit_sourcepolicy_pb_policy_proto != nil {
return
}
if !protoimpl.UnsafeEnabled {
file_policy_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Rule); i {
case 0:
return &v.state
@ -613,7 +616,7 @@ func file_policy_proto_init() {
return nil
}
}
file_policy_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Update); i {
case 0:
return &v.state
@ -625,7 +628,7 @@ func file_policy_proto_init() {
return nil
}
}
file_policy_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Selector); i {
case 0:
return &v.state
@ -637,7 +640,7 @@ func file_policy_proto_init() {
return nil
}
}
file_policy_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*AttrConstraint); i {
case 0:
return &v.state
@ -649,7 +652,7 @@ func file_policy_proto_init() {
return nil
}
}
file_policy_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Policy); i {
case 0:
return &v.state
@ -666,19 +669,19 @@ func file_policy_proto_init() {
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_policy_proto_rawDesc,
RawDescriptor: file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc,
NumEnums: 3,
NumMessages: 6,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_policy_proto_goTypes,
DependencyIndexes: file_policy_proto_depIdxs,
EnumInfos: file_policy_proto_enumTypes,
MessageInfos: file_policy_proto_msgTypes,
GoTypes: file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_goTypes,
DependencyIndexes: file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_depIdxs,
EnumInfos: file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes,
MessageInfos: file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes,
}.Build()
File_policy_proto = out.File
file_policy_proto_rawDesc = nil
file_policy_proto_goTypes = nil
file_policy_proto_depIdxs = nil
File_github_com_moby_buildkit_sourcepolicy_pb_policy_proto = out.File
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc = nil
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_goTypes = nil
file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_depIdxs = nil
}

File diff suppressed because it is too large Load Diff