mirror of
https://github.com/rocky-linux/peridot.git
synced 2024-11-22 13:11:27 +00:00
ad0f7a5305
Upgrade to Go 1.20.5, Hydra v2 SDK, rules-go v0.44.2 (with proper resolves), protobuf v25.3 and mass upgrade of Go dependencies.
66 lines
1.9 KiB
Python
66 lines
1.9 KiB
Python
load("@rules_proto//proto:defs.bzl", "proto_library")
|
|
load("@io_bazel_rules_go//go:def.bzl", "go_library")
|
|
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(
|
|
name = "apollopb_proto",
|
|
srcs = [
|
|
"advisory.proto",
|
|
"affected_product.proto",
|
|
"apollo.proto",
|
|
"build.proto",
|
|
"cve.proto",
|
|
"fix.proto",
|
|
"short_code.proto",
|
|
],
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"@com_envoyproxy_protoc_gen_validate//validate:validate_proto",
|
|
"@com_google_protobuf//:timestamp_proto",
|
|
"@com_google_protobuf//:wrappers_proto",
|
|
"@googleapis//google/api:annotations_proto",
|
|
"@googleapis//google/api:httpbody_proto",
|
|
],
|
|
)
|
|
|
|
go_proto_library(
|
|
name = "apollopb_go_proto",
|
|
compilers = [
|
|
"//:go_apiv2",
|
|
"//:go_grpc",
|
|
"//:go_validate",
|
|
"//:go_gen_grpc_gateway",
|
|
],
|
|
importpath = "peridot.resf.org/apollo/pb",
|
|
proto = ":apollopb_proto",
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"@com_envoyproxy_protoc_gen_validate//validate:validate_go_proto",
|
|
"@org_golang_google_genproto_googleapis_api//annotations",
|
|
"@org_golang_google_genproto_googleapis_api//httpbody",
|
|
],
|
|
)
|
|
|
|
go_library(
|
|
name = "pb",
|
|
embed = [":apollopb_go_proto"],
|
|
importpath = "peridot.resf.org/apollo/pb",
|
|
visibility = ["//visibility:public"],
|
|
)
|
|
|
|
protoc_gen_openapiv2(
|
|
name = "openapi",
|
|
proto = ":apollopb_proto",
|
|
simple_operation_ids = True,
|
|
single_output = True,
|
|
)
|
|
|
|
openapi_generator(
|
|
name = "client_typescript",
|
|
generator = "typescript-fetch",
|
|
spec = ":openapi",
|
|
visibility = ["//visibility:public"],
|
|
)
|