diff --git a/Makefile b/Makefile index a7f56a5..acd8e4e 100644 --- a/Makefile +++ b/Makefile @@ -15,7 +15,7 @@ INTEGRATION_PACKAGE=${PROJECT_ROOT}/integration SNAPSHOT_PACKAGES=$(shell go list ./snapshot/...) # Project binaries. -COMMANDS=ctr containerd containerd-shim protoc-gen-gogoctrd dist +COMMANDS=ctr containerd containerd-shim protoc-gen-gogoctrd dist ctrd-protobuild BINARIES=$(addprefix bin/,$(COMMANDS)) # TODO(stevvooe): This will set version from git tag, but overrides major, @@ -26,7 +26,7 @@ GO_LDFLAGS=-ldflags "-X `go list`.Version=$(VERSION)" # Flags passed to `go test` TESTFLAGS ?=-parallel 8 -race -.PHONY: clean all AUTHORS fmt vet lint build binaries test integration setup generate checkprotos coverage ci check help install uninstall vendor +.PHONY: clean all AUTHORS fmt vet lint build binaries test integration setup generate protos checkprotos coverage ci check help install uninstall vendor .DEFAULT: default all: binaries @@ -45,12 +45,15 @@ setup: ## install dependencies #@go get -u github.com/kisielk/errcheck @go get -u github.com/gordonklaus/ineffassign -generate: bin/protoc-gen-gogoctrd ## generate protobuf +generate: protos @echo "🐳 $@" - @tools/gen-gen-go.sh @PATH=${ROOTDIR}/bin:${PATH} go generate -x ${PACKAGES} -checkprotos: generate ## check if protobufs needs to be generated again +protos: bin/protoc-gen-gogoctrd bin/ctrd-protobuild ## generate protobuf + @echo "🐳 $@" + @PATH=${ROOTDIR}/bin:${PATH} ctrd-protobuild ${PACKAGES} + +checkprotos: protos ## check if protobufs needs to be generated again @echo "🐳 $@" @test -z "$$(git status --short | grep ".pb.go" | tee /dev/stderr)" || \ ((git diff | cat) && \ diff --git a/api/services/execution/execution.pb.go b/api/services/execution/execution.pb.go index 035add0..be1f4c4 100644 --- a/api/services/execution/execution.pb.go +++ b/api/services/execution/execution.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. -// source: execution.proto +// source: github.com/docker/containerd/api/services/execution/execution.proto // DO NOT EDIT! /* Package execution is a generated protocol buffer package. It is generated from these files: - execution.proto + github.com/docker/containerd/api/services/execution/execution.proto It has these top-level messages: StartContainerRequest @@ -966,7 +966,7 @@ var _ExecutionService_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "execution.proto", + Metadata: "github.com/docker/containerd/api/services/execution/execution.proto", } func (m *StartContainerRequest) Marshal() (dAtA []byte, err error) { @@ -4118,60 +4118,63 @@ var ( ErrIntOverflowExecution = fmt.Errorf("proto: integer overflow") ) -func init() { proto.RegisterFile("execution.proto", fileDescriptorExecution) } +func init() { + proto.RegisterFile("github.com/docker/containerd/api/services/execution/execution.proto", fileDescriptorExecution) +} var fileDescriptorExecution = []byte{ - // 831 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x56, 0xcf, 0x4e, 0xfb, 0x46, - 0x10, 0xc6, 0xa1, 0x84, 0x32, 0x21, 0x84, 0x2e, 0xc6, 0x8d, 0x52, 0x64, 0x90, 0x4f, 0xf4, 0x4f, - 0x6c, 0x9a, 0x4a, 0x3d, 0x54, 0x08, 0x55, 0xfc, 0x11, 0xa2, 0x42, 0x15, 0x72, 0x8a, 0x28, 0x52, - 0x25, 0xe4, 0xd8, 0xdb, 0x60, 0x35, 0xf1, 0xba, 0xf6, 0x9a, 0x96, 0x5b, 0x5f, 0xa1, 0xa7, 0x3e, - 0x47, 0xdf, 0x82, 0x63, 0x8f, 0x3d, 0xa1, 0x26, 0x4f, 0xd0, 0x47, 0xa8, 0x62, 0xaf, 0xed, 0x38, - 0xdd, 0x0d, 0xe6, 0x07, 0x9c, 0xbc, 0xbb, 0xfa, 0xe6, 0xf3, 0xcc, 0xec, 0xcc, 0x37, 0x0b, 0x0d, - 0xfc, 0x2b, 0xb6, 0x23, 0xea, 0x12, 0x4f, 0xf7, 0x03, 0x42, 0x09, 0x52, 0x6c, 0xe2, 0x51, 0xcb, - 0xf5, 0x70, 0xe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, 0xcc, 0xed, 0xf2, 0x79, 0x3e, 0xcf, 0x74, 0xb9, 0xd8, 0x67, 0xbe, - 0x1c, 0xcc, 0xa3, 0x9e, 0x19, 0xaa, 0x62, 0x6a, 0xfe, 0xf4, 0x15, 0x52, 0xbb, 0xb0, 0x3a, 0xad, - 0xc8, 0xe8, 0x53, 0x11, 0x2f, 0x47, 0xe6, 0x5b, 0x9f, 0x95, 0x03, 0xb3, 0x6a, 0x21, 0xb0, 0x56, - 0x9c, 0xdc, 0xe2, 0xcc, 0x73, 0x1f, 0x04, 0x2d, 0xbd, 0x2c, 0x9c, 0xfd, 0xd0, 0x85, 0xd5, 0xe9, - 0x61, 0x27, 0x8e, 0x8d, 0x33, 0xf5, 0xc5, 0xb1, 0x71, 0xe7, 0xa7, 0x0d, 0x90, 0xab, 0x2a, 0xfa, - 0x78, 0x4e, 0x5e, 0x66, 0x7e, 0xf3, 0x49, 0x19, 0x28, 0xfb, 0xc9, 0x25, 0xd4, 0x0b, 0x62, 0x8b, - 0xc4, 0x3e, 0x72, 0x34, 0x59, 0x58, 0x02, 0x97, 0x50, 0x2f, 0xa8, 0xa9, 0x98, 0x96, 0x27, 0xba, - 0x42, 0xda, 0x01, 0xd4, 0x0b, 0xd2, 0x27, 0xa6, 0xe5, 0xa9, 0x6d, 0xab, 0x5d, 0x12, 0x9d, 0xe4, - 0xe6, 0x70, 0xeb, 0x61, 0xa4, 0x2e, 0xfc, 0x3d, 0x52, 0x17, 0xfe, 0x1d, 0xa9, 0xd2, 0x6f, 0x63, - 0x55, 0x7a, 0x18, 0xab, 0xd2, 0x5f, 0x63, 0x55, 0xfa, 0x67, 0xac, 0x4a, 0xbd, 0x6a, 0xec, 0xdb, - 0x17, 0xff, 0x05, 0x00, 0x00, 0xff, 0xff, 0xda, 0xb4, 0xeb, 0x33, 0xf9, 0x0c, 0x00, 0x00, + // 839 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88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f5, 0xc5, 0xb1, + 0x71, 0xe7, 0xa7, 0x0d, 0x90, 0xab, 0x2a, 0xfa, 0x7c, 0x46, 0x5e, 0xa6, 0x7e, 0xf3, 0x45, 0x19, + 0x53, 0xf6, 0x93, 0x0b, 0xa8, 0x17, 0xc4, 0x16, 0x89, 0x7d, 0xe4, 0x68, 0xb2, 0xb0, 0x04, 0x2e, + 0xa0, 0x5e, 0x50, 0x53, 0x31, 0x2d, 0x4f, 0x74, 0x85, 0xb4, 0x7d, 0xa8, 0x17, 0xa4, 0x4f, 0x4c, + 0xcb, 0x53, 0xdb, 0x66, 0xab, 0xa4, 0x75, 0x92, 0x9b, 0x83, 0xcd, 0xfb, 0xa1, 0x3a, 0xf7, 0xff, + 0x50, 0x9d, 0x7b, 0x3b, 0x54, 0xa5, 0xbf, 0x46, 0xaa, 0x74, 0x3f, 0x52, 0xa5, 0xff, 0x46, 0xaa, + 0xf4, 0x66, 0xa4, 0x4a, 0xdd, 0x6a, 0xec, 0xdb, 0x37, 0xef, 0x02, 0x00, 0x00, 0xff, 0xff, 0xb3, + 0xca, 0xfb, 0x2c, 0x2d, 0x0d, 0x00, 0x00, } diff --git a/api/services/execution/gen.go b/api/services/execution/gen.go deleted file mode 100644 index 081538e..0000000 --- a/api/services/execution/gen.go +++ /dev/null @@ -1,6 +0,0 @@ -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package execution - -//go:generate protoc -I.:/home/suda/gopath/src/github.com/docker/containerd/vendor:/home/suda/gopath/src/github.com/docker/containerd/vendor/github.com/gogo/protobuf:/home/suda/gopath/src/github.com/docker/containerd/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=github.com/docker/containerd/api/services/execution,Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. execution.proto diff --git a/api/services/shim/gen.go b/api/services/shim/gen.go deleted file mode 100644 index 3d42f1d..0000000 --- a/api/services/shim/gen.go +++ /dev/null @@ -1,6 +0,0 @@ -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package shim - -//go:generate protoc -I.:/home/suda/gopath/src/github.com/docker/containerd/vendor:/home/suda/gopath/src/github.com/docker/containerd/vendor/github.com/gogo/protobuf:/home/suda/gopath/src/github.com/docker/containerd/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=github.com/docker/containerd/api/services/shim,Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. shim.proto diff --git a/api/services/shim/shim.pb.go b/api/services/shim/shim.pb.go index e73e4e5..21db9bd 100644 --- a/api/services/shim/shim.pb.go +++ b/api/services/shim/shim.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. -// source: shim.proto +// source: github.com/docker/containerd/api/services/shim/shim.proto // DO NOT EDIT! /* Package shim is a generated protocol buffer package. It is generated from these files: - shim.proto + github.com/docker/containerd/api/services/shim/shim.proto It has these top-level messages: CreateRequest @@ -820,7 +820,7 @@ var _Shim_serviceDesc = grpc.ServiceDesc{ ServerStreams: true, }, }, - Metadata: "shim.proto", + Metadata: "github.com/docker/containerd/api/services/shim/shim.proto", } func (m *CreateRequest) Marshal() (dAtA []byte, err error) { @@ -3662,69 +3662,72 @@ var ( ErrIntOverflowShim = fmt.Errorf("proto: integer overflow") ) -func init() { proto.RegisterFile("shim.proto", fileDescriptorShim) } +func init() { + proto.RegisterFile("github.com/docker/containerd/api/services/shim/shim.proto", fileDescriptorShim) +} var fileDescriptorShim = []byte{ - // 975 bytes of a gzipped FileDescriptorProto + // 982 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x9c, 0x55, 0xdd, 0x8e, 0xdb, 0x44, 0x14, 0x5e, 0xc7, 0xce, 0xdf, 0x49, 0x9c, 0x0d, 0xa3, 0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, 0x58, 0x87, 0x6d, 0xfa, 0x1e, 0xdf, 0xc2, 0xda, + 0x56, 0x57, 0xf6, 0x69, 0xb1, 0xd5, 0xab, 0x6d, 0x5c, 0x18, 0xee, 0x57, 0x50, 0x51, 0xed, 0x5d, + 0x1c, 0xee, 0x4e, 0xfb, 0x17, 0x19, 0x7a, 0x76, 0xef, 0xf5, 0x65, 0x77, 0xef, 0xcf, 0xcb, 0xee, + 0xde, 0x3f, 0x97, 0x5d, 0xed, 0xa7, 0x75, 0x57, 0x7b, 0xbd, 0xee, 0x6a, 0xbf, 0xaf, 0xbb, 0xda, + 0xdf, 0xeb, 0xae, 0x36, 0xa9, 0x48, 0xf6, 0xc7, 0xff, 0x06, 0x00, 0x00, 0xff, 0xff, 0xcf, 0x48, + 0x89, 0x64, 0x6b, 0x09, 0x00, 0x00, } diff --git a/api/types/container/container.pb.go b/api/types/container/container.pb.go index 5c1bdca..e5d082b 100644 --- a/api/types/container/container.pb.go +++ b/api/types/container/container.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. -// source: container.proto +// source: github.com/docker/containerd/api/types/container/container.proto // DO NOT EDIT! /* Package container is a generated protocol buffer package. It is generated from these files: - container.proto + github.com/docker/containerd/api/types/container/container.proto It has these top-level messages: Container @@ -433,22 +433,24 @@ var ( ErrIntOverflowContainer = fmt.Errorf("proto: integer overflow") ) -func init() { proto.RegisterFile("container.proto", fileDescriptorContainer) } +func init() { + proto.RegisterFile("github.com/docker/containerd/api/types/container/container.proto", fileDescriptorContainer) +} var fileDescriptorContainer = []byte{ - // 216 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xe2, 0x4f, 0xce, 0xcf, 0x2b, - 0x49, 0xcc, 0xcc, 0x4b, 0x2d, 0xd2, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x86, 0x0b, 0xa4, - 0xe8, 0x95, 0x19, 0xea, 0x95, 0x54, 0x16, 0xa4, 0x16, 0x4b, 0x89, 0xa4, 0xe7, 0xa7, 0xe7, 0x83, - 0xe5, 0xf5, 0x41, 0x2c, 0x88, 0x52, 0x29, 0x8b, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, - 0xfc, 0x5c, 0xfd, 0x94, 0xfc, 0xe4, 0xec, 0xd4, 0x22, 0x7d, 0x84, 0x66, 0xfd, 0xc4, 0x82, 0x4c, - 0x7d, 0xb0, 0x6e, 0xfd, 0xe2, 0x92, 0xc4, 0x92, 0x54, 0x08, 0x09, 0xd1, 0xa9, 0x94, 0xcb, 0xc5, - 0xe9, 0x0c, 0x53, 0x29, 0x24, 0xc6, 0xc5, 0x94, 0x99, 0x22, 0xc1, 0xa8, 0xc0, 0xa8, 0xc1, 0xe9, - 0xc4, 0xf6, 0xe8, 0x9e, 0x3c, 0x93, 0xa7, 0x4b, 0x10, 0x53, 0x66, 0x8a, 0x90, 0x18, 0x17, 0x5b, - 0x52, 0x69, 0x5e, 0x4a, 0x4e, 0xaa, 0x04, 0x13, 0x48, 0x2e, 0x08, 0xca, 0x13, 0x32, 0xe0, 0x62, - 0x05, 0x9b, 0x25, 0xc1, 0xa2, 0xc0, 0xa8, 0xc1, 0x67, 0x24, 0xa5, 0x87, 0xc5, 0xc5, 0x7a, 0xc1, - 0x20, 0x15, 0x41, 0x10, 0x85, 0x4e, 0x32, 0x27, 0x1e, 0xca, 0x31, 0xdc, 0x78, 0x28, 0xc7, 0xf0, - 0xe1, 0xa1, 0x1c, 0x63, 0xc3, 0x23, 0x39, 0xc6, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, - 0x7c, 0xf0, 0x48, 0x8e, 0x31, 0x89, 0x0d, 0xec, 0x26, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, - 0x85, 0x4e, 0xbe, 0x56, 0x0b, 0x01, 0x00, 0x00, + // 219 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0x72, 0x48, 0xcf, 0x2c, 0xc9, + 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xc9, 0x4f, 0xce, 0x4e, 0x2d, 0xd2, 0x4f, 0xce, + 0xcf, 0x2b, 0x49, 0xcc, 0xcc, 0x4b, 0x2d, 0x4a, 0xd1, 0x4f, 0x2c, 0xc8, 0xd4, 0x2f, 0xa9, 0x2c, + 0x48, 0x2d, 0x46, 0x08, 0x22, 0x58, 0x7a, 0x05, 0x45, 0xf9, 0x25, 0xf9, 0x42, 0xc2, 0x08, 0xf5, + 0x7a, 0x65, 0x86, 0x7a, 0x60, 0xe5, 0x52, 0x22, 0xe9, 0xf9, 0xe9, 0xf9, 0x60, 0x79, 0x7d, 0x10, + 0x0b, 0xa2, 0x54, 0xca, 0x82, 0x48, 0xcb, 0x8a, 0x4b, 0x12, 0x4b, 0x52, 0x21, 0x24, 0x44, 0xa7, + 0x52, 0x2e, 0x17, 0xa7, 0x33, 0x4c, 0xa5, 0x90, 0x18, 0x17, 0x53, 0x66, 0x8a, 0x04, 0xa3, 0x02, + 0xa3, 0x06, 0xa7, 0x13, 0xdb, 0xa3, 0x7b, 0xf2, 0x4c, 0x9e, 0x2e, 0x41, 0x4c, 0x99, 0x29, 0x42, + 0x62, 0x5c, 0x6c, 0x49, 0xa5, 0x79, 0x29, 0x39, 0xa9, 0x12, 0x4c, 0x20, 0xb9, 0x20, 0x28, 0x4f, + 0xc8, 0x80, 0x8b, 0x15, 0x6c, 0x96, 0x04, 0x8b, 0x02, 0xa3, 0x06, 0x9f, 0x91, 0x94, 0x1e, 0x16, + 0x17, 0xeb, 0x05, 0x83, 0x54, 0x04, 0x41, 0x14, 0x3a, 0xc9, 0x9c, 0x78, 0x28, 0xc7, 0x70, 0xe3, + 0xa1, 0x1c, 0xc3, 0x87, 0x87, 0x72, 0x8c, 0x0d, 0x8f, 0xe4, 0x18, 0x4f, 0x3c, 0x92, 0x63, 0xbc, + 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x24, 0x36, 0xb0, 0x9b, 0x8c, 0x01, 0x01, 0x00, + 0x00, 0xff, 0xff, 0x4c, 0xd0, 0x44, 0x85, 0x3c, 0x01, 0x00, 0x00, } diff --git a/api/types/container/gen.go b/api/types/container/gen.go deleted file mode 100644 index 52ab311..0000000 --- a/api/types/container/gen.go +++ /dev/null @@ -1,6 +0,0 @@ -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package container - -//go:generate protoc -I.:/home/suda/gopath/src/github.com/docker/containerd/vendor:/home/suda/gopath/src/github.com/docker/containerd/vendor/github.com/gogo/protobuf:/home/suda/gopath/src/github.com/docker/containerd/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=github.com/docker/containerd/api/types/container,Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. container.proto diff --git a/api/types/mount/gen.go b/api/types/mount/gen.go deleted file mode 100644 index 88cf834..0000000 --- a/api/types/mount/gen.go +++ /dev/null @@ -1,6 +0,0 @@ -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package mount - -//go:generate protoc -I.:/home/suda/gopath/src/github.com/docker/containerd/vendor:/home/suda/gopath/src/github.com/docker/containerd/vendor/github.com/gogo/protobuf:/home/suda/gopath/src/github.com/docker/containerd/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=github.com/docker/containerd/api/types/mount,Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. mount.proto diff --git a/api/types/mount/mount.pb.go b/api/types/mount/mount.pb.go index 547c117..b92e097 100644 --- a/api/types/mount/mount.pb.go +++ b/api/types/mount/mount.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. -// source: mount.proto +// source: github.com/docker/containerd/api/types/mount/mount.proto // DO NOT EDIT! /* Package mount is a generated protocol buffer package. It is generated from these files: - mount.proto + github.com/docker/containerd/api/types/mount/mount.proto It has these top-level messages: Mount @@ -509,21 +509,24 @@ var ( ErrIntOverflowMount = fmt.Errorf("proto: integer overflow") ) -func init() { proto.RegisterFile("mount.proto", fileDescriptorMount) } +func init() { + proto.RegisterFile("github.com/docker/containerd/api/types/mount/mount.proto", fileDescriptorMount) +} var fileDescriptorMount = []byte{ - // 196 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xe2, 0xce, 0xcd, 0x2f, 0xcd, - 0x2b, 0xd1, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x4e, 0xce, 0xcf, 0x2b, 0x49, 0xcc, 0xcc, - 0x4b, 0x2d, 0x4a, 0xd1, 0x2b, 0x33, 0xd4, 0x2b, 0xa9, 0x2c, 0x48, 0x2d, 0x96, 0xd2, 0x4d, 0xcf, - 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xcf, 0x4f, 0xcf, 0xd7, 0x07, 0xab, - 0x4d, 0x2a, 0x4d, 0x03, 0xf3, 0xc0, 0x1c, 0x30, 0x0b, 0x62, 0x86, 0x52, 0x2a, 0x17, 0xab, 0x2f, - 0xc8, 0x48, 0x21, 0x21, 0x2e, 0x16, 0x90, 0x01, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, 0x41, 0x60, - 0xb6, 0x90, 0x18, 0x17, 0x5b, 0x71, 0x7e, 0x69, 0x51, 0x72, 0xaa, 0x04, 0x13, 0x58, 0x14, 0xca, - 0x03, 0x89, 0x97, 0x24, 0x16, 0xa5, 0xa7, 0x96, 0x48, 0x30, 0x43, 0xc4, 0x21, 0x3c, 0x21, 0x09, - 0x2e, 0xf6, 0xfc, 0x82, 0x92, 0xcc, 0xfc, 0xbc, 0x62, 0x09, 0x16, 0x05, 0x66, 0x0d, 0xce, 0x20, - 0x18, 0xd7, 0x49, 0xe6, 0xc4, 0x43, 0x39, 0x86, 0x1b, 0x0f, 0xe5, 0x18, 0x3e, 0x3c, 0x94, 0x63, - 0x6c, 0x78, 0x24, 0xc7, 0x78, 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, - 0x31, 0x26, 0xb1, 0x81, 0xdd, 0x62, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0xce, 0xd6, 0xd6, 0x24, - 0xde, 0x00, 0x00, 0x00, + // 217 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xb2, 0x48, 0xcf, 0x2c, 0xc9, + 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xc9, 0x4f, 0xce, 0x4e, 0x2d, 0xd2, 0x4f, 0xce, + 0xcf, 0x2b, 0x49, 0xcc, 0xcc, 0x4b, 0x2d, 0x4a, 0xd1, 0x4f, 0x2c, 0xc8, 0xd4, 0x2f, 0xa9, 0x2c, + 0x48, 0x2d, 0xd6, 0xcf, 0xcd, 0x2f, 0xcd, 0x2b, 0x81, 0x90, 0x7a, 0x05, 0x45, 0xf9, 0x25, 0xf9, + 0x42, 0xc2, 0x08, 0x75, 0x7a, 0x65, 0x86, 0x7a, 0x60, 0x65, 0x52, 0xba, 0x48, 0xc6, 0xa5, 0xe7, + 0xa7, 0xe7, 0xeb, 0x83, 0xd5, 0x26, 0x95, 0xa6, 0x81, 0x79, 0x60, 0x0e, 0x98, 0x05, 0x31, 0x43, + 0x29, 0x95, 0x8b, 0xd5, 0x17, 0x64, 0xa4, 0x90, 0x10, 0x17, 0x0b, 0xc8, 0x00, 0x09, 0x46, 0x05, + 0x46, 0x0d, 0xce, 0x20, 0x30, 0x5b, 0x48, 0x8c, 0x8b, 0xad, 0x38, 0xbf, 0xb4, 0x28, 0x39, 0x55, + 0x82, 0x09, 0x2c, 0x0a, 0xe5, 0x81, 0xc4, 0x4b, 0x12, 0x8b, 0xd2, 0x53, 0x4b, 0x24, 0x98, 0x21, + 0xe2, 0x10, 0x9e, 0x90, 0x04, 0x17, 0x7b, 0x7e, 0x41, 0x49, 0x66, 0x7e, 0x5e, 0xb1, 0x04, 0x8b, + 0x02, 0xb3, 0x06, 0x67, 0x10, 0x8c, 0xeb, 0x24, 0x73, 0xe2, 0xa1, 0x1c, 0xc3, 0x8d, 0x87, 0x72, + 0x0c, 0x1f, 0x1e, 0xca, 0x31, 0x36, 0x3c, 0x92, 0x63, 0x3c, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, + 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x93, 0xd8, 0xc0, 0x6e, 0x31, 0x06, 0x04, 0x00, 0x00, 0xff, + 0xff, 0x9f, 0x5a, 0xf3, 0x3d, 0x0b, 0x01, 0x00, 0x00, } diff --git a/api/types/process/gen.go b/api/types/process/gen.go deleted file mode 100644 index 879461b..0000000 --- a/api/types/process/gen.go +++ /dev/null @@ -1,6 +0,0 @@ -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package process - -//go:generate protoc -I.:/home/suda/gopath/src/github.com/docker/containerd/vendor:/home/suda/gopath/src/github.com/docker/containerd/vendor/github.com/gogo/protobuf:/home/suda/gopath/src/github.com/docker/containerd/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=github.com/docker/containerd/api/types/process,Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. process.proto diff --git a/api/types/process/process.pb.go b/api/types/process/process.pb.go index afe2eb6..f31de4b 100644 --- a/api/types/process/process.pb.go +++ b/api/types/process/process.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. -// source: process.proto +// source: github.com/docker/containerd/api/types/process/process.proto // DO NOT EDIT! /* Package process is a generated protocol buffer package. It is generated from these files: - process.proto + github.com/docker/containerd/api/types/process/process.proto It has these top-level messages: Process @@ -645,27 +645,29 @@ var ( ErrIntOverflowProcess = fmt.Errorf("proto: integer overflow") ) -func init() { proto.RegisterFile("process.proto", fileDescriptorProcess) } +func init() { + proto.RegisterFile("github.com/docker/containerd/api/types/process/process.proto", fileDescriptorProcess) +} var fileDescriptorProcess = []byte{ - // 296 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x8c, 0x90, 0xbd, 0x4e, 0xc3, 0x30, - 0x14, 0x85, 0x7b, 0xe9, 0x5f, 0x70, 0x55, 0x84, 0xcc, 0x62, 0x22, 0x64, 0x2c, 0xa6, 0x2c, 0x38, - 0x50, 0x24, 0xc4, 0xcc, 0x13, 0xa0, 0x54, 0xcc, 0x28, 0x75, 0xac, 0x62, 0x41, 0xe3, 0xc8, 0x76, - 0x5a, 0xd8, 0x78, 0xbc, 0x8e, 0x8c, 0x8c, 0x24, 0x4f, 0x00, 0x6f, 0x80, 0xec, 0x48, 0xb0, 0x74, - 0x60, 0xb1, 0xce, 0x3d, 0xfa, 0xee, 0xd1, 0xb9, 0x46, 0xd3, 0xca, 0x68, 0x21, 0xad, 0xe5, 0x95, - 0xd1, 0x4e, 0xe3, 0x23, 0xa1, 0x4b, 0x97, 0xab, 0x52, 0x9a, 0x82, 0xaf, 0x2f, 0xb9, 0x7b, 0xad, - 0xa4, 0x8d, 0xaf, 0x97, 0xca, 0x3d, 0xd6, 0x0b, 0x2e, 0xf4, 0x2a, 0x2d, 0xb4, 0x78, 0x92, 0x26, - 0xfd, 0xc3, 0xd2, 0xbc, 0x52, 0x69, 0xe0, 0xd2, 0xda, 0x4a, 0x13, 0x9e, 0x2e, 0x2c, 0xbe, 0xf9, - 0xe7, 0x9e, 0x75, 0xb9, 0x93, 0xdd, 0xdb, 0x6d, 0x9e, 0x7d, 0x03, 0x1a, 0xdf, 0x75, 0xc5, 0xf0, - 0x21, 0xea, 0x57, 0xaa, 0x20, 0xc0, 0x20, 0x99, 0x66, 0x5e, 0x62, 0x8c, 0x06, 0xb9, 0x59, 0x5a, - 0xb2, 0xc7, 0xfa, 0xc9, 0x7e, 0x16, 0xb4, 0xa7, 0x64, 0xb9, 0x26, 0xfd, 0x60, 0x79, 0x89, 0xcf, - 0xd1, 0xc0, 0x77, 0x21, 0x03, 0x06, 0xc9, 0x64, 0x76, 0xcc, 0x77, 0x5c, 0xc6, 0xef, 0xad, 0x34, - 0x59, 0xc0, 0x7c, 0x80, 0xd8, 0x14, 0x64, 0xc8, 0xc0, 0x07, 0x88, 0x4d, 0x81, 0x63, 0x14, 0x39, - 0x69, 0x56, 0xaa, 0xcc, 0x9f, 0xc9, 0x88, 0x41, 0x12, 0x65, 0xbf, 0x33, 0xbe, 0x40, 0xc3, 0xd0, - 0x97, 0x8c, 0x19, 0x24, 0x07, 0xb3, 0x78, 0x67, 0xfa, 0xdc, 0x13, 0x59, 0x07, 0xe2, 0x53, 0x34, - 0x91, 0x2f, 0xca, 0x3d, 0xf8, 0xa9, 0xb6, 0x24, 0x0a, 0xe7, 0x20, 0x6f, 0xcd, 0x83, 0x73, 0x7b, - 0xb2, 0x6d, 0x68, 0xef, 0xa3, 0xa1, 0xbd, 0xaf, 0x86, 0xc2, 0x5b, 0x4b, 0x61, 0xdb, 0x52, 0x78, - 0x6f, 0x29, 0x7c, 0xb6, 0x14, 0x16, 0xa3, 0xf0, 0x31, 0x57, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, - 0x04, 0x02, 0x48, 0xdc, 0xb0, 0x01, 0x00, 0x00, + // 300 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 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c7, 0x93, 0x13, 0xbe, 0xe5, + 0x32, 0xfe, 0x68, 0xa5, 0x49, 0x03, 0xe6, 0x0d, 0xc4, 0x2a, 0x27, 0x7d, 0x06, 0xde, 0x40, 0xac, + 0x72, 0x1c, 0xa1, 0x91, 0x93, 0x66, 0xa1, 0x8a, 0xec, 0x95, 0x0c, 0x18, 0xc4, 0xa3, 0x74, 0x33, + 0xe3, 0x4b, 0xd4, 0x0f, 0x79, 0xc9, 0x90, 0x41, 0x7c, 0x38, 0x89, 0xb6, 0xba, 0x4f, 0x3d, 0x91, + 0xb6, 0x20, 0x3e, 0x43, 0x63, 0xf9, 0xa6, 0xdc, 0x93, 0x9f, 0x2a, 0x4b, 0x46, 0xe1, 0x1c, 0xe4, + 0xa5, 0x69, 0x50, 0xee, 0x4f, 0xd7, 0x35, 0xed, 0x7c, 0xd5, 0xb4, 0xf3, 0x53, 0x53, 0xf8, 0x68, + 0x28, 0xac, 0x1b, 0x0a, 0x9f, 0x0d, 0x85, 0xef, 0x86, 0xc2, 0x6c, 0x10, 0x3e, 0xe6, 0xfa, 0x2f, + 0x00, 0x00, 0xff, 0xff, 0xdc, 0xc2, 0xb3, 0x39, 0xdf, 0x01, 0x00, 0x00, } diff --git a/api/types/state/gen.go b/api/types/state/gen.go deleted file mode 100644 index 458f73b..0000000 --- a/api/types/state/gen.go +++ /dev/null @@ -1,6 +0,0 @@ -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package state - -//go:generate protoc -I.:/home/suda/gopath/src/github.com/docker/containerd/vendor:/home/suda/gopath/src/github.com/docker/containerd/vendor/github.com/gogo/protobuf:/home/suda/gopath/src/github.com/docker/containerd/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=github.com/docker/containerd/api/types/state,Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. state.proto diff --git a/api/types/state/state.pb.go b/api/types/state/state.pb.go index 86b271a..db371dd 100644 --- a/api/types/state/state.pb.go +++ b/api/types/state/state.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. -// source: state.proto +// source: github.com/docker/containerd/api/types/state/state.proto // DO NOT EDIT! /* Package state is a generated protocol buffer package. It is generated from these files: - state.proto + github.com/docker/containerd/api/types/state/state.proto It has these top-level messages: */ @@ -62,18 +62,22 @@ func init() { proto.RegisterEnum("containerd.v1.types.State", State_name, State_value) } -func init() { proto.RegisterFile("state.proto", fileDescriptorState) } +func init() { + proto.RegisterFile("github.com/docker/containerd/api/types/state/state.proto", fileDescriptorState) +} var fileDescriptorState = []byte{ - // 159 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xe2, 0x2e, 0x2e, 0x49, 0x2c, - 0x49, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x4e, 0xce, 0xcf, 0x2b, 0x49, 0xcc, 0xcc, - 0x4b, 0x2d, 0x4a, 0xd1, 0x2b, 0x33, 0xd4, 0x2b, 0xa9, 0x2c, 0x48, 0x2d, 0xd6, 0x72, 0xe7, 0x62, - 0x0d, 0x06, 0xa9, 0x11, 0xe2, 0xe6, 0x62, 0x0f, 0xf5, 0xf3, 0xf6, 0xf3, 0x0f, 0xf7, 0x13, 0x60, - 0x00, 0x71, 0x9c, 0x83, 0x5c, 0x1d, 0x43, 0x5c, 0x5d, 0x04, 0x18, 0x41, 0x9c, 0xa0, 0x50, 0x3f, - 0x3f, 0x4f, 0x3f, 0x77, 0x01, 0x26, 0x10, 0x27, 0x38, 0xc4, 0x3f, 0x20, 0xc0, 0xd5, 0x45, 0x80, - 0x59, 0x88, 0x8b, 0x8b, 0x2d, 0xc0, 0x31, 0x34, 0xd8, 0xd5, 0x45, 0x80, 0xc5, 0x49, 0xe6, 0xc4, - 0x43, 0x39, 0x86, 0x1b, 0x0f, 0xe5, 0x18, 0x3e, 0x3c, 0x94, 0x63, 0x6c, 0x78, 0x24, 0xc7, 0x78, - 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x26, 0xb1, 0x81, 0x9d, - 0x60, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x5a, 0xfd, 0xe3, 0xd8, 0x91, 0x00, 0x00, 0x00, + // 189 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xb2, 0x48, 0xcf, 0x2c, 0xc9, + 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xc9, 0x4f, 0xce, 0x4e, 0x2d, 0xd2, 0x4f, 0xce, + 0xcf, 0x2b, 0x49, 0xcc, 0xcc, 0x4b, 0x2d, 0x4a, 0xd1, 0x4f, 0x2c, 0xc8, 0xd4, 0x2f, 0xa9, 0x2c, + 0x48, 0x2d, 0xd6, 0x2f, 0x2e, 0x49, 0x2c, 0x49, 0x85, 0x90, 0x7a, 0x05, 0x45, 0xf9, 0x25, 0xf9, + 0x42, 0xc2, 0x08, 0x75, 0x7a, 0x65, 0x86, 0x7a, 0x60, 0x65, 0x5a, 0xee, 0x5c, 0xac, 0xc1, 0x20, + 0x35, 0x42, 0xdc, 0x5c, 0xec, 0xa1, 0x7e, 0xde, 0x7e, 0xfe, 0xe1, 0x7e, 0x02, 0x0c, 0x20, 0x8e, + 0x73, 0x90, 0xab, 0x63, 0x88, 0xab, 0x8b, 0x00, 0x23, 0x88, 0x13, 0x14, 0xea, 0xe7, 0xe7, 0xe9, + 0xe7, 0x2e, 0xc0, 0x04, 0xe2, 0x04, 0x87, 0xf8, 0x07, 0x04, 0xb8, 0xba, 0x08, 0x30, 0x0b, 0x71, + 0x71, 0xb1, 0x05, 0x38, 0x86, 0x06, 0xbb, 0xba, 0x08, 0xb0, 0x38, 0xc9, 0x9c, 0x78, 0x28, 0xc7, + 0x70, 0xe3, 0xa1, 0x1c, 0xc3, 0x87, 0x87, 0x72, 0x8c, 0x0d, 0x8f, 0xe4, 0x18, 0x4f, 0x3c, 0x92, + 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x24, 0x36, 0xb0, 0x13, 0x8c, 0x01, + 0x01, 0x00, 0x00, 0xff, 0xff, 0x41, 0x75, 0xb8, 0xe9, 0xbe, 0x00, 0x00, 0x00, } diff --git a/api/types/user/gen.go b/api/types/user/gen.go deleted file mode 100644 index 84038df..0000000 --- a/api/types/user/gen.go +++ /dev/null @@ -1,6 +0,0 @@ -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package user - -//go:generate protoc -I.:/home/suda/gopath/src/github.com/docker/containerd/vendor:/home/suda/gopath/src/github.com/docker/containerd/vendor/github.com/gogo/protobuf:/home/suda/gopath/src/github.com/docker/containerd/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=github.com/docker/containerd/api/types/user,Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. user.proto diff --git a/api/types/user/user.pb.go b/api/types/user/user.pb.go index 698c528..1b9c01f 100644 --- a/api/types/user/user.pb.go +++ b/api/types/user/user.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. -// source: user.proto +// source: github.com/docker/containerd/api/types/user/user.proto // DO NOT EDIT! /* Package user is a generated protocol buffer package. It is generated from these files: - user.proto + github.com/docker/containerd/api/types/user/user.proto It has these top-level messages: User @@ -466,19 +466,22 @@ var ( ErrIntOverflowUser = fmt.Errorf("proto: integer overflow") ) -func init() { proto.RegisterFile("user.proto", fileDescriptorUser) } +func init() { + proto.RegisterFile("github.com/docker/containerd/api/types/user/user.proto", fileDescriptorUser) +} var fileDescriptorUser = []byte{ - // 162 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xe2, 0x2a, 0x2d, 0x4e, 0x2d, - 0xd2, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x4e, 0xce, 0xcf, 0x2b, 0x49, 0xcc, 0xcc, 0x4b, - 0x2d, 0x4a, 0xd1, 0x2b, 0x33, 0xd4, 0x2b, 0xa9, 0x2c, 0x48, 0x2d, 0x56, 0x0a, 0xe6, 0x62, 0x09, - 0x2d, 0x4e, 0x2d, 0x12, 0x12, 0xe0, 0x62, 0x2e, 0xcd, 0x4c, 0x91, 0x60, 0x54, 0x60, 0xd4, 0xe0, - 0x0d, 0x02, 0x31, 0x41, 0x22, 0xe9, 0x99, 0x29, 0x12, 0x4c, 0x10, 0x91, 0xf4, 0xcc, 0x14, 0x21, - 0x75, 0x2e, 0xfe, 0xc4, 0x94, 0x94, 0xcc, 0x92, 0xcc, 0xfc, 0xbc, 0xc4, 0x9c, 0xf8, 0xf4, 0xcc, - 0x94, 0x62, 0x09, 0x66, 0x05, 0x66, 0x0d, 0xde, 0x20, 0x3e, 0x84, 0xb0, 0x7b, 0x66, 0x4a, 0xb1, - 0x93, 0xcc, 0x89, 0x87, 0x72, 0x0c, 0x37, 0x1e, 0xca, 0x31, 0x7c, 0x78, 0x28, 0xc7, 0xd8, 0xf0, - 0x48, 0x8e, 0xf1, 0xc4, 0x23, 0x39, 0xc6, 0x0b, 0x8f, 0xe4, 0x18, 0x1f, 0x3c, 0x92, 0x63, 0x4c, - 0x62, 0x03, 0x3b, 0xc7, 0x18, 0x10, 0x00, 0x00, 0xff, 0xff, 0x28, 0xf0, 0x6e, 0xd2, 0x9c, 0x00, - 0x00, 0x00, + // 192 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0x32, 0x4b, 0xcf, 0x2c, 0xc9, + 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xc9, 0x4f, 0xce, 0x4e, 0x2d, 0xd2, 0x4f, 0xce, + 0xcf, 0x2b, 0x49, 0xcc, 0xcc, 0x4b, 0x2d, 0x4a, 0xd1, 0x4f, 0x2c, 0xc8, 0xd4, 0x2f, 0xa9, 0x2c, + 0x48, 0x2d, 0xd6, 0x2f, 0x2d, 0x4e, 0x2d, 0x02, 0x13, 0x7a, 0x05, 0x45, 0xf9, 0x25, 0xf9, 0x42, + 0xc2, 0x08, 0x55, 0x7a, 0x65, 0x86, 0x7a, 0x60, 0x45, 0x4a, 0xc1, 0x5c, 0x2c, 0xa1, 0xc5, 0xa9, + 0x45, 0x42, 0x02, 0x5c, 0xcc, 0xa5, 0x99, 0x29, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0xbc, 0x41, 0x20, + 0x26, 0x48, 0x24, 0x3d, 0x33, 0x45, 0x82, 0x09, 0x22, 0x92, 0x9e, 0x99, 0x22, 0xa4, 0xce, 0xc5, + 0x9f, 0x98, 0x92, 0x92, 0x59, 0x92, 0x99, 0x9f, 0x97, 0x98, 0x13, 0x9f, 0x9e, 0x99, 0x52, 0x2c, + 0xc1, 0xac, 0xc0, 0xac, 0xc1, 0x1b, 0xc4, 0x87, 0x10, 0x76, 0xcf, 0x4c, 0x29, 0x76, 0x92, 0x39, + 0xf1, 0x50, 0x8e, 0xe1, 0xc6, 0x43, 0x39, 0x86, 0x0f, 0x0f, 0xe5, 0x18, 0x1b, 0x1e, 0xc9, 0x31, + 0x9e, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x49, 0x6c, 0x60, + 0xe7, 0x18, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0xee, 0x98, 0x21, 0x51, 0xc8, 0x00, 0x00, 0x00, } diff --git a/cmd/ctrd-protobuild/main.go b/cmd/ctrd-protobuild/main.go new file mode 100644 index 0000000..c01ee41 --- /dev/null +++ b/cmd/ctrd-protobuild/main.go @@ -0,0 +1,257 @@ +package main + +import ( + "bytes" + "flag" + "fmt" + "log" + "os" + "os/exec" + "path/filepath" + "strings" + "text/template" +) + +// defines several variables for parameterizing the protoc command. We can pull +// this out into a toml files in cases where we to vary this per package. +var ( + generationPlugin = "gogoctrd" + + preIncludePaths = []string{ + ".", + } + + // vendoredIncludes is used for packages that should be included as vendor + // directories. We don't differentiate between packages and projects here. + // This should just be the root of where the protos are included from. + vendoredIncludes = []string{ + "github.com/gogo/protobuf", + } + + // postIncludePaths defines untouched include paths to be added untouched + // to the protoc command. + postIncludePaths = []string{ + "/usr/local/include", // common location for protoc installation of WKTs + } + + plugins = []string{ + "grpc", + } + + // packageMap allows us to map protofile imports to specific Go packages. These + // becomes the M declarations at the end of the declaration. + packageMap = map[string]string{ + "google/protobuf/timestamp.proto": "github.com/gogo/protobuf/types", + "google/protobuf/descriptor.proto": "github.com/gogo/protobuf/protoc-gen-gogo/descriptor", + "gogoproto/gogo.proto": "github.com/gogo/protobuf/gogoproto", + } + + tmpl = template.Must(template.New("protoc").Parse(`protoc -I + {{- range $index, $include := .Includes -}} + {{if $index}}:{{end -}} + {{.}} + {{- end }} -- + {{- .Name -}}_out=plugins={{- range $index, $plugin := .Plugins -}} + {{- if $index}}+{{end}} + {{- $plugin}} + {{- end -}} + ,import_path={{.ImportPath}} + {{- range $proto, $gopkg := .PackageMap -}},M + {{- $proto}}={{$gopkg -}} + {{- end -}} + :{{- .OutputDir }} + {{- range .Files}} {{.}}{{end -}} +`)) +) + +// Protoc defines inputs to a protoc command string. +type Protoc struct { + Name string // backend name + Includes []string + Plugins []string + ImportPath string + PackageMap map[string]string + Files []string + OutputDir string +} + +func (p *Protoc) mkcmd() (string, error) { + var buf bytes.Buffer + if err := tmpl.Execute(&buf, p); err != nil { + return "", err + } + + return buf.String(), nil +} + +func main() { + flag.Parse() + + pkgInfos, err := goPkgInfo(flag.Args()...) + if err != nil { + log.Fatalln(err) + } + + gopath, err := gopathSrc() + if err != nil { + log.Fatalln(err) + } + + gopathCurrent, err := gopathCurrent() + if err != nil { + log.Fatalln(err) + } + + // For some reason, the golang protobuf generator makes the god awful + // decision to output the files relative to the gopath root. It doesn't do + // this only in the case where you give it ".". + outputDir := filepath.Join(gopathCurrent, "src") + + for _, pkg := range pkgInfos { + var includes []string + includes = append(includes, preIncludePaths...) + + vendor, err := closestVendorDir(pkg.Dir) + if err != nil { + log.Fatalln(err) + } + + // we also special case the inclusion of gogoproto in the vendor dir. + // We could parameterize this better if we find it to be a common case. + var vendoredIncludesResolved []string + for _, vendoredInclude := range vendoredIncludes { + vendoredIncludesResolved = append(vendoredIncludesResolved, + filepath.Join(vendor, vendoredInclude)) + } + + includes = append(includes, vendoredIncludesResolved...) + includes = append(includes, vendor, gopath) + includes = append(includes, postIncludePaths...) + + protoc := Protoc{ + Name: generationPlugin, + ImportPath: pkg.GoImportPath, + PackageMap: packageMap, + Plugins: plugins, + Files: pkg.ProtoFiles, + OutputDir: outputDir, + Includes: includes, + } + + arg, err := protoc.mkcmd() + if err != nil { + log.Fatalln(err) + } + + fmt.Println(arg) + + // pass to sh -c so we don't need to re-split here. + args := []string{"-c", arg} + cmd := exec.Command("sh", args...) + if err := cmd.Run(); err != nil { + log.Fatalln(err) + } + } +} + +type protoGoPkgInfo struct { + Dir string + GoImportPath string + ProtoFiles []string +} + +func goPkgInfo(golistpath ...string) ([]protoGoPkgInfo, error) { + args := []string{ + "list", "-e", "-f", "{{.ImportPath}} {{.Dir}}"} + args = append(args, golistpath...) + cmd := exec.Command("go", args...) + + p, err := cmd.Output() + if err != nil { + return nil, err + } + + var pkgInfos []protoGoPkgInfo + lines := bytes.Split(p, []byte("\n")) + for _, line := range lines { + if len(line) == 0 { + continue + } + parts := bytes.Fields(line) + if len(parts) != 2 { + return nil, fmt.Errorf("bad output from command: %s", p) + } + + pkgInfo := protoGoPkgInfo{ + Dir: string(parts[1]), + GoImportPath: string(parts[0]), + } + + protoFiles, err := filepath.Glob(filepath.Join(pkgInfo.Dir, "*.proto")) + if err != nil { + return nil, err + } + if len(protoFiles) == 0 { + continue // not a proto directory, skip + } + + pkgInfo.ProtoFiles = protoFiles + pkgInfos = append(pkgInfos, pkgInfo) + } + + return pkgInfos, nil +} + +// gopathSrc modifies GOPATH elements from env to include the src directory. +func gopathSrc() (string, error) { + gopathAll := os.Getenv("GOPATH") + + if gopathAll == "" { + return "", fmt.Errorf("must be run from a gopath") + } + + var elements []string + for _, element := range strings.Split(gopathAll, ":") { // TODO(stevvooe): Make this work on windows. + elements = append(elements, filepath.Join(element, "src")) + } + + return strings.Join(elements, ":"), nil +} + +// gopathCurrent provides the top-level gopath for the current generation. +func gopathCurrent() (string, error) { + gopathAll := os.Getenv("GOPATH") + + if gopathAll == "" { + return "", fmt.Errorf("must be run from a gopath") + } + + return strings.Split(gopathAll, ":")[0], nil +} + +// closestVendorDir walks up from dir until it finds the vendor directory. +func closestVendorDir(dir string) (string, error) { + dir = filepath.Clean(dir) + for dir != "" && dir != string(filepath.Separator) { // TODO(stevvooe): May not work on windows + vendor := filepath.Join(dir, "vendor") + fi, err := os.Stat(vendor) + if err != nil { + if os.IsNotExist(err) { + // up we go! + dir = filepath.Dir(dir) + continue + } + return "", err + } + + if !fi.IsDir() { + // up we go! + dir = filepath.Dir(dir) + continue + } + + return vendor, nil + } + + return "", fmt.Errorf("no vendor dir found") +} diff --git a/tools/gen-gen-go.sh b/tools/gen-gen-go.sh deleted file mode 100755 index bfed476..0000000 --- a/tools/gen-gen-go.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/bash - -# This script generates gen.go for grpc packages. - -set -e - -validate_dir() { - dir=$1 - parent=$(dirname $dir) - ( [ $parent = api/types ] || [ $parent = api/services ] ) || { echo "Unexpected dir ${dir}"; exit 1; } - [ $(find $dir -name '*.proto' | wc -l) -eq 1 ] || { echo "${dir} has unexpected number of proto files"; exit 1; } -} - -repo=$(pwd) -[ $(basename $repo) = containerd ] || { echo "Unexpected cwd ${repo}"; exit 1; } -protos=$(find api -name '*.proto') -for proto in $protos; do - dir=$(dirname $proto) - validate_dir $dir - proto_base=$(basename $proto) - pkg="github.com/docker/containerd/${dir}" - pkg_base=$(basename $dir) - gengo="${dir}/gen.go" - cat < $gengo -// Code generated by tools/gen-gen-go.sh -// DO NOT EDIT! - -package ${pkg_base} - -//go:generate protoc -I.:${repo}/vendor:${repo}/vendor/github.com/gogo/protobuf:${repo}/../../..:/usr/local/include --gogoctrd_out=plugins=grpc,import_path=${pkg},Mgogoproto/gogo.proto=github.com/gogo/protobuf/gogoproto,Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:. ${proto_base} -EOF -done