xref: /aosp_15_r20/external/googleapis/google/cloud/orgpolicy/v2/BUILD.bazel (revision d5c09012810ac0c9f33fe448fb6da8260d444cc9)
1# This file was automatically generated by BuildFileGenerator
2# https://github.com/googleapis/rules_gapic/tree/master/bazel
3
4# Most of the manual changes to this file will be overwritten.
5# It's **only** allowed to change the following rule attribute values:
6# - names of *_gapic_assembly_* rules
7# - certain parameters of *_gapic_library rules, including but not limited to:
8#    * extra_protoc_parameters
9#    * extra_protoc_file_parameters
10# The complete list of preserved parameters can be found in the source code.
11
12# This is an API workspace, having public visibility by default makes perfect sense.
13package(default_visibility = ["//visibility:public"])
14
15##############################################################################
16# Common
17##############################################################################
18load("@rules_proto//proto:defs.bzl", "proto_library")
19load("@com_google_googleapis_imports//:imports.bzl", "proto_library_with_info")
20
21proto_library(
22    name = "orgpolicy_proto",
23    srcs = [
24        "constraint.proto",
25        "orgpolicy.proto",
26    ],
27    deps = [
28        "//google/api:annotations_proto",
29        "//google/api:client_proto",
30        "//google/api:field_behavior_proto",
31        "//google/api:resource_proto",
32        "//google/type:expr_proto",
33        "@com_google_protobuf//:empty_proto",
34        "@com_google_protobuf//:field_mask_proto",
35        "@com_google_protobuf//:timestamp_proto",
36    ],
37)
38
39proto_library_with_info(
40    name = "orgpolicy_proto_with_info",
41    deps = [
42        ":orgpolicy_proto",
43        "//google/cloud:common_resources_proto",
44    ],
45)
46
47##############################################################################
48# Java
49##############################################################################
50load(
51    "@com_google_googleapis_imports//:imports.bzl",
52    "java_gapic_assembly_gradle_pkg",
53    "java_gapic_library",
54    "java_gapic_test",
55    "java_grpc_library",
56    "java_proto_library",
57)
58
59java_proto_library(
60    name = "orgpolicy_java_proto",
61    deps = [":orgpolicy_proto"],
62)
63
64java_grpc_library(
65    name = "orgpolicy_java_grpc",
66    srcs = [":orgpolicy_proto"],
67    deps = [":orgpolicy_java_proto"],
68)
69
70java_gapic_library(
71    name = "orgpolicy_java_gapic",
72    srcs = [":orgpolicy_proto_with_info"],
73    gapic_yaml = None,
74    grpc_service_config = "orgpolicy_grpc_service_config.json",
75    rest_numeric_enums = True,
76    service_yaml = "orgpolicy_v2.yaml",
77    test_deps = [
78        ":orgpolicy_java_grpc",
79    ],
80    transport = "grpc+rest",
81    deps = [
82        ":orgpolicy_java_proto",
83        "//google/api:api_java_proto",
84    ],
85)
86
87java_gapic_test(
88    name = "orgpolicy_java_gapic_test_suite",
89    test_classes = [
90        "com.google.cloud.orgpolicy.v2.OrgPolicyClientHttpJsonTest",
91        "com.google.cloud.orgpolicy.v2.OrgPolicyClientTest",
92    ],
93    runtime_deps = [":orgpolicy_java_gapic_test"],
94)
95
96# Open Source Packages
97java_gapic_assembly_gradle_pkg(
98    name = "google-cloud-orgpolicy-v2-java",
99    include_samples = True,
100    transport = "grpc+rest",
101    deps = [
102        ":orgpolicy_java_gapic",
103        ":orgpolicy_java_grpc",
104        ":orgpolicy_java_proto",
105        ":orgpolicy_proto",
106    ],
107)
108
109##############################################################################
110# Go
111##############################################################################
112load(
113    "@com_google_googleapis_imports//:imports.bzl",
114    "go_gapic_assembly_pkg",
115    "go_gapic_library",
116    "go_proto_library",
117)
118
119go_proto_library(
120    name = "orgpolicy_go_proto",
121    compilers = ["@io_bazel_rules_go//proto:go_grpc"],
122    importpath = "cloud.google.com/go/orgpolicy/apiv2/orgpolicypb",
123    protos = [":orgpolicy_proto"],
124    deps = [
125        "//google/api:annotations_go_proto",
126        "//google/type:expr_go_proto",
127    ],
128)
129
130go_gapic_library(
131    name = "orgpolicy_go_gapic",
132    srcs = [":orgpolicy_proto_with_info"],
133    grpc_service_config = "orgpolicy_grpc_service_config.json",
134    importpath = "cloud.google.com/go/orgpolicy/apiv2;orgpolicy",
135    metadata = True,
136    release_level = "ga",
137    rest_numeric_enums = True,
138    service_yaml = "orgpolicy_v2.yaml",
139    transport = "grpc+rest",
140    deps = [
141        ":orgpolicy_go_proto",
142    ],
143)
144
145# Open Source Packages
146go_gapic_assembly_pkg(
147    name = "gapi-cloud-orgpolicy-v2-go",
148    deps = [
149        ":orgpolicy_go_gapic",
150        ":orgpolicy_go_gapic_srcjar-metadata.srcjar",
151        ":orgpolicy_go_gapic_srcjar-snippets.srcjar",
152        ":orgpolicy_go_gapic_srcjar-test.srcjar",
153        ":orgpolicy_go_proto",
154    ],
155)
156
157##############################################################################
158# Python
159##############################################################################
160load(
161    "@com_google_googleapis_imports//:imports.bzl",
162    "py_gapic_assembly_pkg",
163    "py_gapic_library",
164    "py_test",
165)
166
167py_gapic_library(
168    name = "orgpolicy_py_gapic",
169    srcs = [":orgpolicy_proto"],
170    grpc_service_config = "orgpolicy_grpc_service_config.json",
171    opt_args = ["warehouse-package-name=google-cloud-org-policy"],
172    rest_numeric_enums = True,
173    service_yaml = "orgpolicy_v2.yaml",
174    transport = "grpc+rest",
175    deps = [
176    ],
177)
178
179py_test(
180    name = "orgpolicy_py_gapic_test",
181    srcs = [
182        "orgpolicy_py_gapic_pytest.py",
183        "orgpolicy_py_gapic_test.py",
184    ],
185    legacy_create_init = False,
186    deps = [":orgpolicy_py_gapic"],
187)
188
189# Open Source Packages
190py_gapic_assembly_pkg(
191    name = "orgpolicy-v2-py",
192    deps = [
193        ":orgpolicy_py_gapic",
194    ],
195)
196
197##############################################################################
198# PHP
199##############################################################################
200load(
201    "@com_google_googleapis_imports//:imports.bzl",
202    "php_gapic_assembly_pkg",
203    "php_gapic_library",
204    "php_proto_library",
205)
206
207php_proto_library(
208    name = "orgpolicy_php_proto",
209    deps = [":orgpolicy_proto"],
210)
211
212php_gapic_library(
213    name = "orgpolicy_php_gapic",
214    srcs = [":orgpolicy_proto_with_info"],
215    grpc_service_config = "orgpolicy_grpc_service_config.json",
216    migration_mode = "MIGRATING",
217    rest_numeric_enums = True,
218    service_yaml = "orgpolicy_v2.yaml",
219    transport = "grpc+rest",
220    deps = [":orgpolicy_php_proto"],
221)
222
223# Open Source Packages
224php_gapic_assembly_pkg(
225    name = "google-cloud-orgpolicy-v2-php",
226    deps = [
227        ":orgpolicy_php_gapic",
228        ":orgpolicy_php_proto",
229    ],
230)
231
232##############################################################################
233# Node.js
234##############################################################################
235load(
236    "@com_google_googleapis_imports//:imports.bzl",
237    "nodejs_gapic_assembly_pkg",
238    "nodejs_gapic_library",
239)
240
241nodejs_gapic_library(
242    name = "orgpolicy_nodejs_gapic",
243    package_name = "@google-cloud/org-policy",
244    src = ":orgpolicy_proto_with_info",
245    extra_protoc_parameters = ["metadata"],
246    grpc_service_config = "orgpolicy_grpc_service_config.json",
247    package = "google.cloud.orgpolicy.v2",
248    rest_numeric_enums = True,
249    service_yaml = "orgpolicy_v2.yaml",
250    transport = "grpc+rest",
251    deps = [],
252)
253
254nodejs_gapic_assembly_pkg(
255    name = "orgpolicy-v2-nodejs",
256    deps = [
257        ":orgpolicy_nodejs_gapic",
258        ":orgpolicy_proto",
259    ],
260)
261
262##############################################################################
263# Ruby
264##############################################################################
265load(
266    "@com_google_googleapis_imports//:imports.bzl",
267    "ruby_cloud_gapic_library",
268    "ruby_gapic_assembly_pkg",
269    "ruby_grpc_library",
270    "ruby_proto_library",
271)
272
273ruby_proto_library(
274    name = "orgpolicy_ruby_proto",
275    deps = [":orgpolicy_proto"],
276)
277
278ruby_grpc_library(
279    name = "orgpolicy_ruby_grpc",
280    srcs = [":orgpolicy_proto"],
281    deps = [":orgpolicy_ruby_proto"],
282)
283
284ruby_cloud_gapic_library(
285    name = "orgpolicy_ruby_gapic",
286    srcs = [":orgpolicy_proto_with_info"],
287    extra_protoc_parameters = [
288        "ruby-cloud-api-id=orgpolicy.googleapis.com",
289        "ruby-cloud-api-shortname=orgpolicy",
290        "ruby-cloud-env-prefix=ORG_POLICY",
291        "ruby-cloud-gem-name=google-cloud-org_policy-v2",
292        "ruby-cloud-product-url=https://cloud.google.com/resource-manager/docs/organization-policy/overview",
293    ],
294    grpc_service_config = "orgpolicy_grpc_service_config.json",
295    rest_numeric_enums = True,
296    ruby_cloud_description = "The Cloud Org Policy service provides a simple mechanism for organizations to restrict the allowed configurations across their entire Cloud Resource hierarchy.",
297    ruby_cloud_title = "Organization Policy V2",
298    service_yaml = "orgpolicy_v2.yaml",
299    transport = "grpc+rest",
300    deps = [
301        ":orgpolicy_ruby_grpc",
302        ":orgpolicy_ruby_proto",
303    ],
304)
305
306# Open Source Packages
307ruby_gapic_assembly_pkg(
308    name = "google-cloud-orgpolicy-v2-ruby",
309    deps = [
310        ":orgpolicy_ruby_gapic",
311        ":orgpolicy_ruby_grpc",
312        ":orgpolicy_ruby_proto",
313    ],
314)
315
316##############################################################################
317# C#
318##############################################################################
319load(
320    "@com_google_googleapis_imports//:imports.bzl",
321    "csharp_gapic_assembly_pkg",
322    "csharp_gapic_library",
323    "csharp_grpc_library",
324    "csharp_proto_library",
325)
326
327csharp_proto_library(
328    name = "orgpolicy_csharp_proto",
329    deps = [":orgpolicy_proto"],
330)
331
332csharp_grpc_library(
333    name = "orgpolicy_csharp_grpc",
334    srcs = [":orgpolicy_proto"],
335    deps = [":orgpolicy_csharp_proto"],
336)
337
338csharp_gapic_library(
339    name = "orgpolicy_csharp_gapic",
340    srcs = [":orgpolicy_proto_with_info"],
341    common_resources_config = "@gax_dotnet//:Google.Api.Gax/ResourceNames/CommonResourcesConfig.json",
342    grpc_service_config = "orgpolicy_grpc_service_config.json",
343    rest_numeric_enums = True,
344    service_yaml = "orgpolicy_v2.yaml",
345    transport = "grpc+rest",
346    deps = [
347        ":orgpolicy_csharp_grpc",
348        ":orgpolicy_csharp_proto",
349    ],
350)
351
352# Open Source Packages
353csharp_gapic_assembly_pkg(
354    name = "google-cloud-orgpolicy-v2-csharp",
355    deps = [
356        ":orgpolicy_csharp_gapic",
357        ":orgpolicy_csharp_grpc",
358        ":orgpolicy_csharp_proto",
359    ],
360)
361
362##############################################################################
363# C++
364##############################################################################
365load(
366    "@com_google_googleapis_imports//:imports.bzl",
367    "cc_grpc_library",
368    "cc_proto_library",
369)
370
371cc_proto_library(
372    name = "orgpolicy_cc_proto",
373    deps = [":orgpolicy_proto"],
374)
375
376cc_grpc_library(
377    name = "orgpolicy_cc_grpc",
378    srcs = [":orgpolicy_proto"],
379    grpc_only = True,
380    deps = [":orgpolicy_cc_proto"],
381)
382