containerd/api/Protobuild.toml
Maksym Pavlenko d1cd9757eb Generate GRPC for runtime task service
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2023-02-02 09:58:43 -08:00

62 lines
1.8 KiB
TOML

version = "2"
generators = ["go", "go-grpc"]
# Control protoc include paths. Below are usually some good defaults, but feel
# free to try it without them if it works for your project.
[includes]
# Include paths that will be added before all others. Typically, you want to
# treat the root of the project as an include, but this may not be necessary.
before = []
# Paths that will be added untouched to the end of the includes. We use
# `/usr/local/include` to pickup the common install location of protobuf.
# This is the default.
after = ["/usr/local/include"]
# This section maps protobuf imports to Go packages. These will become
# `-M` directives in the call to the go protobuf generator.
[packages]
"google/rpc/status.proto" = "google.golang.org/genproto/googleapis/rpc/status"
[[overrides]]
prefixes = ["github.com/containerd/containerd/api/events"]
generators = ["go", "go-ttrpc", "go-fieldpath"]
[[overrides]]
prefixes = ["github.com/containerd/containerd/api/services/ttrpc/events/v1"]
generators = ["go", "go-ttrpc", "go-fieldpath"]
[[overrides]]
# enable ttrpc and disable fieldpath and grpc for the shim
prefixes = [
"github.com/containerd/containerd/runtime/v1/shim/v1",
"github.com/containerd/containerd/api/runtime/task/v2",
]
generators = ["go", "go-ttrpc"]
[[overrides]]
prefixes = [
"github.com/containerd/containerd/api/runtime/sandbox/v1",
]
generators = ["go", "go-ttrpc", "go-grpc"]
[overrides.parameters.go-ttrpc]
prefix = "TTRPC"
[[overrides]]
prefixes = [
"github.com/containerd/containerd/api/runtime/task/v3",
]
generators = ["go", "go-ttrpc", "go-grpc"]
[overrides.parameters.go-ttrpc]
prefix = "TTRPC"
# Aggregrate the API descriptors to lock down API changes.
[[descriptors]]
prefix = "github.com/containerd/containerd/api"
target = "next.pb.txt"
ignore_files = [
"google/protobuf/descriptor.proto",
]