tooling: generate protoset file (#17364)

Extends the `proto` make target to generate a protoset file for use with
grpcurl etc.
This commit is contained in:
Dan Upton 2023-06-26 13:53:55 +01:00 committed by GitHub
parent b117eb0126
commit ce24646d36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 0 deletions

View File

@ -72,6 +72,10 @@ function main {
status "Generated gRPC rate limit mapping file" status "Generated gRPC rate limit mapping file"
generate_protoset_file
status "Generated protoset file"
return 0 return 0
} }
@ -152,5 +156,11 @@ function generate_rate_limit_mappings {
} }
} }
function generate_protoset_file {
local pkg_dir="${SOURCE_DIR}/pkg"
mkdir -p "$pkg_dir"
print_run buf build -o "${pkg_dir}/consul.protoset"
}
main "$@" main "$@"
exit $? exit $?