peridot/apollo/proto/v1/BUILD.bazel

66 lines
1.9 KiB
Python
Raw Normal View History

2022-07-07 20:11:50 +00:00
load("@rules_proto//proto:defs.bzl", "proto_library")
2022-10-30 01:59:25 +00:00
load("@io_bazel_rules_go//go:def.bzl", "go_library")
2022-07-07 20:11:50 +00:00
load("@io_bazel_rules_go//proto:def.bzl", "go_proto_library")
load("@com_github_grpc_ecosystem_grpc_gateway_v2//protoc-gen-openapiv2:defs.bzl", "protoc_gen_openapiv2")
load("@openapi_tools_generator_bazel//:defs.bzl", "openapi_generator")
proto_library(
2022-10-30 01:59:25 +00:00
name = "apollopb_proto",
2022-07-07 20:11:50 +00:00
srcs = [
"advisory.proto",
2022-10-30 01:59:25 +00:00
"affected_product.proto",
"apollo.proto",
"build.proto",
"cve.proto",
"fix.proto",
"short_code.proto",
2022-07-07 20:11:50 +00:00
],
visibility = ["//visibility:public"],
deps = [
"@com_envoyproxy_protoc_gen_validate//validate:validate_proto",
"@com_google_protobuf//:timestamp_proto",
"@com_google_protobuf//:wrappers_proto",
"@go_googleapis//google/api:annotations_proto",
2022-10-30 01:59:25 +00:00
"@go_googleapis//google/api:httpbody_proto",
2022-07-07 20:11:50 +00:00
],
)
go_proto_library(
2022-10-30 01:59:25 +00:00
name = "apollopb_go_proto",
2022-07-07 20:11:50 +00:00
compilers = [
"//:go_apiv2",
"//:go_grpc",
"//:go_validate",
"@com_github_grpc_ecosystem_grpc_gateway_v2//protoc-gen-grpc-gateway:go_gen_grpc_gateway",
],
2022-10-30 01:59:25 +00:00
importpath = "peridot.resf.org/apollo/pb",
proto = ":apollopb_proto",
2022-07-07 20:11:50 +00:00
visibility = ["//visibility:public"],
deps = [
"@com_envoyproxy_protoc_gen_validate//validate:validate_go_proto",
"@go_googleapis//google/api:annotations_go_proto",
2022-10-30 01:59:25 +00:00
"@go_googleapis//google/api:httpbody_go_proto",
2022-07-07 20:11:50 +00:00
],
)
2022-10-30 01:59:25 +00:00
go_library(
name = "pb",
embed = [":apollopb_go_proto"],
importpath = "peridot.resf.org/apollo/pb",
visibility = ["//visibility:public"],
)
2022-07-07 20:11:50 +00:00
protoc_gen_openapiv2(
name = "openapi",
2022-10-30 01:59:25 +00:00
proto = ":apollopb_proto",
2022-07-07 20:11:50 +00:00
simple_operation_ids = True,
single_output = True,
)
openapi_generator(
name = "client_typescript",
generator = "typescript-fetch",
spec = ":openapi",
visibility = ["//visibility:public"],
)