aae8cedb760b51c975a050eb8a72bf91b09292cb
[platform/upstream/grpc.git] / src / python / grpcio_channelz / grpc_channelz / v1 / BUILD.bazel
1 load("@grpc_python_dependencies//:requirements.bzl", "requirement")
2 load("@org_pubref_rules_protobuf//python:rules.bzl", "py_proto_library")
3
4 package(default_visibility = ["//visibility:public"])
5
6 genrule(
7     name = "mv_channelz_proto",
8     srcs = [
9         "//src/proto/grpc/channelz:channelz_proto_file",
10     ],
11     outs = ["channelz.proto",],
12     cmd = "cp $< $@",
13 )
14
15 py_proto_library(
16     name = "py_channelz_proto",
17     protos = ["mv_channelz_proto",],
18     imports = [
19         "external/com_google_protobuf/src/",
20     ],
21     inputs = [
22         "@com_google_protobuf//:well_known_protos",
23     ],
24     with_grpc = True,
25     deps = [
26         requirement('protobuf'),
27     ],
28 )
29
30 py_library(
31     name = "grpc_channelz",
32     srcs = ["channelz.py",],
33     deps = [
34         ":py_channelz_proto",
35         "//src/python/grpcio/grpc:grpcio",
36     ],
37     imports=["../../",],
38 )