pulumi-gcp 7.15.0a1711038061__py3-none-any.whl → 7.16.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pulumi_gcp/__init__.py +102 -0
- pulumi_gcp/accesscontextmanager/__init__.py +1 -0
- pulumi_gcp/accesscontextmanager/_inputs.py +74 -58
- pulumi_gcp/accesscontextmanager/outputs.py +74 -58
- pulumi_gcp/accesscontextmanager/service_perimeter.py +0 -2
- pulumi_gcp/accesscontextmanager/service_perimeter_dry_run_resource.py +345 -0
- pulumi_gcp/accesscontextmanager/service_perimeter_egress_policy.py +80 -0
- pulumi_gcp/accesscontextmanager/service_perimeter_ingress_policy.py +86 -0
- pulumi_gcp/accesscontextmanager/service_perimeter_resource.py +4 -2
- pulumi_gcp/apphub/__init__.py +15 -0
- pulumi_gcp/apphub/_inputs.py +1016 -0
- pulumi_gcp/apphub/application.py +775 -0
- pulumi_gcp/apphub/get_discovered_service.py +180 -0
- pulumi_gcp/apphub/get_discovered_workload.py +180 -0
- pulumi_gcp/apphub/outputs.py +1206 -0
- pulumi_gcp/apphub/service.py +1121 -0
- pulumi_gcp/apphub/service_project_attachment.py +516 -0
- pulumi_gcp/apphub/workload.py +1197 -0
- pulumi_gcp/cloudquota/__init__.py +10 -0
- pulumi_gcp/cloudquota/get_s_quota_info.py +322 -0
- pulumi_gcp/cloudquota/get_s_quota_infos.py +136 -0
- pulumi_gcp/cloudquota/outputs.py +375 -0
- pulumi_gcp/cloudrunv2/_inputs.py +85 -4
- pulumi_gcp/cloudrunv2/get_service.py +11 -1
- pulumi_gcp/cloudrunv2/outputs.py +165 -6
- pulumi_gcp/cloudrunv2/service.py +60 -6
- pulumi_gcp/composer/_inputs.py +16 -0
- pulumi_gcp/composer/outputs.py +23 -0
- pulumi_gcp/compute/_inputs.py +109 -11
- pulumi_gcp/compute/outputs.py +144 -13
- pulumi_gcp/compute/region_network_endpoint_group.py +30 -0
- pulumi_gcp/compute/region_url_map.py +152 -0
- pulumi_gcp/config/__init__.pyi +4 -0
- pulumi_gcp/config/vars.py +8 -0
- pulumi_gcp/dataform/repository.py +4 -74
- pulumi_gcp/firebase/__init__.py +1 -0
- pulumi_gcp/firebase/android_app.py +41 -40
- pulumi_gcp/firebase/app_check_device_check_config.py +572 -0
- pulumi_gcp/firestore/_inputs.py +69 -0
- pulumi_gcp/firestore/database.py +206 -0
- pulumi_gcp/firestore/index.py +34 -48
- pulumi_gcp/firestore/outputs.py +80 -0
- pulumi_gcp/gkeonprem/_inputs.py +1 -3
- pulumi_gcp/gkeonprem/outputs.py +1 -3
- pulumi_gcp/gkeonprem/v_mware_cluster.py +2 -0
- pulumi_gcp/iap/__init__.py +5 -0
- pulumi_gcp/iap/_inputs.py +100 -0
- pulumi_gcp/iap/get_tunnel_dest_group_iam_policy.py +172 -0
- pulumi_gcp/iap/outputs.py +76 -0
- pulumi_gcp/iap/tunnel_dest_group.py +524 -0
- pulumi_gcp/iap/tunnel_dest_group_iam_binding.py +858 -0
- pulumi_gcp/iap/tunnel_dest_group_iam_member.py +858 -0
- pulumi_gcp/iap/tunnel_dest_group_iam_policy.py +760 -0
- pulumi_gcp/kms/__init__.py +1 -0
- pulumi_gcp/kms/_inputs.py +246 -0
- pulumi_gcp/kms/ekm_connection.py +610 -0
- pulumi_gcp/kms/outputs.py +242 -0
- pulumi_gcp/monitoring/_inputs.py +2 -0
- pulumi_gcp/monitoring/outputs.py +2 -0
- pulumi_gcp/networksecurity/__init__.py +1 -0
- pulumi_gcp/networksecurity/firewall_endpoint.py +48 -0
- pulumi_gcp/networksecurity/firewall_endpoint_association.py +753 -0
- pulumi_gcp/notebooks/instance.py +8 -0
- pulumi_gcp/orgpolicy/policy.py +2 -2
- pulumi_gcp/provider.py +40 -0
- pulumi_gcp/pubsub/_inputs.py +108 -0
- pulumi_gcp/pubsub/get_topic.py +11 -1
- pulumi_gcp/pubsub/outputs.py +213 -0
- pulumi_gcp/pubsub/subscription.py +4 -4
- pulumi_gcp/pubsub/topic.py +92 -0
- pulumi_gcp/securityposture/posture.py +2 -2
- pulumi_gcp/securityposture/posture_deployment.py +2 -2
- pulumi_gcp/storage/_inputs.py +72 -15
- pulumi_gcp/storage/bucket.py +54 -0
- pulumi_gcp/storage/get_bucket.py +11 -1
- pulumi_gcp/storage/outputs.py +110 -14
- pulumi_gcp/workstations/_inputs.py +247 -4
- pulumi_gcp/workstations/outputs.py +261 -5
- pulumi_gcp/workstations/workstation_config.py +160 -0
- {pulumi_gcp-7.15.0a1711038061.dist-info → pulumi_gcp-7.16.0.dist-info}/METADATA +1 -1
- {pulumi_gcp-7.15.0a1711038061.dist-info → pulumi_gcp-7.16.0.dist-info}/RECORD +83 -61
- {pulumi_gcp-7.15.0a1711038061.dist-info → pulumi_gcp-7.16.0.dist-info}/WHEEL +0 -0
- {pulumi_gcp-7.15.0a1711038061.dist-info → pulumi_gcp-7.16.0.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,1121 @@
|
|
1
|
+
# coding=utf-8
|
2
|
+
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
|
3
|
+
# *** Do not edit by hand unless you're certain you know what you are doing! ***
|
4
|
+
|
5
|
+
import copy
|
6
|
+
import warnings
|
7
|
+
import pulumi
|
8
|
+
import pulumi.runtime
|
9
|
+
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
10
|
+
from .. import _utilities
|
11
|
+
from . import outputs
|
12
|
+
from ._inputs import *
|
13
|
+
|
14
|
+
__all__ = ['ServiceArgs', 'Service']
|
15
|
+
|
16
|
+
@pulumi.input_type
|
17
|
+
class ServiceArgs:
|
18
|
+
def __init__(__self__, *,
|
19
|
+
application_id: pulumi.Input[str],
|
20
|
+
discovered_service: pulumi.Input[str],
|
21
|
+
location: pulumi.Input[str],
|
22
|
+
service_id: pulumi.Input[str],
|
23
|
+
attributes: Optional[pulumi.Input['ServiceAttributesArgs']] = None,
|
24
|
+
description: Optional[pulumi.Input[str]] = None,
|
25
|
+
display_name: Optional[pulumi.Input[str]] = None,
|
26
|
+
project: Optional[pulumi.Input[str]] = None):
|
27
|
+
"""
|
28
|
+
The set of arguments for constructing a Service resource.
|
29
|
+
:param pulumi.Input[str] application_id: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
30
|
+
:param pulumi.Input[str] discovered_service: Immutable. The resource name of the original discovered service.
|
31
|
+
:param pulumi.Input[str] location: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
32
|
+
:param pulumi.Input[str] service_id: The Service identifier.
|
33
|
+
|
34
|
+
|
35
|
+
- - -
|
36
|
+
:param pulumi.Input['ServiceAttributesArgs'] attributes: Consumer provided attributes.
|
37
|
+
Structure is documented below.
|
38
|
+
:param pulumi.Input[str] description: User-defined description of a Service.
|
39
|
+
:param pulumi.Input[str] display_name: User-defined name for the Service.
|
40
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
41
|
+
If it is not provided, the provider project is used.
|
42
|
+
"""
|
43
|
+
pulumi.set(__self__, "application_id", application_id)
|
44
|
+
pulumi.set(__self__, "discovered_service", discovered_service)
|
45
|
+
pulumi.set(__self__, "location", location)
|
46
|
+
pulumi.set(__self__, "service_id", service_id)
|
47
|
+
if attributes is not None:
|
48
|
+
pulumi.set(__self__, "attributes", attributes)
|
49
|
+
if description is not None:
|
50
|
+
pulumi.set(__self__, "description", description)
|
51
|
+
if display_name is not None:
|
52
|
+
pulumi.set(__self__, "display_name", display_name)
|
53
|
+
if project is not None:
|
54
|
+
pulumi.set(__self__, "project", project)
|
55
|
+
|
56
|
+
@property
|
57
|
+
@pulumi.getter(name="applicationId")
|
58
|
+
def application_id(self) -> pulumi.Input[str]:
|
59
|
+
"""
|
60
|
+
Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
61
|
+
"""
|
62
|
+
return pulumi.get(self, "application_id")
|
63
|
+
|
64
|
+
@application_id.setter
|
65
|
+
def application_id(self, value: pulumi.Input[str]):
|
66
|
+
pulumi.set(self, "application_id", value)
|
67
|
+
|
68
|
+
@property
|
69
|
+
@pulumi.getter(name="discoveredService")
|
70
|
+
def discovered_service(self) -> pulumi.Input[str]:
|
71
|
+
"""
|
72
|
+
Immutable. The resource name of the original discovered service.
|
73
|
+
"""
|
74
|
+
return pulumi.get(self, "discovered_service")
|
75
|
+
|
76
|
+
@discovered_service.setter
|
77
|
+
def discovered_service(self, value: pulumi.Input[str]):
|
78
|
+
pulumi.set(self, "discovered_service", value)
|
79
|
+
|
80
|
+
@property
|
81
|
+
@pulumi.getter
|
82
|
+
def location(self) -> pulumi.Input[str]:
|
83
|
+
"""
|
84
|
+
Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
85
|
+
"""
|
86
|
+
return pulumi.get(self, "location")
|
87
|
+
|
88
|
+
@location.setter
|
89
|
+
def location(self, value: pulumi.Input[str]):
|
90
|
+
pulumi.set(self, "location", value)
|
91
|
+
|
92
|
+
@property
|
93
|
+
@pulumi.getter(name="serviceId")
|
94
|
+
def service_id(self) -> pulumi.Input[str]:
|
95
|
+
"""
|
96
|
+
The Service identifier.
|
97
|
+
|
98
|
+
|
99
|
+
- - -
|
100
|
+
"""
|
101
|
+
return pulumi.get(self, "service_id")
|
102
|
+
|
103
|
+
@service_id.setter
|
104
|
+
def service_id(self, value: pulumi.Input[str]):
|
105
|
+
pulumi.set(self, "service_id", value)
|
106
|
+
|
107
|
+
@property
|
108
|
+
@pulumi.getter
|
109
|
+
def attributes(self) -> Optional[pulumi.Input['ServiceAttributesArgs']]:
|
110
|
+
"""
|
111
|
+
Consumer provided attributes.
|
112
|
+
Structure is documented below.
|
113
|
+
"""
|
114
|
+
return pulumi.get(self, "attributes")
|
115
|
+
|
116
|
+
@attributes.setter
|
117
|
+
def attributes(self, value: Optional[pulumi.Input['ServiceAttributesArgs']]):
|
118
|
+
pulumi.set(self, "attributes", value)
|
119
|
+
|
120
|
+
@property
|
121
|
+
@pulumi.getter
|
122
|
+
def description(self) -> Optional[pulumi.Input[str]]:
|
123
|
+
"""
|
124
|
+
User-defined description of a Service.
|
125
|
+
"""
|
126
|
+
return pulumi.get(self, "description")
|
127
|
+
|
128
|
+
@description.setter
|
129
|
+
def description(self, value: Optional[pulumi.Input[str]]):
|
130
|
+
pulumi.set(self, "description", value)
|
131
|
+
|
132
|
+
@property
|
133
|
+
@pulumi.getter(name="displayName")
|
134
|
+
def display_name(self) -> Optional[pulumi.Input[str]]:
|
135
|
+
"""
|
136
|
+
User-defined name for the Service.
|
137
|
+
"""
|
138
|
+
return pulumi.get(self, "display_name")
|
139
|
+
|
140
|
+
@display_name.setter
|
141
|
+
def display_name(self, value: Optional[pulumi.Input[str]]):
|
142
|
+
pulumi.set(self, "display_name", value)
|
143
|
+
|
144
|
+
@property
|
145
|
+
@pulumi.getter
|
146
|
+
def project(self) -> Optional[pulumi.Input[str]]:
|
147
|
+
"""
|
148
|
+
The ID of the project in which the resource belongs.
|
149
|
+
If it is not provided, the provider project is used.
|
150
|
+
"""
|
151
|
+
return pulumi.get(self, "project")
|
152
|
+
|
153
|
+
@project.setter
|
154
|
+
def project(self, value: Optional[pulumi.Input[str]]):
|
155
|
+
pulumi.set(self, "project", value)
|
156
|
+
|
157
|
+
|
158
|
+
@pulumi.input_type
|
159
|
+
class _ServiceState:
|
160
|
+
def __init__(__self__, *,
|
161
|
+
application_id: Optional[pulumi.Input[str]] = None,
|
162
|
+
attributes: Optional[pulumi.Input['ServiceAttributesArgs']] = None,
|
163
|
+
create_time: Optional[pulumi.Input[str]] = None,
|
164
|
+
description: Optional[pulumi.Input[str]] = None,
|
165
|
+
discovered_service: Optional[pulumi.Input[str]] = None,
|
166
|
+
display_name: Optional[pulumi.Input[str]] = None,
|
167
|
+
location: Optional[pulumi.Input[str]] = None,
|
168
|
+
name: Optional[pulumi.Input[str]] = None,
|
169
|
+
project: Optional[pulumi.Input[str]] = None,
|
170
|
+
service_id: Optional[pulumi.Input[str]] = None,
|
171
|
+
service_properties: Optional[pulumi.Input[Sequence[pulumi.Input['ServiceServicePropertyArgs']]]] = None,
|
172
|
+
service_references: Optional[pulumi.Input[Sequence[pulumi.Input['ServiceServiceReferenceArgs']]]] = None,
|
173
|
+
state: Optional[pulumi.Input[str]] = None,
|
174
|
+
uid: Optional[pulumi.Input[str]] = None,
|
175
|
+
update_time: Optional[pulumi.Input[str]] = None):
|
176
|
+
"""
|
177
|
+
Input properties used for looking up and filtering Service resources.
|
178
|
+
:param pulumi.Input[str] application_id: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
179
|
+
:param pulumi.Input['ServiceAttributesArgs'] attributes: Consumer provided attributes.
|
180
|
+
Structure is documented below.
|
181
|
+
:param pulumi.Input[str] create_time: Output only. Create time.
|
182
|
+
:param pulumi.Input[str] description: User-defined description of a Service.
|
183
|
+
:param pulumi.Input[str] discovered_service: Immutable. The resource name of the original discovered service.
|
184
|
+
:param pulumi.Input[str] display_name: User-defined name for the Service.
|
185
|
+
:param pulumi.Input[str] location: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
186
|
+
:param pulumi.Input[str] name: Identifier. The resource name of a Service. Format:
|
187
|
+
"projects/{host-project-id}/locations/{location}/applications/{application-id}/services/{service-id}"
|
188
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
189
|
+
If it is not provided, the provider project is used.
|
190
|
+
:param pulumi.Input[str] service_id: The Service identifier.
|
191
|
+
|
192
|
+
|
193
|
+
- - -
|
194
|
+
:param pulumi.Input[Sequence[pulumi.Input['ServiceServicePropertyArgs']]] service_properties: Properties of an underlying cloud resource that can comprise a Service.
|
195
|
+
Structure is documented below.
|
196
|
+
:param pulumi.Input[Sequence[pulumi.Input['ServiceServiceReferenceArgs']]] service_references: Reference to an underlying networking resource that can comprise a Service.
|
197
|
+
Structure is documented below.
|
198
|
+
:param pulumi.Input[str] state: Output only. Service state. Possible values: STATE_UNSPECIFIED CREATING ACTIVE DELETING DETACHED
|
199
|
+
:param pulumi.Input[str] uid: Output only. A universally unique identifier (UUID) for the `Service` in the UUID4
|
200
|
+
format.
|
201
|
+
:param pulumi.Input[str] update_time: Output only. Update time.
|
202
|
+
"""
|
203
|
+
if application_id is not None:
|
204
|
+
pulumi.set(__self__, "application_id", application_id)
|
205
|
+
if attributes is not None:
|
206
|
+
pulumi.set(__self__, "attributes", attributes)
|
207
|
+
if create_time is not None:
|
208
|
+
pulumi.set(__self__, "create_time", create_time)
|
209
|
+
if description is not None:
|
210
|
+
pulumi.set(__self__, "description", description)
|
211
|
+
if discovered_service is not None:
|
212
|
+
pulumi.set(__self__, "discovered_service", discovered_service)
|
213
|
+
if display_name is not None:
|
214
|
+
pulumi.set(__self__, "display_name", display_name)
|
215
|
+
if location is not None:
|
216
|
+
pulumi.set(__self__, "location", location)
|
217
|
+
if name is not None:
|
218
|
+
pulumi.set(__self__, "name", name)
|
219
|
+
if project is not None:
|
220
|
+
pulumi.set(__self__, "project", project)
|
221
|
+
if service_id is not None:
|
222
|
+
pulumi.set(__self__, "service_id", service_id)
|
223
|
+
if service_properties is not None:
|
224
|
+
pulumi.set(__self__, "service_properties", service_properties)
|
225
|
+
if service_references is not None:
|
226
|
+
pulumi.set(__self__, "service_references", service_references)
|
227
|
+
if state is not None:
|
228
|
+
pulumi.set(__self__, "state", state)
|
229
|
+
if uid is not None:
|
230
|
+
pulumi.set(__self__, "uid", uid)
|
231
|
+
if update_time is not None:
|
232
|
+
pulumi.set(__self__, "update_time", update_time)
|
233
|
+
|
234
|
+
@property
|
235
|
+
@pulumi.getter(name="applicationId")
|
236
|
+
def application_id(self) -> Optional[pulumi.Input[str]]:
|
237
|
+
"""
|
238
|
+
Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
239
|
+
"""
|
240
|
+
return pulumi.get(self, "application_id")
|
241
|
+
|
242
|
+
@application_id.setter
|
243
|
+
def application_id(self, value: Optional[pulumi.Input[str]]):
|
244
|
+
pulumi.set(self, "application_id", value)
|
245
|
+
|
246
|
+
@property
|
247
|
+
@pulumi.getter
|
248
|
+
def attributes(self) -> Optional[pulumi.Input['ServiceAttributesArgs']]:
|
249
|
+
"""
|
250
|
+
Consumer provided attributes.
|
251
|
+
Structure is documented below.
|
252
|
+
"""
|
253
|
+
return pulumi.get(self, "attributes")
|
254
|
+
|
255
|
+
@attributes.setter
|
256
|
+
def attributes(self, value: Optional[pulumi.Input['ServiceAttributesArgs']]):
|
257
|
+
pulumi.set(self, "attributes", value)
|
258
|
+
|
259
|
+
@property
|
260
|
+
@pulumi.getter(name="createTime")
|
261
|
+
def create_time(self) -> Optional[pulumi.Input[str]]:
|
262
|
+
"""
|
263
|
+
Output only. Create time.
|
264
|
+
"""
|
265
|
+
return pulumi.get(self, "create_time")
|
266
|
+
|
267
|
+
@create_time.setter
|
268
|
+
def create_time(self, value: Optional[pulumi.Input[str]]):
|
269
|
+
pulumi.set(self, "create_time", value)
|
270
|
+
|
271
|
+
@property
|
272
|
+
@pulumi.getter
|
273
|
+
def description(self) -> Optional[pulumi.Input[str]]:
|
274
|
+
"""
|
275
|
+
User-defined description of a Service.
|
276
|
+
"""
|
277
|
+
return pulumi.get(self, "description")
|
278
|
+
|
279
|
+
@description.setter
|
280
|
+
def description(self, value: Optional[pulumi.Input[str]]):
|
281
|
+
pulumi.set(self, "description", value)
|
282
|
+
|
283
|
+
@property
|
284
|
+
@pulumi.getter(name="discoveredService")
|
285
|
+
def discovered_service(self) -> Optional[pulumi.Input[str]]:
|
286
|
+
"""
|
287
|
+
Immutable. The resource name of the original discovered service.
|
288
|
+
"""
|
289
|
+
return pulumi.get(self, "discovered_service")
|
290
|
+
|
291
|
+
@discovered_service.setter
|
292
|
+
def discovered_service(self, value: Optional[pulumi.Input[str]]):
|
293
|
+
pulumi.set(self, "discovered_service", value)
|
294
|
+
|
295
|
+
@property
|
296
|
+
@pulumi.getter(name="displayName")
|
297
|
+
def display_name(self) -> Optional[pulumi.Input[str]]:
|
298
|
+
"""
|
299
|
+
User-defined name for the Service.
|
300
|
+
"""
|
301
|
+
return pulumi.get(self, "display_name")
|
302
|
+
|
303
|
+
@display_name.setter
|
304
|
+
def display_name(self, value: Optional[pulumi.Input[str]]):
|
305
|
+
pulumi.set(self, "display_name", value)
|
306
|
+
|
307
|
+
@property
|
308
|
+
@pulumi.getter
|
309
|
+
def location(self) -> Optional[pulumi.Input[str]]:
|
310
|
+
"""
|
311
|
+
Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
312
|
+
"""
|
313
|
+
return pulumi.get(self, "location")
|
314
|
+
|
315
|
+
@location.setter
|
316
|
+
def location(self, value: Optional[pulumi.Input[str]]):
|
317
|
+
pulumi.set(self, "location", value)
|
318
|
+
|
319
|
+
@property
|
320
|
+
@pulumi.getter
|
321
|
+
def name(self) -> Optional[pulumi.Input[str]]:
|
322
|
+
"""
|
323
|
+
Identifier. The resource name of a Service. Format:
|
324
|
+
"projects/{host-project-id}/locations/{location}/applications/{application-id}/services/{service-id}"
|
325
|
+
"""
|
326
|
+
return pulumi.get(self, "name")
|
327
|
+
|
328
|
+
@name.setter
|
329
|
+
def name(self, value: Optional[pulumi.Input[str]]):
|
330
|
+
pulumi.set(self, "name", value)
|
331
|
+
|
332
|
+
@property
|
333
|
+
@pulumi.getter
|
334
|
+
def project(self) -> Optional[pulumi.Input[str]]:
|
335
|
+
"""
|
336
|
+
The ID of the project in which the resource belongs.
|
337
|
+
If it is not provided, the provider project is used.
|
338
|
+
"""
|
339
|
+
return pulumi.get(self, "project")
|
340
|
+
|
341
|
+
@project.setter
|
342
|
+
def project(self, value: Optional[pulumi.Input[str]]):
|
343
|
+
pulumi.set(self, "project", value)
|
344
|
+
|
345
|
+
@property
|
346
|
+
@pulumi.getter(name="serviceId")
|
347
|
+
def service_id(self) -> Optional[pulumi.Input[str]]:
|
348
|
+
"""
|
349
|
+
The Service identifier.
|
350
|
+
|
351
|
+
|
352
|
+
- - -
|
353
|
+
"""
|
354
|
+
return pulumi.get(self, "service_id")
|
355
|
+
|
356
|
+
@service_id.setter
|
357
|
+
def service_id(self, value: Optional[pulumi.Input[str]]):
|
358
|
+
pulumi.set(self, "service_id", value)
|
359
|
+
|
360
|
+
@property
|
361
|
+
@pulumi.getter(name="serviceProperties")
|
362
|
+
def service_properties(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['ServiceServicePropertyArgs']]]]:
|
363
|
+
"""
|
364
|
+
Properties of an underlying cloud resource that can comprise a Service.
|
365
|
+
Structure is documented below.
|
366
|
+
"""
|
367
|
+
return pulumi.get(self, "service_properties")
|
368
|
+
|
369
|
+
@service_properties.setter
|
370
|
+
def service_properties(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['ServiceServicePropertyArgs']]]]):
|
371
|
+
pulumi.set(self, "service_properties", value)
|
372
|
+
|
373
|
+
@property
|
374
|
+
@pulumi.getter(name="serviceReferences")
|
375
|
+
def service_references(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['ServiceServiceReferenceArgs']]]]:
|
376
|
+
"""
|
377
|
+
Reference to an underlying networking resource that can comprise a Service.
|
378
|
+
Structure is documented below.
|
379
|
+
"""
|
380
|
+
return pulumi.get(self, "service_references")
|
381
|
+
|
382
|
+
@service_references.setter
|
383
|
+
def service_references(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['ServiceServiceReferenceArgs']]]]):
|
384
|
+
pulumi.set(self, "service_references", value)
|
385
|
+
|
386
|
+
@property
|
387
|
+
@pulumi.getter
|
388
|
+
def state(self) -> Optional[pulumi.Input[str]]:
|
389
|
+
"""
|
390
|
+
Output only. Service state. Possible values: STATE_UNSPECIFIED CREATING ACTIVE DELETING DETACHED
|
391
|
+
"""
|
392
|
+
return pulumi.get(self, "state")
|
393
|
+
|
394
|
+
@state.setter
|
395
|
+
def state(self, value: Optional[pulumi.Input[str]]):
|
396
|
+
pulumi.set(self, "state", value)
|
397
|
+
|
398
|
+
@property
|
399
|
+
@pulumi.getter
|
400
|
+
def uid(self) -> Optional[pulumi.Input[str]]:
|
401
|
+
"""
|
402
|
+
Output only. A universally unique identifier (UUID) for the `Service` in the UUID4
|
403
|
+
format.
|
404
|
+
"""
|
405
|
+
return pulumi.get(self, "uid")
|
406
|
+
|
407
|
+
@uid.setter
|
408
|
+
def uid(self, value: Optional[pulumi.Input[str]]):
|
409
|
+
pulumi.set(self, "uid", value)
|
410
|
+
|
411
|
+
@property
|
412
|
+
@pulumi.getter(name="updateTime")
|
413
|
+
def update_time(self) -> Optional[pulumi.Input[str]]:
|
414
|
+
"""
|
415
|
+
Output only. Update time.
|
416
|
+
"""
|
417
|
+
return pulumi.get(self, "update_time")
|
418
|
+
|
419
|
+
@update_time.setter
|
420
|
+
def update_time(self, value: Optional[pulumi.Input[str]]):
|
421
|
+
pulumi.set(self, "update_time", value)
|
422
|
+
|
423
|
+
|
424
|
+
class Service(pulumi.CustomResource):
|
425
|
+
@overload
|
426
|
+
def __init__(__self__,
|
427
|
+
resource_name: str,
|
428
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
429
|
+
application_id: Optional[pulumi.Input[str]] = None,
|
430
|
+
attributes: Optional[pulumi.Input[pulumi.InputType['ServiceAttributesArgs']]] = None,
|
431
|
+
description: Optional[pulumi.Input[str]] = None,
|
432
|
+
discovered_service: Optional[pulumi.Input[str]] = None,
|
433
|
+
display_name: Optional[pulumi.Input[str]] = None,
|
434
|
+
location: Optional[pulumi.Input[str]] = None,
|
435
|
+
project: Optional[pulumi.Input[str]] = None,
|
436
|
+
service_id: Optional[pulumi.Input[str]] = None,
|
437
|
+
__props__=None):
|
438
|
+
"""
|
439
|
+
Service is a network/api interface that exposes some functionality to clients for consumption over the network. Service typically has one or more Workloads behind it. It registers identified service to the Application.
|
440
|
+
|
441
|
+
## Example Usage
|
442
|
+
|
443
|
+
### Apphub Service Basic
|
444
|
+
|
445
|
+
<!--Start PulumiCodeChooser -->
|
446
|
+
```python
|
447
|
+
import pulumi
|
448
|
+
import pulumi_gcp as gcp
|
449
|
+
import pulumi_time as time
|
450
|
+
|
451
|
+
application = gcp.apphub.Application("application",
|
452
|
+
location="us-central1",
|
453
|
+
application_id="example-application-1",
|
454
|
+
scope=gcp.apphub.ApplicationScopeArgs(
|
455
|
+
type="REGIONAL",
|
456
|
+
))
|
457
|
+
service_project = gcp.organizations.Project("service_project",
|
458
|
+
project_id="project-1",
|
459
|
+
name="Service Project",
|
460
|
+
org_id="123456789",
|
461
|
+
billing_account="000000-0000000-0000000-000000")
|
462
|
+
# Enable Compute API
|
463
|
+
compute_service_project = gcp.projects.Service("compute_service_project",
|
464
|
+
project=service_project.project_id,
|
465
|
+
service="compute.googleapis.com")
|
466
|
+
wait120s = time.index.Sleep("wait_120s", create_duration=120s)
|
467
|
+
service_project_attachment = gcp.apphub.ServiceProjectAttachment("service_project_attachment", service_project_attachment_id=service_project.project_id)
|
468
|
+
# VPC network
|
469
|
+
ilb_network = gcp.compute.Network("ilb_network",
|
470
|
+
name="l7-ilb-network",
|
471
|
+
project=service_project.project_id,
|
472
|
+
auto_create_subnetworks=False)
|
473
|
+
# backend subnet
|
474
|
+
ilb_subnet = gcp.compute.Subnetwork("ilb_subnet",
|
475
|
+
name="l7-ilb-subnet",
|
476
|
+
project=service_project.project_id,
|
477
|
+
ip_cidr_range="10.0.1.0/24",
|
478
|
+
region="us-central1",
|
479
|
+
network=ilb_network.id)
|
480
|
+
# health check
|
481
|
+
default = gcp.compute.HealthCheck("default",
|
482
|
+
name="l7-ilb-hc",
|
483
|
+
project=service_project.project_id,
|
484
|
+
check_interval_sec=1,
|
485
|
+
timeout_sec=1,
|
486
|
+
tcp_health_check=gcp.compute.HealthCheckTcpHealthCheckArgs(
|
487
|
+
port=80,
|
488
|
+
))
|
489
|
+
# backend service
|
490
|
+
backend = gcp.compute.RegionBackendService("backend",
|
491
|
+
name="l7-ilb-backend-subnet",
|
492
|
+
project=service_project.project_id,
|
493
|
+
region="us-central1",
|
494
|
+
health_checks=default.id)
|
495
|
+
# forwarding rule
|
496
|
+
forwarding_rule = gcp.compute.ForwardingRule("forwarding_rule",
|
497
|
+
name="l7-ilb-forwarding-rule",
|
498
|
+
project=service_project.project_id,
|
499
|
+
region="us-central1",
|
500
|
+
ip_version="IPV4",
|
501
|
+
load_balancing_scheme="INTERNAL",
|
502
|
+
all_ports=True,
|
503
|
+
backend_service=backend.id,
|
504
|
+
network=ilb_network.id,
|
505
|
+
subnetwork=ilb_subnet.id)
|
506
|
+
# discovered service block
|
507
|
+
catalog_service = gcp.apphub.get_discovered_service_output(location="us-central1",
|
508
|
+
service_uri=forwarding_rule.id.apply(lambda id: f"//compute.googleapis.com/{id}"))
|
509
|
+
wait120s_for_resource_ingestion = time.index.Sleep("wait_120s_for_resource_ingestion", create_duration=120s)
|
510
|
+
example = gcp.apphub.Service("example",
|
511
|
+
location="us-central1",
|
512
|
+
application_id=application.application_id,
|
513
|
+
service_id=forwarding_rule.name,
|
514
|
+
discovered_service=catalog_service.name)
|
515
|
+
```
|
516
|
+
<!--End PulumiCodeChooser -->
|
517
|
+
### Apphub Service Full
|
518
|
+
|
519
|
+
<!--Start PulumiCodeChooser -->
|
520
|
+
```python
|
521
|
+
import pulumi
|
522
|
+
import pulumi_gcp as gcp
|
523
|
+
import pulumi_time as time
|
524
|
+
|
525
|
+
application = gcp.apphub.Application("application",
|
526
|
+
location="us-central1",
|
527
|
+
application_id="example-application-1",
|
528
|
+
scope=gcp.apphub.ApplicationScopeArgs(
|
529
|
+
type="REGIONAL",
|
530
|
+
))
|
531
|
+
service_project = gcp.organizations.Project("service_project",
|
532
|
+
project_id="project-1",
|
533
|
+
name="Service Project",
|
534
|
+
org_id="123456789",
|
535
|
+
billing_account="000000-0000000-0000000-000000")
|
536
|
+
# Enable Compute API
|
537
|
+
compute_service_project = gcp.projects.Service("compute_service_project",
|
538
|
+
project=service_project.project_id,
|
539
|
+
service="compute.googleapis.com")
|
540
|
+
wait120s = time.index.Sleep("wait_120s", create_duration=120s)
|
541
|
+
service_project_attachment = gcp.apphub.ServiceProjectAttachment("service_project_attachment", service_project_attachment_id=service_project.project_id)
|
542
|
+
# VPC network
|
543
|
+
ilb_network = gcp.compute.Network("ilb_network",
|
544
|
+
name="l7-ilb-network",
|
545
|
+
project=service_project.project_id,
|
546
|
+
auto_create_subnetworks=False)
|
547
|
+
# backend subnet
|
548
|
+
ilb_subnet = gcp.compute.Subnetwork("ilb_subnet",
|
549
|
+
name="l7-ilb-subnet",
|
550
|
+
project=service_project.project_id,
|
551
|
+
ip_cidr_range="10.0.1.0/24",
|
552
|
+
region="us-central1",
|
553
|
+
network=ilb_network.id)
|
554
|
+
# health check
|
555
|
+
default = gcp.compute.HealthCheck("default",
|
556
|
+
name="l7-ilb-hc",
|
557
|
+
project=service_project.project_id,
|
558
|
+
check_interval_sec=1,
|
559
|
+
timeout_sec=1,
|
560
|
+
tcp_health_check=gcp.compute.HealthCheckTcpHealthCheckArgs(
|
561
|
+
port=80,
|
562
|
+
))
|
563
|
+
# backend service
|
564
|
+
backend = gcp.compute.RegionBackendService("backend",
|
565
|
+
name="l7-ilb-backend-subnet",
|
566
|
+
project=service_project.project_id,
|
567
|
+
region="us-central1",
|
568
|
+
health_checks=default.id)
|
569
|
+
# forwarding rule
|
570
|
+
forwarding_rule = gcp.compute.ForwardingRule("forwarding_rule",
|
571
|
+
name="l7-ilb-forwarding-rule",
|
572
|
+
project=service_project.project_id,
|
573
|
+
region="us-central1",
|
574
|
+
ip_version="IPV4",
|
575
|
+
load_balancing_scheme="INTERNAL",
|
576
|
+
all_ports=True,
|
577
|
+
backend_service=backend.id,
|
578
|
+
network=ilb_network.id,
|
579
|
+
subnetwork=ilb_subnet.id)
|
580
|
+
# discovered service block
|
581
|
+
catalog_service = gcp.apphub.get_discovered_service_output(location="us-central1",
|
582
|
+
service_uri=forwarding_rule.id.apply(lambda id: f"//compute.googleapis.com/{id}"))
|
583
|
+
wait120s_for_resource_ingestion = time.index.Sleep("wait_120s_for_resource_ingestion", create_duration=120s)
|
584
|
+
example = gcp.apphub.Service("example",
|
585
|
+
location="us-central1",
|
586
|
+
application_id=application.application_id,
|
587
|
+
service_id=forwarding_rule.name,
|
588
|
+
discovered_service=catalog_service.name,
|
589
|
+
display_name="Example Service Full",
|
590
|
+
description="Register service for testing",
|
591
|
+
attributes=gcp.apphub.ServiceAttributesArgs(
|
592
|
+
environment=gcp.apphub.ServiceAttributesEnvironmentArgs(
|
593
|
+
type="STAGING",
|
594
|
+
),
|
595
|
+
criticality=gcp.apphub.ServiceAttributesCriticalityArgs(
|
596
|
+
type="MISSION_CRITICAL",
|
597
|
+
),
|
598
|
+
business_owners=[gcp.apphub.ServiceAttributesBusinessOwnerArgs(
|
599
|
+
display_name="Alice",
|
600
|
+
email="alice@google.com",
|
601
|
+
)],
|
602
|
+
developer_owners=[gcp.apphub.ServiceAttributesDeveloperOwnerArgs(
|
603
|
+
display_name="Bob",
|
604
|
+
email="bob@google.com",
|
605
|
+
)],
|
606
|
+
operator_owners=[gcp.apphub.ServiceAttributesOperatorOwnerArgs(
|
607
|
+
display_name="Charlie",
|
608
|
+
email="charlie@google.com",
|
609
|
+
)],
|
610
|
+
))
|
611
|
+
```
|
612
|
+
<!--End PulumiCodeChooser -->
|
613
|
+
|
614
|
+
## Import
|
615
|
+
|
616
|
+
Service can be imported using any of these accepted formats:
|
617
|
+
|
618
|
+
* `projects/{{project}}/locations/{{location}}/applications/{{application_id}}/services/{{service_id}}`
|
619
|
+
|
620
|
+
* `{{project}}/{{location}}/{{application_id}}/{{service_id}}`
|
621
|
+
|
622
|
+
* `{{location}}/{{application_id}}/{{service_id}}`
|
623
|
+
|
624
|
+
When using the `pulumi import` command, Service can be imported using one of the formats above. For example:
|
625
|
+
|
626
|
+
```sh
|
627
|
+
$ pulumi import gcp:apphub/service:Service default projects/{{project}}/locations/{{location}}/applications/{{application_id}}/services/{{service_id}}
|
628
|
+
```
|
629
|
+
|
630
|
+
```sh
|
631
|
+
$ pulumi import gcp:apphub/service:Service default {{project}}/{{location}}/{{application_id}}/{{service_id}}
|
632
|
+
```
|
633
|
+
|
634
|
+
```sh
|
635
|
+
$ pulumi import gcp:apphub/service:Service default {{location}}/{{application_id}}/{{service_id}}
|
636
|
+
```
|
637
|
+
|
638
|
+
:param str resource_name: The name of the resource.
|
639
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
640
|
+
:param pulumi.Input[str] application_id: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
641
|
+
:param pulumi.Input[pulumi.InputType['ServiceAttributesArgs']] attributes: Consumer provided attributes.
|
642
|
+
Structure is documented below.
|
643
|
+
:param pulumi.Input[str] description: User-defined description of a Service.
|
644
|
+
:param pulumi.Input[str] discovered_service: Immutable. The resource name of the original discovered service.
|
645
|
+
:param pulumi.Input[str] display_name: User-defined name for the Service.
|
646
|
+
:param pulumi.Input[str] location: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
647
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
648
|
+
If it is not provided, the provider project is used.
|
649
|
+
:param pulumi.Input[str] service_id: The Service identifier.
|
650
|
+
|
651
|
+
|
652
|
+
- - -
|
653
|
+
"""
|
654
|
+
...
|
655
|
+
@overload
|
656
|
+
def __init__(__self__,
|
657
|
+
resource_name: str,
|
658
|
+
args: ServiceArgs,
|
659
|
+
opts: Optional[pulumi.ResourceOptions] = None):
|
660
|
+
"""
|
661
|
+
Service is a network/api interface that exposes some functionality to clients for consumption over the network. Service typically has one or more Workloads behind it. It registers identified service to the Application.
|
662
|
+
|
663
|
+
## Example Usage
|
664
|
+
|
665
|
+
### Apphub Service Basic
|
666
|
+
|
667
|
+
<!--Start PulumiCodeChooser -->
|
668
|
+
```python
|
669
|
+
import pulumi
|
670
|
+
import pulumi_gcp as gcp
|
671
|
+
import pulumi_time as time
|
672
|
+
|
673
|
+
application = gcp.apphub.Application("application",
|
674
|
+
location="us-central1",
|
675
|
+
application_id="example-application-1",
|
676
|
+
scope=gcp.apphub.ApplicationScopeArgs(
|
677
|
+
type="REGIONAL",
|
678
|
+
))
|
679
|
+
service_project = gcp.organizations.Project("service_project",
|
680
|
+
project_id="project-1",
|
681
|
+
name="Service Project",
|
682
|
+
org_id="123456789",
|
683
|
+
billing_account="000000-0000000-0000000-000000")
|
684
|
+
# Enable Compute API
|
685
|
+
compute_service_project = gcp.projects.Service("compute_service_project",
|
686
|
+
project=service_project.project_id,
|
687
|
+
service="compute.googleapis.com")
|
688
|
+
wait120s = time.index.Sleep("wait_120s", create_duration=120s)
|
689
|
+
service_project_attachment = gcp.apphub.ServiceProjectAttachment("service_project_attachment", service_project_attachment_id=service_project.project_id)
|
690
|
+
# VPC network
|
691
|
+
ilb_network = gcp.compute.Network("ilb_network",
|
692
|
+
name="l7-ilb-network",
|
693
|
+
project=service_project.project_id,
|
694
|
+
auto_create_subnetworks=False)
|
695
|
+
# backend subnet
|
696
|
+
ilb_subnet = gcp.compute.Subnetwork("ilb_subnet",
|
697
|
+
name="l7-ilb-subnet",
|
698
|
+
project=service_project.project_id,
|
699
|
+
ip_cidr_range="10.0.1.0/24",
|
700
|
+
region="us-central1",
|
701
|
+
network=ilb_network.id)
|
702
|
+
# health check
|
703
|
+
default = gcp.compute.HealthCheck("default",
|
704
|
+
name="l7-ilb-hc",
|
705
|
+
project=service_project.project_id,
|
706
|
+
check_interval_sec=1,
|
707
|
+
timeout_sec=1,
|
708
|
+
tcp_health_check=gcp.compute.HealthCheckTcpHealthCheckArgs(
|
709
|
+
port=80,
|
710
|
+
))
|
711
|
+
# backend service
|
712
|
+
backend = gcp.compute.RegionBackendService("backend",
|
713
|
+
name="l7-ilb-backend-subnet",
|
714
|
+
project=service_project.project_id,
|
715
|
+
region="us-central1",
|
716
|
+
health_checks=default.id)
|
717
|
+
# forwarding rule
|
718
|
+
forwarding_rule = gcp.compute.ForwardingRule("forwarding_rule",
|
719
|
+
name="l7-ilb-forwarding-rule",
|
720
|
+
project=service_project.project_id,
|
721
|
+
region="us-central1",
|
722
|
+
ip_version="IPV4",
|
723
|
+
load_balancing_scheme="INTERNAL",
|
724
|
+
all_ports=True,
|
725
|
+
backend_service=backend.id,
|
726
|
+
network=ilb_network.id,
|
727
|
+
subnetwork=ilb_subnet.id)
|
728
|
+
# discovered service block
|
729
|
+
catalog_service = gcp.apphub.get_discovered_service_output(location="us-central1",
|
730
|
+
service_uri=forwarding_rule.id.apply(lambda id: f"//compute.googleapis.com/{id}"))
|
731
|
+
wait120s_for_resource_ingestion = time.index.Sleep("wait_120s_for_resource_ingestion", create_duration=120s)
|
732
|
+
example = gcp.apphub.Service("example",
|
733
|
+
location="us-central1",
|
734
|
+
application_id=application.application_id,
|
735
|
+
service_id=forwarding_rule.name,
|
736
|
+
discovered_service=catalog_service.name)
|
737
|
+
```
|
738
|
+
<!--End PulumiCodeChooser -->
|
739
|
+
### Apphub Service Full
|
740
|
+
|
741
|
+
<!--Start PulumiCodeChooser -->
|
742
|
+
```python
|
743
|
+
import pulumi
|
744
|
+
import pulumi_gcp as gcp
|
745
|
+
import pulumi_time as time
|
746
|
+
|
747
|
+
application = gcp.apphub.Application("application",
|
748
|
+
location="us-central1",
|
749
|
+
application_id="example-application-1",
|
750
|
+
scope=gcp.apphub.ApplicationScopeArgs(
|
751
|
+
type="REGIONAL",
|
752
|
+
))
|
753
|
+
service_project = gcp.organizations.Project("service_project",
|
754
|
+
project_id="project-1",
|
755
|
+
name="Service Project",
|
756
|
+
org_id="123456789",
|
757
|
+
billing_account="000000-0000000-0000000-000000")
|
758
|
+
# Enable Compute API
|
759
|
+
compute_service_project = gcp.projects.Service("compute_service_project",
|
760
|
+
project=service_project.project_id,
|
761
|
+
service="compute.googleapis.com")
|
762
|
+
wait120s = time.index.Sleep("wait_120s", create_duration=120s)
|
763
|
+
service_project_attachment = gcp.apphub.ServiceProjectAttachment("service_project_attachment", service_project_attachment_id=service_project.project_id)
|
764
|
+
# VPC network
|
765
|
+
ilb_network = gcp.compute.Network("ilb_network",
|
766
|
+
name="l7-ilb-network",
|
767
|
+
project=service_project.project_id,
|
768
|
+
auto_create_subnetworks=False)
|
769
|
+
# backend subnet
|
770
|
+
ilb_subnet = gcp.compute.Subnetwork("ilb_subnet",
|
771
|
+
name="l7-ilb-subnet",
|
772
|
+
project=service_project.project_id,
|
773
|
+
ip_cidr_range="10.0.1.0/24",
|
774
|
+
region="us-central1",
|
775
|
+
network=ilb_network.id)
|
776
|
+
# health check
|
777
|
+
default = gcp.compute.HealthCheck("default",
|
778
|
+
name="l7-ilb-hc",
|
779
|
+
project=service_project.project_id,
|
780
|
+
check_interval_sec=1,
|
781
|
+
timeout_sec=1,
|
782
|
+
tcp_health_check=gcp.compute.HealthCheckTcpHealthCheckArgs(
|
783
|
+
port=80,
|
784
|
+
))
|
785
|
+
# backend service
|
786
|
+
backend = gcp.compute.RegionBackendService("backend",
|
787
|
+
name="l7-ilb-backend-subnet",
|
788
|
+
project=service_project.project_id,
|
789
|
+
region="us-central1",
|
790
|
+
health_checks=default.id)
|
791
|
+
# forwarding rule
|
792
|
+
forwarding_rule = gcp.compute.ForwardingRule("forwarding_rule",
|
793
|
+
name="l7-ilb-forwarding-rule",
|
794
|
+
project=service_project.project_id,
|
795
|
+
region="us-central1",
|
796
|
+
ip_version="IPV4",
|
797
|
+
load_balancing_scheme="INTERNAL",
|
798
|
+
all_ports=True,
|
799
|
+
backend_service=backend.id,
|
800
|
+
network=ilb_network.id,
|
801
|
+
subnetwork=ilb_subnet.id)
|
802
|
+
# discovered service block
|
803
|
+
catalog_service = gcp.apphub.get_discovered_service_output(location="us-central1",
|
804
|
+
service_uri=forwarding_rule.id.apply(lambda id: f"//compute.googleapis.com/{id}"))
|
805
|
+
wait120s_for_resource_ingestion = time.index.Sleep("wait_120s_for_resource_ingestion", create_duration=120s)
|
806
|
+
example = gcp.apphub.Service("example",
|
807
|
+
location="us-central1",
|
808
|
+
application_id=application.application_id,
|
809
|
+
service_id=forwarding_rule.name,
|
810
|
+
discovered_service=catalog_service.name,
|
811
|
+
display_name="Example Service Full",
|
812
|
+
description="Register service for testing",
|
813
|
+
attributes=gcp.apphub.ServiceAttributesArgs(
|
814
|
+
environment=gcp.apphub.ServiceAttributesEnvironmentArgs(
|
815
|
+
type="STAGING",
|
816
|
+
),
|
817
|
+
criticality=gcp.apphub.ServiceAttributesCriticalityArgs(
|
818
|
+
type="MISSION_CRITICAL",
|
819
|
+
),
|
820
|
+
business_owners=[gcp.apphub.ServiceAttributesBusinessOwnerArgs(
|
821
|
+
display_name="Alice",
|
822
|
+
email="alice@google.com",
|
823
|
+
)],
|
824
|
+
developer_owners=[gcp.apphub.ServiceAttributesDeveloperOwnerArgs(
|
825
|
+
display_name="Bob",
|
826
|
+
email="bob@google.com",
|
827
|
+
)],
|
828
|
+
operator_owners=[gcp.apphub.ServiceAttributesOperatorOwnerArgs(
|
829
|
+
display_name="Charlie",
|
830
|
+
email="charlie@google.com",
|
831
|
+
)],
|
832
|
+
))
|
833
|
+
```
|
834
|
+
<!--End PulumiCodeChooser -->
|
835
|
+
|
836
|
+
## Import
|
837
|
+
|
838
|
+
Service can be imported using any of these accepted formats:
|
839
|
+
|
840
|
+
* `projects/{{project}}/locations/{{location}}/applications/{{application_id}}/services/{{service_id}}`
|
841
|
+
|
842
|
+
* `{{project}}/{{location}}/{{application_id}}/{{service_id}}`
|
843
|
+
|
844
|
+
* `{{location}}/{{application_id}}/{{service_id}}`
|
845
|
+
|
846
|
+
When using the `pulumi import` command, Service can be imported using one of the formats above. For example:
|
847
|
+
|
848
|
+
```sh
|
849
|
+
$ pulumi import gcp:apphub/service:Service default projects/{{project}}/locations/{{location}}/applications/{{application_id}}/services/{{service_id}}
|
850
|
+
```
|
851
|
+
|
852
|
+
```sh
|
853
|
+
$ pulumi import gcp:apphub/service:Service default {{project}}/{{location}}/{{application_id}}/{{service_id}}
|
854
|
+
```
|
855
|
+
|
856
|
+
```sh
|
857
|
+
$ pulumi import gcp:apphub/service:Service default {{location}}/{{application_id}}/{{service_id}}
|
858
|
+
```
|
859
|
+
|
860
|
+
:param str resource_name: The name of the resource.
|
861
|
+
:param ServiceArgs args: The arguments to use to populate this resource's properties.
|
862
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
863
|
+
"""
|
864
|
+
...
|
865
|
+
def __init__(__self__, resource_name: str, *args, **kwargs):
|
866
|
+
resource_args, opts = _utilities.get_resource_args_opts(ServiceArgs, pulumi.ResourceOptions, *args, **kwargs)
|
867
|
+
if resource_args is not None:
|
868
|
+
__self__._internal_init(resource_name, opts, **resource_args.__dict__)
|
869
|
+
else:
|
870
|
+
__self__._internal_init(resource_name, *args, **kwargs)
|
871
|
+
|
872
|
+
def _internal_init(__self__,
|
873
|
+
resource_name: str,
|
874
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
875
|
+
application_id: Optional[pulumi.Input[str]] = None,
|
876
|
+
attributes: Optional[pulumi.Input[pulumi.InputType['ServiceAttributesArgs']]] = None,
|
877
|
+
description: Optional[pulumi.Input[str]] = None,
|
878
|
+
discovered_service: Optional[pulumi.Input[str]] = None,
|
879
|
+
display_name: Optional[pulumi.Input[str]] = None,
|
880
|
+
location: Optional[pulumi.Input[str]] = None,
|
881
|
+
project: Optional[pulumi.Input[str]] = None,
|
882
|
+
service_id: Optional[pulumi.Input[str]] = None,
|
883
|
+
__props__=None):
|
884
|
+
opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
|
885
|
+
if not isinstance(opts, pulumi.ResourceOptions):
|
886
|
+
raise TypeError('Expected resource options to be a ResourceOptions instance')
|
887
|
+
if opts.id is None:
|
888
|
+
if __props__ is not None:
|
889
|
+
raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
|
890
|
+
__props__ = ServiceArgs.__new__(ServiceArgs)
|
891
|
+
|
892
|
+
if application_id is None and not opts.urn:
|
893
|
+
raise TypeError("Missing required property 'application_id'")
|
894
|
+
__props__.__dict__["application_id"] = application_id
|
895
|
+
__props__.__dict__["attributes"] = attributes
|
896
|
+
__props__.__dict__["description"] = description
|
897
|
+
if discovered_service is None and not opts.urn:
|
898
|
+
raise TypeError("Missing required property 'discovered_service'")
|
899
|
+
__props__.__dict__["discovered_service"] = discovered_service
|
900
|
+
__props__.__dict__["display_name"] = display_name
|
901
|
+
if location is None and not opts.urn:
|
902
|
+
raise TypeError("Missing required property 'location'")
|
903
|
+
__props__.__dict__["location"] = location
|
904
|
+
__props__.__dict__["project"] = project
|
905
|
+
if service_id is None and not opts.urn:
|
906
|
+
raise TypeError("Missing required property 'service_id'")
|
907
|
+
__props__.__dict__["service_id"] = service_id
|
908
|
+
__props__.__dict__["create_time"] = None
|
909
|
+
__props__.__dict__["name"] = None
|
910
|
+
__props__.__dict__["service_properties"] = None
|
911
|
+
__props__.__dict__["service_references"] = None
|
912
|
+
__props__.__dict__["state"] = None
|
913
|
+
__props__.__dict__["uid"] = None
|
914
|
+
__props__.__dict__["update_time"] = None
|
915
|
+
super(Service, __self__).__init__(
|
916
|
+
'gcp:apphub/service:Service',
|
917
|
+
resource_name,
|
918
|
+
__props__,
|
919
|
+
opts)
|
920
|
+
|
921
|
+
@staticmethod
|
922
|
+
def get(resource_name: str,
|
923
|
+
id: pulumi.Input[str],
|
924
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
925
|
+
application_id: Optional[pulumi.Input[str]] = None,
|
926
|
+
attributes: Optional[pulumi.Input[pulumi.InputType['ServiceAttributesArgs']]] = None,
|
927
|
+
create_time: Optional[pulumi.Input[str]] = None,
|
928
|
+
description: Optional[pulumi.Input[str]] = None,
|
929
|
+
discovered_service: Optional[pulumi.Input[str]] = None,
|
930
|
+
display_name: Optional[pulumi.Input[str]] = None,
|
931
|
+
location: Optional[pulumi.Input[str]] = None,
|
932
|
+
name: Optional[pulumi.Input[str]] = None,
|
933
|
+
project: Optional[pulumi.Input[str]] = None,
|
934
|
+
service_id: Optional[pulumi.Input[str]] = None,
|
935
|
+
service_properties: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['ServiceServicePropertyArgs']]]]] = None,
|
936
|
+
service_references: Optional[pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['ServiceServiceReferenceArgs']]]]] = None,
|
937
|
+
state: Optional[pulumi.Input[str]] = None,
|
938
|
+
uid: Optional[pulumi.Input[str]] = None,
|
939
|
+
update_time: Optional[pulumi.Input[str]] = None) -> 'Service':
|
940
|
+
"""
|
941
|
+
Get an existing Service resource's state with the given name, id, and optional extra
|
942
|
+
properties used to qualify the lookup.
|
943
|
+
|
944
|
+
:param str resource_name: The unique name of the resulting resource.
|
945
|
+
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
|
946
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
947
|
+
:param pulumi.Input[str] application_id: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
948
|
+
:param pulumi.Input[pulumi.InputType['ServiceAttributesArgs']] attributes: Consumer provided attributes.
|
949
|
+
Structure is documented below.
|
950
|
+
:param pulumi.Input[str] create_time: Output only. Create time.
|
951
|
+
:param pulumi.Input[str] description: User-defined description of a Service.
|
952
|
+
:param pulumi.Input[str] discovered_service: Immutable. The resource name of the original discovered service.
|
953
|
+
:param pulumi.Input[str] display_name: User-defined name for the Service.
|
954
|
+
:param pulumi.Input[str] location: Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
955
|
+
:param pulumi.Input[str] name: Identifier. The resource name of a Service. Format:
|
956
|
+
"projects/{host-project-id}/locations/{location}/applications/{application-id}/services/{service-id}"
|
957
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
958
|
+
If it is not provided, the provider project is used.
|
959
|
+
:param pulumi.Input[str] service_id: The Service identifier.
|
960
|
+
|
961
|
+
|
962
|
+
- - -
|
963
|
+
:param pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['ServiceServicePropertyArgs']]]] service_properties: Properties of an underlying cloud resource that can comprise a Service.
|
964
|
+
Structure is documented below.
|
965
|
+
:param pulumi.Input[Sequence[pulumi.Input[pulumi.InputType['ServiceServiceReferenceArgs']]]] service_references: Reference to an underlying networking resource that can comprise a Service.
|
966
|
+
Structure is documented below.
|
967
|
+
:param pulumi.Input[str] state: Output only. Service state. Possible values: STATE_UNSPECIFIED CREATING ACTIVE DELETING DETACHED
|
968
|
+
:param pulumi.Input[str] uid: Output only. A universally unique identifier (UUID) for the `Service` in the UUID4
|
969
|
+
format.
|
970
|
+
:param pulumi.Input[str] update_time: Output only. Update time.
|
971
|
+
"""
|
972
|
+
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
|
973
|
+
|
974
|
+
__props__ = _ServiceState.__new__(_ServiceState)
|
975
|
+
|
976
|
+
__props__.__dict__["application_id"] = application_id
|
977
|
+
__props__.__dict__["attributes"] = attributes
|
978
|
+
__props__.__dict__["create_time"] = create_time
|
979
|
+
__props__.__dict__["description"] = description
|
980
|
+
__props__.__dict__["discovered_service"] = discovered_service
|
981
|
+
__props__.__dict__["display_name"] = display_name
|
982
|
+
__props__.__dict__["location"] = location
|
983
|
+
__props__.__dict__["name"] = name
|
984
|
+
__props__.__dict__["project"] = project
|
985
|
+
__props__.__dict__["service_id"] = service_id
|
986
|
+
__props__.__dict__["service_properties"] = service_properties
|
987
|
+
__props__.__dict__["service_references"] = service_references
|
988
|
+
__props__.__dict__["state"] = state
|
989
|
+
__props__.__dict__["uid"] = uid
|
990
|
+
__props__.__dict__["update_time"] = update_time
|
991
|
+
return Service(resource_name, opts=opts, __props__=__props__)
|
992
|
+
|
993
|
+
@property
|
994
|
+
@pulumi.getter(name="applicationId")
|
995
|
+
def application_id(self) -> pulumi.Output[str]:
|
996
|
+
"""
|
997
|
+
Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
998
|
+
"""
|
999
|
+
return pulumi.get(self, "application_id")
|
1000
|
+
|
1001
|
+
@property
|
1002
|
+
@pulumi.getter
|
1003
|
+
def attributes(self) -> pulumi.Output[Optional['outputs.ServiceAttributes']]:
|
1004
|
+
"""
|
1005
|
+
Consumer provided attributes.
|
1006
|
+
Structure is documented below.
|
1007
|
+
"""
|
1008
|
+
return pulumi.get(self, "attributes")
|
1009
|
+
|
1010
|
+
@property
|
1011
|
+
@pulumi.getter(name="createTime")
|
1012
|
+
def create_time(self) -> pulumi.Output[str]:
|
1013
|
+
"""
|
1014
|
+
Output only. Create time.
|
1015
|
+
"""
|
1016
|
+
return pulumi.get(self, "create_time")
|
1017
|
+
|
1018
|
+
@property
|
1019
|
+
@pulumi.getter
|
1020
|
+
def description(self) -> pulumi.Output[Optional[str]]:
|
1021
|
+
"""
|
1022
|
+
User-defined description of a Service.
|
1023
|
+
"""
|
1024
|
+
return pulumi.get(self, "description")
|
1025
|
+
|
1026
|
+
@property
|
1027
|
+
@pulumi.getter(name="discoveredService")
|
1028
|
+
def discovered_service(self) -> pulumi.Output[str]:
|
1029
|
+
"""
|
1030
|
+
Immutable. The resource name of the original discovered service.
|
1031
|
+
"""
|
1032
|
+
return pulumi.get(self, "discovered_service")
|
1033
|
+
|
1034
|
+
@property
|
1035
|
+
@pulumi.getter(name="displayName")
|
1036
|
+
def display_name(self) -> pulumi.Output[Optional[str]]:
|
1037
|
+
"""
|
1038
|
+
User-defined name for the Service.
|
1039
|
+
"""
|
1040
|
+
return pulumi.get(self, "display_name")
|
1041
|
+
|
1042
|
+
@property
|
1043
|
+
@pulumi.getter
|
1044
|
+
def location(self) -> pulumi.Output[str]:
|
1045
|
+
"""
|
1046
|
+
Part of `parent`. Full resource name of a parent Application. Example: projects/{HOST_PROJECT_ID}/locations/{LOCATION}/applications/{APPLICATION_ID}
|
1047
|
+
"""
|
1048
|
+
return pulumi.get(self, "location")
|
1049
|
+
|
1050
|
+
@property
|
1051
|
+
@pulumi.getter
|
1052
|
+
def name(self) -> pulumi.Output[str]:
|
1053
|
+
"""
|
1054
|
+
Identifier. The resource name of a Service. Format:
|
1055
|
+
"projects/{host-project-id}/locations/{location}/applications/{application-id}/services/{service-id}"
|
1056
|
+
"""
|
1057
|
+
return pulumi.get(self, "name")
|
1058
|
+
|
1059
|
+
@property
|
1060
|
+
@pulumi.getter
|
1061
|
+
def project(self) -> pulumi.Output[str]:
|
1062
|
+
"""
|
1063
|
+
The ID of the project in which the resource belongs.
|
1064
|
+
If it is not provided, the provider project is used.
|
1065
|
+
"""
|
1066
|
+
return pulumi.get(self, "project")
|
1067
|
+
|
1068
|
+
@property
|
1069
|
+
@pulumi.getter(name="serviceId")
|
1070
|
+
def service_id(self) -> pulumi.Output[str]:
|
1071
|
+
"""
|
1072
|
+
The Service identifier.
|
1073
|
+
|
1074
|
+
|
1075
|
+
- - -
|
1076
|
+
"""
|
1077
|
+
return pulumi.get(self, "service_id")
|
1078
|
+
|
1079
|
+
@property
|
1080
|
+
@pulumi.getter(name="serviceProperties")
|
1081
|
+
def service_properties(self) -> pulumi.Output[Sequence['outputs.ServiceServiceProperty']]:
|
1082
|
+
"""
|
1083
|
+
Properties of an underlying cloud resource that can comprise a Service.
|
1084
|
+
Structure is documented below.
|
1085
|
+
"""
|
1086
|
+
return pulumi.get(self, "service_properties")
|
1087
|
+
|
1088
|
+
@property
|
1089
|
+
@pulumi.getter(name="serviceReferences")
|
1090
|
+
def service_references(self) -> pulumi.Output[Sequence['outputs.ServiceServiceReference']]:
|
1091
|
+
"""
|
1092
|
+
Reference to an underlying networking resource that can comprise a Service.
|
1093
|
+
Structure is documented below.
|
1094
|
+
"""
|
1095
|
+
return pulumi.get(self, "service_references")
|
1096
|
+
|
1097
|
+
@property
|
1098
|
+
@pulumi.getter
|
1099
|
+
def state(self) -> pulumi.Output[str]:
|
1100
|
+
"""
|
1101
|
+
Output only. Service state. Possible values: STATE_UNSPECIFIED CREATING ACTIVE DELETING DETACHED
|
1102
|
+
"""
|
1103
|
+
return pulumi.get(self, "state")
|
1104
|
+
|
1105
|
+
@property
|
1106
|
+
@pulumi.getter
|
1107
|
+
def uid(self) -> pulumi.Output[str]:
|
1108
|
+
"""
|
1109
|
+
Output only. A universally unique identifier (UUID) for the `Service` in the UUID4
|
1110
|
+
format.
|
1111
|
+
"""
|
1112
|
+
return pulumi.get(self, "uid")
|
1113
|
+
|
1114
|
+
@property
|
1115
|
+
@pulumi.getter(name="updateTime")
|
1116
|
+
def update_time(self) -> pulumi.Output[str]:
|
1117
|
+
"""
|
1118
|
+
Output only. Update time.
|
1119
|
+
"""
|
1120
|
+
return pulumi.get(self, "update_time")
|
1121
|
+
|