pulumi-gcp 8.17.0a1738274430__py3-none-any.whl → 8.17.0a1738349438__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 +91 -0
- pulumi_gcp/alloydb/cluster.py +75 -7
- pulumi_gcp/apigee/_inputs.py +91 -0
- pulumi_gcp/apigee/endpoint_attachment.py +0 -64
- pulumi_gcp/apigee/environment.py +54 -0
- pulumi_gcp/apigee/outputs.py +54 -0
- pulumi_gcp/apihub/__init__.py +10 -0
- pulumi_gcp/apihub/_inputs.py +154 -0
- pulumi_gcp/apihub/api_hub_instance.py +784 -0
- pulumi_gcp/apihub/outputs.py +124 -0
- pulumi_gcp/chronicle/__init__.py +1 -0
- pulumi_gcp/chronicle/_inputs.py +124 -0
- pulumi_gcp/chronicle/outputs.py +112 -0
- pulumi_gcp/chronicle/retrohunt.py +645 -0
- pulumi_gcp/cloudrunv2/_inputs.py +197 -0
- pulumi_gcp/cloudrunv2/get_service.py +12 -1
- pulumi_gcp/cloudrunv2/outputs.py +256 -0
- pulumi_gcp/cloudrunv2/service.py +159 -0
- pulumi_gcp/colab/__init__.py +5 -0
- pulumi_gcp/colab/_inputs.py +131 -0
- pulumi_gcp/colab/get_runtime_template_iam_policy.py +182 -0
- pulumi_gcp/colab/outputs.py +92 -0
- pulumi_gcp/colab/runtime.py +696 -0
- pulumi_gcp/colab/runtime_template_iam_binding.py +828 -0
- pulumi_gcp/colab/runtime_template_iam_member.py +828 -0
- pulumi_gcp/colab/runtime_template_iam_policy.py +667 -0
- pulumi_gcp/compute/__init__.py +4 -0
- pulumi_gcp/compute/_inputs.py +526 -0
- pulumi_gcp/compute/firewall_policy_rule.py +104 -22
- pulumi_gcp/compute/firewall_policy_with_rules.py +114 -42
- pulumi_gcp/compute/get_instance_template_iam_policy.py +159 -0
- pulumi_gcp/compute/instance_template_iam_binding.py +998 -0
- pulumi_gcp/compute/instance_template_iam_member.py +998 -0
- pulumi_gcp/compute/instance_template_iam_policy.py +817 -0
- pulumi_gcp/compute/interconnect_attachment.py +189 -2
- pulumi_gcp/compute/network_firewall_policy_rule.py +122 -10
- pulumi_gcp/compute/network_firewall_policy_with_rules.py +116 -44
- pulumi_gcp/compute/outputs.py +352 -0
- pulumi_gcp/compute/project_metadata_item.py +12 -0
- pulumi_gcp/compute/public_advertised_prefix.py +87 -0
- pulumi_gcp/compute/region_network_firewall_policy_rule.py +130 -10
- pulumi_gcp/compute/region_network_firewall_policy_with_rules.py +104 -32
- pulumi_gcp/compute/router_peer.py +115 -3
- pulumi_gcp/config/__init__.pyi +2 -0
- pulumi_gcp/config/vars.py +4 -0
- pulumi_gcp/filestore/get_instance.py +12 -1
- pulumi_gcp/filestore/instance.py +75 -0
- pulumi_gcp/gemini/code_repository_index.py +29 -33
- pulumi_gcp/gemini/get_repository_group_iam_policy.py +28 -2
- pulumi_gcp/gemini/repository_group.py +76 -26
- pulumi_gcp/gemini/repository_group_iam_binding.py +258 -0
- pulumi_gcp/gemini/repository_group_iam_member.py +258 -0
- pulumi_gcp/gemini/repository_group_iam_policy.py +258 -0
- pulumi_gcp/kms/__init__.py +1 -0
- pulumi_gcp/kms/get_key_handles.py +172 -0
- pulumi_gcp/kms/outputs.py +45 -0
- pulumi_gcp/networksecurity/_inputs.py +72 -0
- pulumi_gcp/networksecurity/outputs.py +76 -0
- pulumi_gcp/networksecurity/security_profile.py +233 -7
- pulumi_gcp/networksecurity/security_profile_group.py +218 -0
- pulumi_gcp/organizations/__init__.py +1 -0
- pulumi_gcp/organizations/get_s.py +128 -0
- pulumi_gcp/organizations/outputs.py +63 -0
- pulumi_gcp/parametermanager/__init__.py +3 -0
- pulumi_gcp/parametermanager/get_parameter.py +211 -0
- pulumi_gcp/parametermanager/get_regional_parameters.py +157 -0
- pulumi_gcp/parametermanager/outputs.py +210 -0
- pulumi_gcp/parametermanager/parameter_version.py +496 -0
- pulumi_gcp/parametermanager/regional_parameter_version.py +10 -38
- pulumi_gcp/provider.py +20 -0
- pulumi_gcp/pubsub/_inputs.py +213 -1
- pulumi_gcp/pubsub/outputs.py +278 -2
- pulumi_gcp/pubsub/topic.py +42 -0
- pulumi_gcp/pulumi-plugin.json +1 -1
- pulumi_gcp/redis/__init__.py +1 -0
- pulumi_gcp/redis/_inputs.py +342 -6
- pulumi_gcp/redis/cluster.py +223 -102
- pulumi_gcp/redis/cluster_user_created_connections.py +845 -0
- pulumi_gcp/redis/outputs.py +268 -4
- {pulumi_gcp-8.17.0a1738274430.dist-info → pulumi_gcp-8.17.0a1738349438.dist-info}/METADATA +1 -1
- {pulumi_gcp-8.17.0a1738274430.dist-info → pulumi_gcp-8.17.0a1738349438.dist-info}/RECORD +83 -63
- {pulumi_gcp-8.17.0a1738274430.dist-info → pulumi_gcp-8.17.0a1738349438.dist-info}/WHEEL +0 -0
- {pulumi_gcp-8.17.0a1738274430.dist-info → pulumi_gcp-8.17.0a1738349438.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,667 @@
|
|
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 sys
|
8
|
+
import pulumi
|
9
|
+
import pulumi.runtime
|
10
|
+
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
15
|
+
from .. import _utilities
|
16
|
+
|
17
|
+
__all__ = ['RuntimeTemplateIamPolicyArgs', 'RuntimeTemplateIamPolicy']
|
18
|
+
|
19
|
+
@pulumi.input_type
|
20
|
+
class RuntimeTemplateIamPolicyArgs:
|
21
|
+
def __init__(__self__, *,
|
22
|
+
policy_data: pulumi.Input[str],
|
23
|
+
runtime_template: pulumi.Input[str],
|
24
|
+
location: Optional[pulumi.Input[str]] = None,
|
25
|
+
project: Optional[pulumi.Input[str]] = None):
|
26
|
+
"""
|
27
|
+
The set of arguments for constructing a RuntimeTemplateIamPolicy resource.
|
28
|
+
:param pulumi.Input[str] policy_data: The policy data generated by
|
29
|
+
a `organizations_get_iam_policy` data source.
|
30
|
+
:param pulumi.Input[str] runtime_template: Used to find the parent resource to bind the IAM policy to
|
31
|
+
:param pulumi.Input[str] location: The location for the resource: https://cloud.google.com/colab/docs/locations Used to find the parent resource to bind the IAM policy to. If not specified,
|
32
|
+
the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
|
33
|
+
location is specified, it is taken from the provider configuration.
|
34
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
35
|
+
If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
|
36
|
+
"""
|
37
|
+
pulumi.set(__self__, "policy_data", policy_data)
|
38
|
+
pulumi.set(__self__, "runtime_template", runtime_template)
|
39
|
+
if location is not None:
|
40
|
+
pulumi.set(__self__, "location", location)
|
41
|
+
if project is not None:
|
42
|
+
pulumi.set(__self__, "project", project)
|
43
|
+
|
44
|
+
@property
|
45
|
+
@pulumi.getter(name="policyData")
|
46
|
+
def policy_data(self) -> pulumi.Input[str]:
|
47
|
+
"""
|
48
|
+
The policy data generated by
|
49
|
+
a `organizations_get_iam_policy` data source.
|
50
|
+
"""
|
51
|
+
return pulumi.get(self, "policy_data")
|
52
|
+
|
53
|
+
@policy_data.setter
|
54
|
+
def policy_data(self, value: pulumi.Input[str]):
|
55
|
+
pulumi.set(self, "policy_data", value)
|
56
|
+
|
57
|
+
@property
|
58
|
+
@pulumi.getter(name="runtimeTemplate")
|
59
|
+
def runtime_template(self) -> pulumi.Input[str]:
|
60
|
+
"""
|
61
|
+
Used to find the parent resource to bind the IAM policy to
|
62
|
+
"""
|
63
|
+
return pulumi.get(self, "runtime_template")
|
64
|
+
|
65
|
+
@runtime_template.setter
|
66
|
+
def runtime_template(self, value: pulumi.Input[str]):
|
67
|
+
pulumi.set(self, "runtime_template", value)
|
68
|
+
|
69
|
+
@property
|
70
|
+
@pulumi.getter
|
71
|
+
def location(self) -> Optional[pulumi.Input[str]]:
|
72
|
+
"""
|
73
|
+
The location for the resource: https://cloud.google.com/colab/docs/locations Used to find the parent resource to bind the IAM policy to. If not specified,
|
74
|
+
the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
|
75
|
+
location is specified, it is taken from the provider configuration.
|
76
|
+
"""
|
77
|
+
return pulumi.get(self, "location")
|
78
|
+
|
79
|
+
@location.setter
|
80
|
+
def location(self, value: Optional[pulumi.Input[str]]):
|
81
|
+
pulumi.set(self, "location", value)
|
82
|
+
|
83
|
+
@property
|
84
|
+
@pulumi.getter
|
85
|
+
def project(self) -> Optional[pulumi.Input[str]]:
|
86
|
+
"""
|
87
|
+
The ID of the project in which the resource belongs.
|
88
|
+
If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
|
89
|
+
"""
|
90
|
+
return pulumi.get(self, "project")
|
91
|
+
|
92
|
+
@project.setter
|
93
|
+
def project(self, value: Optional[pulumi.Input[str]]):
|
94
|
+
pulumi.set(self, "project", value)
|
95
|
+
|
96
|
+
|
97
|
+
@pulumi.input_type
|
98
|
+
class _RuntimeTemplateIamPolicyState:
|
99
|
+
def __init__(__self__, *,
|
100
|
+
etag: Optional[pulumi.Input[str]] = None,
|
101
|
+
location: Optional[pulumi.Input[str]] = None,
|
102
|
+
policy_data: Optional[pulumi.Input[str]] = None,
|
103
|
+
project: Optional[pulumi.Input[str]] = None,
|
104
|
+
runtime_template: Optional[pulumi.Input[str]] = None):
|
105
|
+
"""
|
106
|
+
Input properties used for looking up and filtering RuntimeTemplateIamPolicy resources.
|
107
|
+
:param pulumi.Input[str] etag: (Computed) The etag of the IAM policy.
|
108
|
+
:param pulumi.Input[str] location: The location for the resource: https://cloud.google.com/colab/docs/locations Used to find the parent resource to bind the IAM policy to. If not specified,
|
109
|
+
the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
|
110
|
+
location is specified, it is taken from the provider configuration.
|
111
|
+
:param pulumi.Input[str] policy_data: The policy data generated by
|
112
|
+
a `organizations_get_iam_policy` data source.
|
113
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
114
|
+
If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
|
115
|
+
:param pulumi.Input[str] runtime_template: Used to find the parent resource to bind the IAM policy to
|
116
|
+
"""
|
117
|
+
if etag is not None:
|
118
|
+
pulumi.set(__self__, "etag", etag)
|
119
|
+
if location is not None:
|
120
|
+
pulumi.set(__self__, "location", location)
|
121
|
+
if policy_data is not None:
|
122
|
+
pulumi.set(__self__, "policy_data", policy_data)
|
123
|
+
if project is not None:
|
124
|
+
pulumi.set(__self__, "project", project)
|
125
|
+
if runtime_template is not None:
|
126
|
+
pulumi.set(__self__, "runtime_template", runtime_template)
|
127
|
+
|
128
|
+
@property
|
129
|
+
@pulumi.getter
|
130
|
+
def etag(self) -> Optional[pulumi.Input[str]]:
|
131
|
+
"""
|
132
|
+
(Computed) The etag of the IAM policy.
|
133
|
+
"""
|
134
|
+
return pulumi.get(self, "etag")
|
135
|
+
|
136
|
+
@etag.setter
|
137
|
+
def etag(self, value: Optional[pulumi.Input[str]]):
|
138
|
+
pulumi.set(self, "etag", value)
|
139
|
+
|
140
|
+
@property
|
141
|
+
@pulumi.getter
|
142
|
+
def location(self) -> Optional[pulumi.Input[str]]:
|
143
|
+
"""
|
144
|
+
The location for the resource: https://cloud.google.com/colab/docs/locations Used to find the parent resource to bind the IAM policy to. If not specified,
|
145
|
+
the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
|
146
|
+
location is specified, it is taken from the provider configuration.
|
147
|
+
"""
|
148
|
+
return pulumi.get(self, "location")
|
149
|
+
|
150
|
+
@location.setter
|
151
|
+
def location(self, value: Optional[pulumi.Input[str]]):
|
152
|
+
pulumi.set(self, "location", value)
|
153
|
+
|
154
|
+
@property
|
155
|
+
@pulumi.getter(name="policyData")
|
156
|
+
def policy_data(self) -> Optional[pulumi.Input[str]]:
|
157
|
+
"""
|
158
|
+
The policy data generated by
|
159
|
+
a `organizations_get_iam_policy` data source.
|
160
|
+
"""
|
161
|
+
return pulumi.get(self, "policy_data")
|
162
|
+
|
163
|
+
@policy_data.setter
|
164
|
+
def policy_data(self, value: Optional[pulumi.Input[str]]):
|
165
|
+
pulumi.set(self, "policy_data", value)
|
166
|
+
|
167
|
+
@property
|
168
|
+
@pulumi.getter
|
169
|
+
def project(self) -> Optional[pulumi.Input[str]]:
|
170
|
+
"""
|
171
|
+
The ID of the project in which the resource belongs.
|
172
|
+
If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
|
173
|
+
"""
|
174
|
+
return pulumi.get(self, "project")
|
175
|
+
|
176
|
+
@project.setter
|
177
|
+
def project(self, value: Optional[pulumi.Input[str]]):
|
178
|
+
pulumi.set(self, "project", value)
|
179
|
+
|
180
|
+
@property
|
181
|
+
@pulumi.getter(name="runtimeTemplate")
|
182
|
+
def runtime_template(self) -> Optional[pulumi.Input[str]]:
|
183
|
+
"""
|
184
|
+
Used to find the parent resource to bind the IAM policy to
|
185
|
+
"""
|
186
|
+
return pulumi.get(self, "runtime_template")
|
187
|
+
|
188
|
+
@runtime_template.setter
|
189
|
+
def runtime_template(self, value: Optional[pulumi.Input[str]]):
|
190
|
+
pulumi.set(self, "runtime_template", value)
|
191
|
+
|
192
|
+
|
193
|
+
class RuntimeTemplateIamPolicy(pulumi.CustomResource):
|
194
|
+
@overload
|
195
|
+
def __init__(__self__,
|
196
|
+
resource_name: str,
|
197
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
198
|
+
location: Optional[pulumi.Input[str]] = None,
|
199
|
+
policy_data: Optional[pulumi.Input[str]] = None,
|
200
|
+
project: Optional[pulumi.Input[str]] = None,
|
201
|
+
runtime_template: Optional[pulumi.Input[str]] = None,
|
202
|
+
__props__=None):
|
203
|
+
"""
|
204
|
+
Three different resources help you manage your IAM policy for Colab Enterprise RuntimeTemplate. Each of these resources serves a different use case:
|
205
|
+
|
206
|
+
* `colab.RuntimeTemplateIamPolicy`: Authoritative. Sets the IAM policy for the runtimetemplate and replaces any existing policy already attached.
|
207
|
+
* `colab.RuntimeTemplateIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the runtimetemplate are preserved.
|
208
|
+
* `colab.RuntimeTemplateIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the runtimetemplate are preserved.
|
209
|
+
|
210
|
+
A data source can be used to retrieve policy data in advent you do not need creation
|
211
|
+
|
212
|
+
* `colab.RuntimeTemplateIamPolicy`: Retrieves the IAM policy for the runtimetemplate
|
213
|
+
|
214
|
+
> **Note:** `colab.RuntimeTemplateIamPolicy` **cannot** be used in conjunction with `colab.RuntimeTemplateIamBinding` and `colab.RuntimeTemplateIamMember` or they will fight over what your policy should be.
|
215
|
+
|
216
|
+
> **Note:** `colab.RuntimeTemplateIamBinding` resources **can be** used in conjunction with `colab.RuntimeTemplateIamMember` resources **only if** they do not grant privilege to the same role.
|
217
|
+
|
218
|
+
## colab.RuntimeTemplateIamPolicy
|
219
|
+
|
220
|
+
```python
|
221
|
+
import pulumi
|
222
|
+
import pulumi_gcp as gcp
|
223
|
+
|
224
|
+
admin = gcp.organizations.get_iam_policy(bindings=[{
|
225
|
+
"role": "roles/viewer",
|
226
|
+
"members": ["user:jane@example.com"],
|
227
|
+
}])
|
228
|
+
policy = gcp.colab.RuntimeTemplateIamPolicy("policy",
|
229
|
+
project=runtime_template["project"],
|
230
|
+
location=runtime_template["location"],
|
231
|
+
runtime_template=runtime_template["name"],
|
232
|
+
policy_data=admin.policy_data)
|
233
|
+
```
|
234
|
+
|
235
|
+
## colab.RuntimeTemplateIamBinding
|
236
|
+
|
237
|
+
```python
|
238
|
+
import pulumi
|
239
|
+
import pulumi_gcp as gcp
|
240
|
+
|
241
|
+
binding = gcp.colab.RuntimeTemplateIamBinding("binding",
|
242
|
+
project=runtime_template["project"],
|
243
|
+
location=runtime_template["location"],
|
244
|
+
runtime_template=runtime_template["name"],
|
245
|
+
role="roles/viewer",
|
246
|
+
members=["user:jane@example.com"])
|
247
|
+
```
|
248
|
+
|
249
|
+
## colab.RuntimeTemplateIamMember
|
250
|
+
|
251
|
+
```python
|
252
|
+
import pulumi
|
253
|
+
import pulumi_gcp as gcp
|
254
|
+
|
255
|
+
member = gcp.colab.RuntimeTemplateIamMember("member",
|
256
|
+
project=runtime_template["project"],
|
257
|
+
location=runtime_template["location"],
|
258
|
+
runtime_template=runtime_template["name"],
|
259
|
+
role="roles/viewer",
|
260
|
+
member="user:jane@example.com")
|
261
|
+
```
|
262
|
+
|
263
|
+
## This resource supports User Project Overrides.
|
264
|
+
|
265
|
+
-
|
266
|
+
|
267
|
+
# IAM policy for Colab Enterprise RuntimeTemplate
|
268
|
+
Three different resources help you manage your IAM policy for Colab Enterprise RuntimeTemplate. Each of these resources serves a different use case:
|
269
|
+
|
270
|
+
* `colab.RuntimeTemplateIamPolicy`: Authoritative. Sets the IAM policy for the runtimetemplate and replaces any existing policy already attached.
|
271
|
+
* `colab.RuntimeTemplateIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the runtimetemplate are preserved.
|
272
|
+
* `colab.RuntimeTemplateIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the runtimetemplate are preserved.
|
273
|
+
|
274
|
+
A data source can be used to retrieve policy data in advent you do not need creation
|
275
|
+
|
276
|
+
* `colab.RuntimeTemplateIamPolicy`: Retrieves the IAM policy for the runtimetemplate
|
277
|
+
|
278
|
+
> **Note:** `colab.RuntimeTemplateIamPolicy` **cannot** be used in conjunction with `colab.RuntimeTemplateIamBinding` and `colab.RuntimeTemplateIamMember` or they will fight over what your policy should be.
|
279
|
+
|
280
|
+
> **Note:** `colab.RuntimeTemplateIamBinding` resources **can be** used in conjunction with `colab.RuntimeTemplateIamMember` resources **only if** they do not grant privilege to the same role.
|
281
|
+
|
282
|
+
## colab.RuntimeTemplateIamPolicy
|
283
|
+
|
284
|
+
```python
|
285
|
+
import pulumi
|
286
|
+
import pulumi_gcp as gcp
|
287
|
+
|
288
|
+
admin = gcp.organizations.get_iam_policy(bindings=[{
|
289
|
+
"role": "roles/viewer",
|
290
|
+
"members": ["user:jane@example.com"],
|
291
|
+
}])
|
292
|
+
policy = gcp.colab.RuntimeTemplateIamPolicy("policy",
|
293
|
+
project=runtime_template["project"],
|
294
|
+
location=runtime_template["location"],
|
295
|
+
runtime_template=runtime_template["name"],
|
296
|
+
policy_data=admin.policy_data)
|
297
|
+
```
|
298
|
+
|
299
|
+
## colab.RuntimeTemplateIamBinding
|
300
|
+
|
301
|
+
```python
|
302
|
+
import pulumi
|
303
|
+
import pulumi_gcp as gcp
|
304
|
+
|
305
|
+
binding = gcp.colab.RuntimeTemplateIamBinding("binding",
|
306
|
+
project=runtime_template["project"],
|
307
|
+
location=runtime_template["location"],
|
308
|
+
runtime_template=runtime_template["name"],
|
309
|
+
role="roles/viewer",
|
310
|
+
members=["user:jane@example.com"])
|
311
|
+
```
|
312
|
+
|
313
|
+
## colab.RuntimeTemplateIamMember
|
314
|
+
|
315
|
+
```python
|
316
|
+
import pulumi
|
317
|
+
import pulumi_gcp as gcp
|
318
|
+
|
319
|
+
member = gcp.colab.RuntimeTemplateIamMember("member",
|
320
|
+
project=runtime_template["project"],
|
321
|
+
location=runtime_template["location"],
|
322
|
+
runtime_template=runtime_template["name"],
|
323
|
+
role="roles/viewer",
|
324
|
+
member="user:jane@example.com")
|
325
|
+
```
|
326
|
+
|
327
|
+
## Import
|
328
|
+
|
329
|
+
For all import syntaxes, the "resource in question" can take any of the following forms:
|
330
|
+
|
331
|
+
* projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}}
|
332
|
+
|
333
|
+
* {{project}}/{{location}}/{{runtime_template}}
|
334
|
+
|
335
|
+
* {{location}}/{{runtime_template}}
|
336
|
+
|
337
|
+
* {{runtime_template}}
|
338
|
+
|
339
|
+
Any variables not passed in the import command will be taken from the provider configuration.
|
340
|
+
|
341
|
+
Colab Enterprise runtimetemplate IAM resources can be imported using the resource identifiers, role, and member.
|
342
|
+
|
343
|
+
IAM member imports use space-delimited identifiers: the resource in question, the role, and the member identity, e.g.
|
344
|
+
|
345
|
+
```sh
|
346
|
+
$ pulumi import gcp:colab/runtimeTemplateIamPolicy:RuntimeTemplateIamPolicy editor "projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}} roles/viewer user:jane@example.com"
|
347
|
+
```
|
348
|
+
|
349
|
+
IAM binding imports use space-delimited identifiers: the resource in question and the role, e.g.
|
350
|
+
|
351
|
+
```sh
|
352
|
+
$ pulumi import gcp:colab/runtimeTemplateIamPolicy:RuntimeTemplateIamPolicy editor "projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}} roles/viewer"
|
353
|
+
```
|
354
|
+
|
355
|
+
IAM policy imports use the identifier of the resource in question, e.g.
|
356
|
+
|
357
|
+
```sh
|
358
|
+
$ pulumi import gcp:colab/runtimeTemplateIamPolicy:RuntimeTemplateIamPolicy editor projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}}
|
359
|
+
```
|
360
|
+
|
361
|
+
-> **Custom Roles** If you're importing a IAM resource with a custom role, make sure to use the
|
362
|
+
|
363
|
+
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
|
364
|
+
|
365
|
+
:param str resource_name: The name of the resource.
|
366
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
367
|
+
:param pulumi.Input[str] location: The location for the resource: https://cloud.google.com/colab/docs/locations Used to find the parent resource to bind the IAM policy to. If not specified,
|
368
|
+
the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
|
369
|
+
location is specified, it is taken from the provider configuration.
|
370
|
+
:param pulumi.Input[str] policy_data: The policy data generated by
|
371
|
+
a `organizations_get_iam_policy` data source.
|
372
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
373
|
+
If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
|
374
|
+
:param pulumi.Input[str] runtime_template: Used to find the parent resource to bind the IAM policy to
|
375
|
+
"""
|
376
|
+
...
|
377
|
+
@overload
|
378
|
+
def __init__(__self__,
|
379
|
+
resource_name: str,
|
380
|
+
args: RuntimeTemplateIamPolicyArgs,
|
381
|
+
opts: Optional[pulumi.ResourceOptions] = None):
|
382
|
+
"""
|
383
|
+
Three different resources help you manage your IAM policy for Colab Enterprise RuntimeTemplate. Each of these resources serves a different use case:
|
384
|
+
|
385
|
+
* `colab.RuntimeTemplateIamPolicy`: Authoritative. Sets the IAM policy for the runtimetemplate and replaces any existing policy already attached.
|
386
|
+
* `colab.RuntimeTemplateIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the runtimetemplate are preserved.
|
387
|
+
* `colab.RuntimeTemplateIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the runtimetemplate are preserved.
|
388
|
+
|
389
|
+
A data source can be used to retrieve policy data in advent you do not need creation
|
390
|
+
|
391
|
+
* `colab.RuntimeTemplateIamPolicy`: Retrieves the IAM policy for the runtimetemplate
|
392
|
+
|
393
|
+
> **Note:** `colab.RuntimeTemplateIamPolicy` **cannot** be used in conjunction with `colab.RuntimeTemplateIamBinding` and `colab.RuntimeTemplateIamMember` or they will fight over what your policy should be.
|
394
|
+
|
395
|
+
> **Note:** `colab.RuntimeTemplateIamBinding` resources **can be** used in conjunction with `colab.RuntimeTemplateIamMember` resources **only if** they do not grant privilege to the same role.
|
396
|
+
|
397
|
+
## colab.RuntimeTemplateIamPolicy
|
398
|
+
|
399
|
+
```python
|
400
|
+
import pulumi
|
401
|
+
import pulumi_gcp as gcp
|
402
|
+
|
403
|
+
admin = gcp.organizations.get_iam_policy(bindings=[{
|
404
|
+
"role": "roles/viewer",
|
405
|
+
"members": ["user:jane@example.com"],
|
406
|
+
}])
|
407
|
+
policy = gcp.colab.RuntimeTemplateIamPolicy("policy",
|
408
|
+
project=runtime_template["project"],
|
409
|
+
location=runtime_template["location"],
|
410
|
+
runtime_template=runtime_template["name"],
|
411
|
+
policy_data=admin.policy_data)
|
412
|
+
```
|
413
|
+
|
414
|
+
## colab.RuntimeTemplateIamBinding
|
415
|
+
|
416
|
+
```python
|
417
|
+
import pulumi
|
418
|
+
import pulumi_gcp as gcp
|
419
|
+
|
420
|
+
binding = gcp.colab.RuntimeTemplateIamBinding("binding",
|
421
|
+
project=runtime_template["project"],
|
422
|
+
location=runtime_template["location"],
|
423
|
+
runtime_template=runtime_template["name"],
|
424
|
+
role="roles/viewer",
|
425
|
+
members=["user:jane@example.com"])
|
426
|
+
```
|
427
|
+
|
428
|
+
## colab.RuntimeTemplateIamMember
|
429
|
+
|
430
|
+
```python
|
431
|
+
import pulumi
|
432
|
+
import pulumi_gcp as gcp
|
433
|
+
|
434
|
+
member = gcp.colab.RuntimeTemplateIamMember("member",
|
435
|
+
project=runtime_template["project"],
|
436
|
+
location=runtime_template["location"],
|
437
|
+
runtime_template=runtime_template["name"],
|
438
|
+
role="roles/viewer",
|
439
|
+
member="user:jane@example.com")
|
440
|
+
```
|
441
|
+
|
442
|
+
## This resource supports User Project Overrides.
|
443
|
+
|
444
|
+
-
|
445
|
+
|
446
|
+
# IAM policy for Colab Enterprise RuntimeTemplate
|
447
|
+
Three different resources help you manage your IAM policy for Colab Enterprise RuntimeTemplate. Each of these resources serves a different use case:
|
448
|
+
|
449
|
+
* `colab.RuntimeTemplateIamPolicy`: Authoritative. Sets the IAM policy for the runtimetemplate and replaces any existing policy already attached.
|
450
|
+
* `colab.RuntimeTemplateIamBinding`: Authoritative for a given role. Updates the IAM policy to grant a role to a list of members. Other roles within the IAM policy for the runtimetemplate are preserved.
|
451
|
+
* `colab.RuntimeTemplateIamMember`: Non-authoritative. Updates the IAM policy to grant a role to a new member. Other members for the role for the runtimetemplate are preserved.
|
452
|
+
|
453
|
+
A data source can be used to retrieve policy data in advent you do not need creation
|
454
|
+
|
455
|
+
* `colab.RuntimeTemplateIamPolicy`: Retrieves the IAM policy for the runtimetemplate
|
456
|
+
|
457
|
+
> **Note:** `colab.RuntimeTemplateIamPolicy` **cannot** be used in conjunction with `colab.RuntimeTemplateIamBinding` and `colab.RuntimeTemplateIamMember` or they will fight over what your policy should be.
|
458
|
+
|
459
|
+
> **Note:** `colab.RuntimeTemplateIamBinding` resources **can be** used in conjunction with `colab.RuntimeTemplateIamMember` resources **only if** they do not grant privilege to the same role.
|
460
|
+
|
461
|
+
## colab.RuntimeTemplateIamPolicy
|
462
|
+
|
463
|
+
```python
|
464
|
+
import pulumi
|
465
|
+
import pulumi_gcp as gcp
|
466
|
+
|
467
|
+
admin = gcp.organizations.get_iam_policy(bindings=[{
|
468
|
+
"role": "roles/viewer",
|
469
|
+
"members": ["user:jane@example.com"],
|
470
|
+
}])
|
471
|
+
policy = gcp.colab.RuntimeTemplateIamPolicy("policy",
|
472
|
+
project=runtime_template["project"],
|
473
|
+
location=runtime_template["location"],
|
474
|
+
runtime_template=runtime_template["name"],
|
475
|
+
policy_data=admin.policy_data)
|
476
|
+
```
|
477
|
+
|
478
|
+
## colab.RuntimeTemplateIamBinding
|
479
|
+
|
480
|
+
```python
|
481
|
+
import pulumi
|
482
|
+
import pulumi_gcp as gcp
|
483
|
+
|
484
|
+
binding = gcp.colab.RuntimeTemplateIamBinding("binding",
|
485
|
+
project=runtime_template["project"],
|
486
|
+
location=runtime_template["location"],
|
487
|
+
runtime_template=runtime_template["name"],
|
488
|
+
role="roles/viewer",
|
489
|
+
members=["user:jane@example.com"])
|
490
|
+
```
|
491
|
+
|
492
|
+
## colab.RuntimeTemplateIamMember
|
493
|
+
|
494
|
+
```python
|
495
|
+
import pulumi
|
496
|
+
import pulumi_gcp as gcp
|
497
|
+
|
498
|
+
member = gcp.colab.RuntimeTemplateIamMember("member",
|
499
|
+
project=runtime_template["project"],
|
500
|
+
location=runtime_template["location"],
|
501
|
+
runtime_template=runtime_template["name"],
|
502
|
+
role="roles/viewer",
|
503
|
+
member="user:jane@example.com")
|
504
|
+
```
|
505
|
+
|
506
|
+
## Import
|
507
|
+
|
508
|
+
For all import syntaxes, the "resource in question" can take any of the following forms:
|
509
|
+
|
510
|
+
* projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}}
|
511
|
+
|
512
|
+
* {{project}}/{{location}}/{{runtime_template}}
|
513
|
+
|
514
|
+
* {{location}}/{{runtime_template}}
|
515
|
+
|
516
|
+
* {{runtime_template}}
|
517
|
+
|
518
|
+
Any variables not passed in the import command will be taken from the provider configuration.
|
519
|
+
|
520
|
+
Colab Enterprise runtimetemplate IAM resources can be imported using the resource identifiers, role, and member.
|
521
|
+
|
522
|
+
IAM member imports use space-delimited identifiers: the resource in question, the role, and the member identity, e.g.
|
523
|
+
|
524
|
+
```sh
|
525
|
+
$ pulumi import gcp:colab/runtimeTemplateIamPolicy:RuntimeTemplateIamPolicy editor "projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}} roles/viewer user:jane@example.com"
|
526
|
+
```
|
527
|
+
|
528
|
+
IAM binding imports use space-delimited identifiers: the resource in question and the role, e.g.
|
529
|
+
|
530
|
+
```sh
|
531
|
+
$ pulumi import gcp:colab/runtimeTemplateIamPolicy:RuntimeTemplateIamPolicy editor "projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}} roles/viewer"
|
532
|
+
```
|
533
|
+
|
534
|
+
IAM policy imports use the identifier of the resource in question, e.g.
|
535
|
+
|
536
|
+
```sh
|
537
|
+
$ pulumi import gcp:colab/runtimeTemplateIamPolicy:RuntimeTemplateIamPolicy editor projects/{{project}}/locations/{{location}}/notebookRuntimeTemplates/{{runtime_template}}
|
538
|
+
```
|
539
|
+
|
540
|
+
-> **Custom Roles** If you're importing a IAM resource with a custom role, make sure to use the
|
541
|
+
|
542
|
+
full name of the custom role, e.g. `[projects/my-project|organizations/my-org]/roles/my-custom-role`.
|
543
|
+
|
544
|
+
:param str resource_name: The name of the resource.
|
545
|
+
:param RuntimeTemplateIamPolicyArgs args: The arguments to use to populate this resource's properties.
|
546
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
547
|
+
"""
|
548
|
+
...
|
549
|
+
def __init__(__self__, resource_name: str, *args, **kwargs):
|
550
|
+
resource_args, opts = _utilities.get_resource_args_opts(RuntimeTemplateIamPolicyArgs, pulumi.ResourceOptions, *args, **kwargs)
|
551
|
+
if resource_args is not None:
|
552
|
+
__self__._internal_init(resource_name, opts, **resource_args.__dict__)
|
553
|
+
else:
|
554
|
+
__self__._internal_init(resource_name, *args, **kwargs)
|
555
|
+
|
556
|
+
def _internal_init(__self__,
|
557
|
+
resource_name: str,
|
558
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
559
|
+
location: Optional[pulumi.Input[str]] = None,
|
560
|
+
policy_data: Optional[pulumi.Input[str]] = None,
|
561
|
+
project: Optional[pulumi.Input[str]] = None,
|
562
|
+
runtime_template: Optional[pulumi.Input[str]] = None,
|
563
|
+
__props__=None):
|
564
|
+
opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
|
565
|
+
if not isinstance(opts, pulumi.ResourceOptions):
|
566
|
+
raise TypeError('Expected resource options to be a ResourceOptions instance')
|
567
|
+
if opts.id is None:
|
568
|
+
if __props__ is not None:
|
569
|
+
raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
|
570
|
+
__props__ = RuntimeTemplateIamPolicyArgs.__new__(RuntimeTemplateIamPolicyArgs)
|
571
|
+
|
572
|
+
__props__.__dict__["location"] = location
|
573
|
+
if policy_data is None and not opts.urn:
|
574
|
+
raise TypeError("Missing required property 'policy_data'")
|
575
|
+
__props__.__dict__["policy_data"] = policy_data
|
576
|
+
__props__.__dict__["project"] = project
|
577
|
+
if runtime_template is None and not opts.urn:
|
578
|
+
raise TypeError("Missing required property 'runtime_template'")
|
579
|
+
__props__.__dict__["runtime_template"] = runtime_template
|
580
|
+
__props__.__dict__["etag"] = None
|
581
|
+
super(RuntimeTemplateIamPolicy, __self__).__init__(
|
582
|
+
'gcp:colab/runtimeTemplateIamPolicy:RuntimeTemplateIamPolicy',
|
583
|
+
resource_name,
|
584
|
+
__props__,
|
585
|
+
opts)
|
586
|
+
|
587
|
+
@staticmethod
|
588
|
+
def get(resource_name: str,
|
589
|
+
id: pulumi.Input[str],
|
590
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
591
|
+
etag: Optional[pulumi.Input[str]] = None,
|
592
|
+
location: Optional[pulumi.Input[str]] = None,
|
593
|
+
policy_data: Optional[pulumi.Input[str]] = None,
|
594
|
+
project: Optional[pulumi.Input[str]] = None,
|
595
|
+
runtime_template: Optional[pulumi.Input[str]] = None) -> 'RuntimeTemplateIamPolicy':
|
596
|
+
"""
|
597
|
+
Get an existing RuntimeTemplateIamPolicy resource's state with the given name, id, and optional extra
|
598
|
+
properties used to qualify the lookup.
|
599
|
+
|
600
|
+
:param str resource_name: The unique name of the resulting resource.
|
601
|
+
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
|
602
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
603
|
+
:param pulumi.Input[str] etag: (Computed) The etag of the IAM policy.
|
604
|
+
:param pulumi.Input[str] location: The location for the resource: https://cloud.google.com/colab/docs/locations Used to find the parent resource to bind the IAM policy to. If not specified,
|
605
|
+
the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
|
606
|
+
location is specified, it is taken from the provider configuration.
|
607
|
+
:param pulumi.Input[str] policy_data: The policy data generated by
|
608
|
+
a `organizations_get_iam_policy` data source.
|
609
|
+
:param pulumi.Input[str] project: The ID of the project in which the resource belongs.
|
610
|
+
If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
|
611
|
+
:param pulumi.Input[str] runtime_template: Used to find the parent resource to bind the IAM policy to
|
612
|
+
"""
|
613
|
+
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
|
614
|
+
|
615
|
+
__props__ = _RuntimeTemplateIamPolicyState.__new__(_RuntimeTemplateIamPolicyState)
|
616
|
+
|
617
|
+
__props__.__dict__["etag"] = etag
|
618
|
+
__props__.__dict__["location"] = location
|
619
|
+
__props__.__dict__["policy_data"] = policy_data
|
620
|
+
__props__.__dict__["project"] = project
|
621
|
+
__props__.__dict__["runtime_template"] = runtime_template
|
622
|
+
return RuntimeTemplateIamPolicy(resource_name, opts=opts, __props__=__props__)
|
623
|
+
|
624
|
+
@property
|
625
|
+
@pulumi.getter
|
626
|
+
def etag(self) -> pulumi.Output[str]:
|
627
|
+
"""
|
628
|
+
(Computed) The etag of the IAM policy.
|
629
|
+
"""
|
630
|
+
return pulumi.get(self, "etag")
|
631
|
+
|
632
|
+
@property
|
633
|
+
@pulumi.getter
|
634
|
+
def location(self) -> pulumi.Output[str]:
|
635
|
+
"""
|
636
|
+
The location for the resource: https://cloud.google.com/colab/docs/locations Used to find the parent resource to bind the IAM policy to. If not specified,
|
637
|
+
the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
|
638
|
+
location is specified, it is taken from the provider configuration.
|
639
|
+
"""
|
640
|
+
return pulumi.get(self, "location")
|
641
|
+
|
642
|
+
@property
|
643
|
+
@pulumi.getter(name="policyData")
|
644
|
+
def policy_data(self) -> pulumi.Output[str]:
|
645
|
+
"""
|
646
|
+
The policy data generated by
|
647
|
+
a `organizations_get_iam_policy` data source.
|
648
|
+
"""
|
649
|
+
return pulumi.get(self, "policy_data")
|
650
|
+
|
651
|
+
@property
|
652
|
+
@pulumi.getter
|
653
|
+
def project(self) -> pulumi.Output[str]:
|
654
|
+
"""
|
655
|
+
The ID of the project in which the resource belongs.
|
656
|
+
If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
|
657
|
+
"""
|
658
|
+
return pulumi.get(self, "project")
|
659
|
+
|
660
|
+
@property
|
661
|
+
@pulumi.getter(name="runtimeTemplate")
|
662
|
+
def runtime_template(self) -> pulumi.Output[str]:
|
663
|
+
"""
|
664
|
+
Used to find the parent resource to bind the IAM policy to
|
665
|
+
"""
|
666
|
+
return pulumi.get(self, "runtime_template")
|
667
|
+
|
pulumi_gcp/compute/__init__.py
CHANGED
@@ -57,6 +57,7 @@ from .get_instance_guest_attributes import *
|
|
57
57
|
from .get_instance_iam_policy import *
|
58
58
|
from .get_instance_serial_port import *
|
59
59
|
from .get_instance_template import *
|
60
|
+
from .get_instance_template_iam_policy import *
|
60
61
|
from .get_lbip_ranges import *
|
61
62
|
from .get_machine_image_iam_policy import *
|
62
63
|
from .get_machine_types import *
|
@@ -113,6 +114,9 @@ from .instance_iam_member import *
|
|
113
114
|
from .instance_iam_policy import *
|
114
115
|
from .instance_settings import *
|
115
116
|
from .instance_template import *
|
117
|
+
from .instance_template_iam_binding import *
|
118
|
+
from .instance_template_iam_member import *
|
119
|
+
from .instance_template_iam_policy import *
|
116
120
|
from .interconnect import *
|
117
121
|
from .interconnect_attachment import *
|
118
122
|
from .machine_image import *
|