pulumi-digitalocean 4.27.0a1710332933__py3-none-any.whl → 4.39.0a1736849637__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.

Potentially problematic release.


This version of pulumi-digitalocean might be problematic. Click here for more details.

Files changed (107) hide show
  1. pulumi_digitalocean/__init__.py +75 -0
  2. pulumi_digitalocean/_enums.py +131 -52
  3. pulumi_digitalocean/_inputs.py +5767 -399
  4. pulumi_digitalocean/_utilities.py +41 -5
  5. pulumi_digitalocean/app.py +199 -67
  6. pulumi_digitalocean/cdn.py +20 -23
  7. pulumi_digitalocean/certificate.py +45 -42
  8. pulumi_digitalocean/config/__init__.pyi +5 -0
  9. pulumi_digitalocean/config/vars.py +5 -0
  10. pulumi_digitalocean/container_registry.py +11 -6
  11. pulumi_digitalocean/container_registry_docker_credentials.py +53 -12
  12. pulumi_digitalocean/custom_image.py +13 -8
  13. pulumi_digitalocean/database_cluster.py +298 -120
  14. pulumi_digitalocean/database_connection_pool.py +15 -10
  15. pulumi_digitalocean/database_db.py +19 -12
  16. pulumi_digitalocean/database_firewall.py +78 -75
  17. pulumi_digitalocean/database_kafka_config.py +1040 -0
  18. pulumi_digitalocean/database_kafka_topic.py +66 -61
  19. pulumi_digitalocean/database_mongodb_config.py +452 -0
  20. pulumi_digitalocean/database_mysql_config.py +15 -12
  21. pulumi_digitalocean/database_opensearch_config.py +2069 -0
  22. pulumi_digitalocean/database_postgresql_config.py +2614 -0
  23. pulumi_digitalocean/database_redis_config.py +29 -12
  24. pulumi_digitalocean/database_replica.py +29 -24
  25. pulumi_digitalocean/database_user.py +90 -75
  26. pulumi_digitalocean/dns_record.py +13 -8
  27. pulumi_digitalocean/domain.py +7 -6
  28. pulumi_digitalocean/droplet.py +89 -31
  29. pulumi_digitalocean/droplet_autoscale.py +474 -0
  30. pulumi_digitalocean/droplet_snapshot.py +23 -14
  31. pulumi_digitalocean/firewall.py +118 -106
  32. pulumi_digitalocean/floating_ip.py +19 -16
  33. pulumi_digitalocean/floating_ip_assignment.py +19 -16
  34. pulumi_digitalocean/get_account.py +18 -9
  35. pulumi_digitalocean/get_app.py +57 -10
  36. pulumi_digitalocean/get_certificate.py +19 -9
  37. pulumi_digitalocean/get_container_registry.py +19 -9
  38. pulumi_digitalocean/get_database_ca.py +14 -9
  39. pulumi_digitalocean/get_database_cluster.py +119 -11
  40. pulumi_digitalocean/get_database_connection_pool.py +25 -9
  41. pulumi_digitalocean/get_database_replica.py +29 -9
  42. pulumi_digitalocean/get_database_user.py +21 -9
  43. pulumi_digitalocean/get_domain.py +16 -9
  44. pulumi_digitalocean/get_domains.py +34 -27
  45. pulumi_digitalocean/get_droplet.py +66 -23
  46. pulumi_digitalocean/get_droplet_autoscale.py +197 -0
  47. pulumi_digitalocean/get_droplet_snapshot.py +36 -23
  48. pulumi_digitalocean/get_droplets.py +80 -54
  49. pulumi_digitalocean/get_firewall.py +29 -13
  50. pulumi_digitalocean/get_floating_ip.py +16 -9
  51. pulumi_digitalocean/get_image.py +42 -27
  52. pulumi_digitalocean/get_images.py +56 -53
  53. pulumi_digitalocean/get_kubernetes_cluster.py +53 -6
  54. pulumi_digitalocean/get_kubernetes_versions.py +43 -41
  55. pulumi_digitalocean/get_load_balancer.py +81 -17
  56. pulumi_digitalocean/get_project.py +23 -9
  57. pulumi_digitalocean/get_projects.py +56 -53
  58. pulumi_digitalocean/get_record.py +23 -9
  59. pulumi_digitalocean/get_records.py +62 -13
  60. pulumi_digitalocean/get_region.py +17 -9
  61. pulumi_digitalocean/get_regions.py +56 -53
  62. pulumi_digitalocean/get_reserved_ip.py +16 -9
  63. pulumi_digitalocean/get_reserved_ipv6.py +118 -0
  64. pulumi_digitalocean/get_sizes.py +24 -13
  65. pulumi_digitalocean/get_spaces_bucket.py +18 -9
  66. pulumi_digitalocean/get_spaces_bucket_object.py +41 -14
  67. pulumi_digitalocean/get_spaces_bucket_objects.py +26 -5
  68. pulumi_digitalocean/get_spaces_buckets.py +48 -45
  69. pulumi_digitalocean/get_ssh_key.py +27 -19
  70. pulumi_digitalocean/get_ssh_keys.py +40 -37
  71. pulumi_digitalocean/get_tag.py +31 -19
  72. pulumi_digitalocean/get_tags.py +32 -25
  73. pulumi_digitalocean/get_volume.py +35 -23
  74. pulumi_digitalocean/get_volume_snapshot.py +35 -21
  75. pulumi_digitalocean/get_vpc.py +33 -23
  76. pulumi_digitalocean/get_vpc_peering.py +244 -0
  77. pulumi_digitalocean/kubernetes_cluster.py +86 -35
  78. pulumi_digitalocean/kubernetes_node_pool.py +46 -43
  79. pulumi_digitalocean/load_balancer.py +320 -157
  80. pulumi_digitalocean/monitor_alert.py +17 -12
  81. pulumi_digitalocean/outputs.py +3419 -344
  82. pulumi_digitalocean/project.py +19 -16
  83. pulumi_digitalocean/project_resources.py +11 -8
  84. pulumi_digitalocean/provider.py +5 -0
  85. pulumi_digitalocean/pulumi-plugin.json +2 -1
  86. pulumi_digitalocean/reserved_ip.py +19 -16
  87. pulumi_digitalocean/reserved_ip_assignment.py +19 -16
  88. pulumi_digitalocean/reserved_ipv6.py +232 -0
  89. pulumi_digitalocean/reserved_ipv6_assignment.py +171 -0
  90. pulumi_digitalocean/spaces_bucket.py +70 -79
  91. pulumi_digitalocean/spaces_bucket_cors_configuration.py +30 -25
  92. pulumi_digitalocean/spaces_bucket_object.py +11 -12
  93. pulumi_digitalocean/spaces_bucket_policy.py +21 -16
  94. pulumi_digitalocean/ssh_key.py +19 -10
  95. pulumi_digitalocean/tag.py +13 -10
  96. pulumi_digitalocean/uptime_alert.py +10 -5
  97. pulumi_digitalocean/uptime_check.py +5 -0
  98. pulumi_digitalocean/volume.py +47 -50
  99. pulumi_digitalocean/volume_attachment.py +25 -20
  100. pulumi_digitalocean/volume_snapshot.py +17 -10
  101. pulumi_digitalocean/vpc.py +27 -22
  102. pulumi_digitalocean/vpc_peering.py +378 -0
  103. {pulumi_digitalocean-4.27.0a1710332933.dist-info → pulumi_digitalocean-4.39.0a1736849637.dist-info}/METADATA +7 -6
  104. pulumi_digitalocean-4.39.0a1736849637.dist-info/RECORD +108 -0
  105. {pulumi_digitalocean-4.27.0a1710332933.dist-info → pulumi_digitalocean-4.39.0a1736849637.dist-info}/WHEEL +1 -1
  106. pulumi_digitalocean-4.27.0a1710332933.dist-info/RECORD +0 -97
  107. {pulumi_digitalocean-4.27.0a1710332933.dist-info → pulumi_digitalocean-4.39.0a1736849637.dist-info}/top_level.txt +0 -0
@@ -4,9 +4,14 @@
4
4
 
5
5
  import copy
6
6
  import warnings
7
+ import sys
7
8
  import pulumi
8
9
  import pulumi.runtime
9
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
10
15
  from . import _utilities
11
16
 
12
17
  __all__ = [
@@ -166,20 +171,17 @@ def get_volume_snapshot(most_recent: Optional[bool] = None,
166
171
 
167
172
  Get the volume snapshot:
168
173
 
169
- <!--Start PulumiCodeChooser -->
170
174
  ```python
171
175
  import pulumi
172
176
  import pulumi_digitalocean as digitalocean
173
177
 
174
- snapshot = digitalocean.get_volume_snapshot(most_recent=True,
175
- name_regex="^web",
176
- region="nyc3")
178
+ snapshot = digitalocean.get_volume_snapshot(name_regex="^web",
179
+ region="nyc3",
180
+ most_recent=True)
177
181
  ```
178
- <!--End PulumiCodeChooser -->
179
182
 
180
183
  Reuse the data about a volume snapshot to create a new volume based on it:
181
184
 
182
- <!--Start PulumiCodeChooser -->
183
185
  ```python
184
186
  import pulumi
185
187
  import pulumi_digitalocean as digitalocean
@@ -188,11 +190,11 @@ def get_volume_snapshot(most_recent: Optional[bool] = None,
188
190
  region="nyc3",
189
191
  most_recent=True)
190
192
  foobar = digitalocean.Volume("foobar",
191
- region="nyc3",
193
+ region=digitalocean.Region.NYC3,
194
+ name="baz",
192
195
  size=100,
193
196
  snapshot_id=snapshot.id)
194
197
  ```
195
- <!--End PulumiCodeChooser -->
196
198
 
197
199
 
198
200
  :param bool most_recent: If more than one result is returned, use the most recent volume snapshot.
@@ -224,14 +226,11 @@ def get_volume_snapshot(most_recent: Optional[bool] = None,
224
226
  size=pulumi.get(__ret__, 'size'),
225
227
  tags=pulumi.get(__ret__, 'tags'),
226
228
  volume_id=pulumi.get(__ret__, 'volume_id'))
227
-
228
-
229
- @_utilities.lift_output_func(get_volume_snapshot)
230
229
  def get_volume_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool]]] = None,
231
230
  name: Optional[pulumi.Input[Optional[str]]] = None,
232
231
  name_regex: Optional[pulumi.Input[Optional[str]]] = None,
233
232
  region: Optional[pulumi.Input[Optional[str]]] = None,
234
- opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetVolumeSnapshotResult]:
233
+ opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetVolumeSnapshotResult]:
235
234
  """
236
235
  Volume snapshots are saved instances of a block storage volume. Use this data
237
236
  source to retrieve the ID of a DigitalOcean volume snapshot for use in other
@@ -241,20 +240,17 @@ def get_volume_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool]
241
240
 
242
241
  Get the volume snapshot:
243
242
 
244
- <!--Start PulumiCodeChooser -->
245
243
  ```python
246
244
  import pulumi
247
245
  import pulumi_digitalocean as digitalocean
248
246
 
249
- snapshot = digitalocean.get_volume_snapshot(most_recent=True,
250
- name_regex="^web",
251
- region="nyc3")
247
+ snapshot = digitalocean.get_volume_snapshot(name_regex="^web",
248
+ region="nyc3",
249
+ most_recent=True)
252
250
  ```
253
- <!--End PulumiCodeChooser -->
254
251
 
255
252
  Reuse the data about a volume snapshot to create a new volume based on it:
256
253
 
257
- <!--Start PulumiCodeChooser -->
258
254
  ```python
259
255
  import pulumi
260
256
  import pulumi_digitalocean as digitalocean
@@ -263,11 +259,11 @@ def get_volume_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool]
263
259
  region="nyc3",
264
260
  most_recent=True)
265
261
  foobar = digitalocean.Volume("foobar",
266
- region="nyc3",
262
+ region=digitalocean.Region.NYC3,
263
+ name="baz",
267
264
  size=100,
268
265
  snapshot_id=snapshot.id)
269
266
  ```
270
- <!--End PulumiCodeChooser -->
271
267
 
272
268
 
273
269
  :param bool most_recent: If more than one result is returned, use the most recent volume snapshot.
@@ -279,4 +275,22 @@ def get_volume_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool]
279
275
  :param str name_regex: A regex string to apply to the volume snapshot list returned by DigitalOcean. This allows more advanced filtering not supported from the DigitalOcean API. This filtering is done locally on what DigitalOcean returns.
280
276
  :param str region: A "slug" representing a DigitalOcean region (e.g. `nyc1`). If set, only volume snapshots available in the region will be returned.
281
277
  """
282
- ...
278
+ __args__ = dict()
279
+ __args__['mostRecent'] = most_recent
280
+ __args__['name'] = name
281
+ __args__['nameRegex'] = name_regex
282
+ __args__['region'] = region
283
+ opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
284
+ __ret__ = pulumi.runtime.invoke_output('digitalocean:index/getVolumeSnapshot:getVolumeSnapshot', __args__, opts=opts, typ=GetVolumeSnapshotResult)
285
+ return __ret__.apply(lambda __response__: GetVolumeSnapshotResult(
286
+ created_at=pulumi.get(__response__, 'created_at'),
287
+ id=pulumi.get(__response__, 'id'),
288
+ min_disk_size=pulumi.get(__response__, 'min_disk_size'),
289
+ most_recent=pulumi.get(__response__, 'most_recent'),
290
+ name=pulumi.get(__response__, 'name'),
291
+ name_regex=pulumi.get(__response__, 'name_regex'),
292
+ region=pulumi.get(__response__, 'region'),
293
+ regions=pulumi.get(__response__, 'regions'),
294
+ size=pulumi.get(__response__, 'size'),
295
+ tags=pulumi.get(__response__, 'tags'),
296
+ volume_id=pulumi.get(__response__, 'volume_id')))
@@ -4,9 +4,14 @@
4
4
 
5
5
  import copy
6
6
  import warnings
7
+ import sys
7
8
  import pulumi
8
9
  import pulumi.runtime
9
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
10
15
  from . import _utilities
11
16
 
12
17
  __all__ = [
@@ -146,30 +151,27 @@ def get_vpc(id: Optional[str] = None,
146
151
 
147
152
  ### VPC By Name
148
153
 
149
- <!--Start PulumiCodeChooser -->
150
154
  ```python
151
155
  import pulumi
152
156
  import pulumi_digitalocean as digitalocean
153
157
 
154
158
  example = digitalocean.get_vpc(name="example-network")
155
159
  ```
156
- <!--End PulumiCodeChooser -->
157
160
 
158
161
  Reuse the data about a VPC to assign a Droplet to it:
159
162
 
160
- <!--Start PulumiCodeChooser -->
161
163
  ```python
162
164
  import pulumi
163
165
  import pulumi_digitalocean as digitalocean
164
166
 
165
- example_vpc = digitalocean.get_vpc(name="example-network")
166
- example_droplet = digitalocean.Droplet("exampleDroplet",
167
- size="s-1vcpu-1gb",
167
+ example = digitalocean.get_vpc(name="example-network")
168
+ example_droplet = digitalocean.Droplet("example",
169
+ name="example-01",
170
+ size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,
168
171
  image="ubuntu-18-04-x64",
169
- region="nyc3",
170
- vpc_uuid=example_vpc.id)
172
+ region=digitalocean.Region.NYC3,
173
+ vpc_uuid=example.id)
171
174
  ```
172
- <!--End PulumiCodeChooser -->
173
175
 
174
176
 
175
177
  :param str id: The unique identifier of an existing VPC.
@@ -192,13 +194,10 @@ def get_vpc(id: Optional[str] = None,
192
194
  name=pulumi.get(__ret__, 'name'),
193
195
  region=pulumi.get(__ret__, 'region'),
194
196
  urn=pulumi.get(__ret__, 'urn'))
195
-
196
-
197
- @_utilities.lift_output_func(get_vpc)
198
197
  def get_vpc_output(id: Optional[pulumi.Input[Optional[str]]] = None,
199
198
  name: Optional[pulumi.Input[Optional[str]]] = None,
200
199
  region: Optional[pulumi.Input[Optional[str]]] = None,
201
- opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetVpcResult]:
200
+ opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetVpcResult]:
202
201
  """
203
202
  Retrieve information about a VPC for use in other resources.
204
203
 
@@ -213,34 +212,45 @@ def get_vpc_output(id: Optional[pulumi.Input[Optional[str]]] = None,
213
212
 
214
213
  ### VPC By Name
215
214
 
216
- <!--Start PulumiCodeChooser -->
217
215
  ```python
218
216
  import pulumi
219
217
  import pulumi_digitalocean as digitalocean
220
218
 
221
219
  example = digitalocean.get_vpc(name="example-network")
222
220
  ```
223
- <!--End PulumiCodeChooser -->
224
221
 
225
222
  Reuse the data about a VPC to assign a Droplet to it:
226
223
 
227
- <!--Start PulumiCodeChooser -->
228
224
  ```python
229
225
  import pulumi
230
226
  import pulumi_digitalocean as digitalocean
231
227
 
232
- example_vpc = digitalocean.get_vpc(name="example-network")
233
- example_droplet = digitalocean.Droplet("exampleDroplet",
234
- size="s-1vcpu-1gb",
228
+ example = digitalocean.get_vpc(name="example-network")
229
+ example_droplet = digitalocean.Droplet("example",
230
+ name="example-01",
231
+ size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,
235
232
  image="ubuntu-18-04-x64",
236
- region="nyc3",
237
- vpc_uuid=example_vpc.id)
233
+ region=digitalocean.Region.NYC3,
234
+ vpc_uuid=example.id)
238
235
  ```
239
- <!--End PulumiCodeChooser -->
240
236
 
241
237
 
242
238
  :param str id: The unique identifier of an existing VPC.
243
239
  :param str name: The name of an existing VPC.
244
240
  :param str region: The DigitalOcean region slug for the VPC's location.
245
241
  """
246
- ...
242
+ __args__ = dict()
243
+ __args__['id'] = id
244
+ __args__['name'] = name
245
+ __args__['region'] = region
246
+ opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
247
+ __ret__ = pulumi.runtime.invoke_output('digitalocean:index/getVpc:getVpc', __args__, opts=opts, typ=GetVpcResult)
248
+ return __ret__.apply(lambda __response__: GetVpcResult(
249
+ created_at=pulumi.get(__response__, 'created_at'),
250
+ default=pulumi.get(__response__, 'default'),
251
+ description=pulumi.get(__response__, 'description'),
252
+ id=pulumi.get(__response__, 'id'),
253
+ ip_range=pulumi.get(__response__, 'ip_range'),
254
+ name=pulumi.get(__response__, 'name'),
255
+ region=pulumi.get(__response__, 'region'),
256
+ urn=pulumi.get(__response__, 'urn')))
@@ -0,0 +1,244 @@
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__ = [
18
+ 'GetVpcPeeringResult',
19
+ 'AwaitableGetVpcPeeringResult',
20
+ 'get_vpc_peering',
21
+ 'get_vpc_peering_output',
22
+ ]
23
+
24
+ @pulumi.output_type
25
+ class GetVpcPeeringResult:
26
+ """
27
+ A collection of values returned by getVpcPeering.
28
+ """
29
+ def __init__(__self__, created_at=None, id=None, name=None, status=None, vpc_ids=None):
30
+ if created_at and not isinstance(created_at, str):
31
+ raise TypeError("Expected argument 'created_at' to be a str")
32
+ pulumi.set(__self__, "created_at", created_at)
33
+ if id and not isinstance(id, str):
34
+ raise TypeError("Expected argument 'id' to be a str")
35
+ pulumi.set(__self__, "id", id)
36
+ if name and not isinstance(name, str):
37
+ raise TypeError("Expected argument 'name' to be a str")
38
+ pulumi.set(__self__, "name", name)
39
+ if status and not isinstance(status, str):
40
+ raise TypeError("Expected argument 'status' to be a str")
41
+ pulumi.set(__self__, "status", status)
42
+ if vpc_ids and not isinstance(vpc_ids, list):
43
+ raise TypeError("Expected argument 'vpc_ids' to be a list")
44
+ pulumi.set(__self__, "vpc_ids", vpc_ids)
45
+
46
+ @property
47
+ @pulumi.getter(name="createdAt")
48
+ def created_at(self) -> str:
49
+ """
50
+ The date and time of when the VPC Peering was created.
51
+ """
52
+ return pulumi.get(self, "created_at")
53
+
54
+ @property
55
+ @pulumi.getter
56
+ def id(self) -> str:
57
+ """
58
+ The unique identifier for the VPC Peering.
59
+ """
60
+ return pulumi.get(self, "id")
61
+
62
+ @property
63
+ @pulumi.getter
64
+ def name(self) -> str:
65
+ """
66
+ The name of the VPC Peering.
67
+ """
68
+ return pulumi.get(self, "name")
69
+
70
+ @property
71
+ @pulumi.getter
72
+ def status(self) -> str:
73
+ """
74
+ The status of the VPC Peering.
75
+ """
76
+ return pulumi.get(self, "status")
77
+
78
+ @property
79
+ @pulumi.getter(name="vpcIds")
80
+ def vpc_ids(self) -> Sequence[str]:
81
+ """
82
+ The list of VPC IDs involved in the peering.
83
+ """
84
+ return pulumi.get(self, "vpc_ids")
85
+
86
+
87
+ class AwaitableGetVpcPeeringResult(GetVpcPeeringResult):
88
+ # pylint: disable=using-constant-test
89
+ def __await__(self):
90
+ if False:
91
+ yield self
92
+ return GetVpcPeeringResult(
93
+ created_at=self.created_at,
94
+ id=self.id,
95
+ name=self.name,
96
+ status=self.status,
97
+ vpc_ids=self.vpc_ids)
98
+
99
+
100
+ def get_vpc_peering(id: Optional[str] = None,
101
+ name: Optional[str] = None,
102
+ vpc_ids: Optional[Sequence[str]] = None,
103
+ opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetVpcPeeringResult:
104
+ """
105
+ ## Example Usage
106
+
107
+ ### VPC Peering By Id
108
+
109
+ ```python
110
+ import pulumi
111
+ import pulumi_digitalocean as digitalocean
112
+
113
+ example = digitalocean.get_vpc_peering(id="example-id")
114
+ ```
115
+
116
+ Reuse the data about a VPC Peering in other resources:
117
+
118
+ ```python
119
+ import pulumi
120
+ import pulumi_digitalocean as digitalocean
121
+
122
+ example = digitalocean.get_vpc_peering(id="example-id")
123
+ example_droplet = digitalocean.Droplet("example",
124
+ name="example-01",
125
+ size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,
126
+ image="ubuntu-18-04-x64",
127
+ region=digitalocean.Region.NYC3,
128
+ vpc_uuid=example.vpc_ids[0])
129
+ ```
130
+
131
+ ### VPC Peering By Name
132
+
133
+ ```python
134
+ import pulumi
135
+ import pulumi_digitalocean as digitalocean
136
+
137
+ example = digitalocean.get_vpc_peering(name="example-peering")
138
+ ```
139
+
140
+ Reuse the data about a VPC Peering in other resources:
141
+
142
+ ```python
143
+ import pulumi
144
+ import pulumi_digitalocean as digitalocean
145
+
146
+ example = digitalocean.get_vpc_peering(name="example-peering")
147
+ example_droplet = digitalocean.Droplet("example",
148
+ name="example-01",
149
+ size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,
150
+ image="ubuntu-18-04-x64",
151
+ region=digitalocean.Region.NYC3,
152
+ vpc_uuid=example.vpc_ids[0])
153
+ ```
154
+
155
+
156
+ :param str id: The unique identifier of an existing VPC Peering.
157
+ :param str name: The name of an existing VPC Peering.
158
+ :param Sequence[str] vpc_ids: The list of VPC IDs involved in the peering.
159
+ """
160
+ __args__ = dict()
161
+ __args__['id'] = id
162
+ __args__['name'] = name
163
+ __args__['vpcIds'] = vpc_ids
164
+ opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
165
+ __ret__ = pulumi.runtime.invoke('digitalocean:index/getVpcPeering:getVpcPeering', __args__, opts=opts, typ=GetVpcPeeringResult).value
166
+
167
+ return AwaitableGetVpcPeeringResult(
168
+ created_at=pulumi.get(__ret__, 'created_at'),
169
+ id=pulumi.get(__ret__, 'id'),
170
+ name=pulumi.get(__ret__, 'name'),
171
+ status=pulumi.get(__ret__, 'status'),
172
+ vpc_ids=pulumi.get(__ret__, 'vpc_ids'))
173
+ def get_vpc_peering_output(id: Optional[pulumi.Input[Optional[str]]] = None,
174
+ name: Optional[pulumi.Input[Optional[str]]] = None,
175
+ vpc_ids: Optional[pulumi.Input[Optional[Sequence[str]]]] = None,
176
+ opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetVpcPeeringResult]:
177
+ """
178
+ ## Example Usage
179
+
180
+ ### VPC Peering By Id
181
+
182
+ ```python
183
+ import pulumi
184
+ import pulumi_digitalocean as digitalocean
185
+
186
+ example = digitalocean.get_vpc_peering(id="example-id")
187
+ ```
188
+
189
+ Reuse the data about a VPC Peering in other resources:
190
+
191
+ ```python
192
+ import pulumi
193
+ import pulumi_digitalocean as digitalocean
194
+
195
+ example = digitalocean.get_vpc_peering(id="example-id")
196
+ example_droplet = digitalocean.Droplet("example",
197
+ name="example-01",
198
+ size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,
199
+ image="ubuntu-18-04-x64",
200
+ region=digitalocean.Region.NYC3,
201
+ vpc_uuid=example.vpc_ids[0])
202
+ ```
203
+
204
+ ### VPC Peering By Name
205
+
206
+ ```python
207
+ import pulumi
208
+ import pulumi_digitalocean as digitalocean
209
+
210
+ example = digitalocean.get_vpc_peering(name="example-peering")
211
+ ```
212
+
213
+ Reuse the data about a VPC Peering in other resources:
214
+
215
+ ```python
216
+ import pulumi
217
+ import pulumi_digitalocean as digitalocean
218
+
219
+ example = digitalocean.get_vpc_peering(name="example-peering")
220
+ example_droplet = digitalocean.Droplet("example",
221
+ name="example-01",
222
+ size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,
223
+ image="ubuntu-18-04-x64",
224
+ region=digitalocean.Region.NYC3,
225
+ vpc_uuid=example.vpc_ids[0])
226
+ ```
227
+
228
+
229
+ :param str id: The unique identifier of an existing VPC Peering.
230
+ :param str name: The name of an existing VPC Peering.
231
+ :param Sequence[str] vpc_ids: The list of VPC IDs involved in the peering.
232
+ """
233
+ __args__ = dict()
234
+ __args__['id'] = id
235
+ __args__['name'] = name
236
+ __args__['vpcIds'] = vpc_ids
237
+ opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
238
+ __ret__ = pulumi.runtime.invoke_output('digitalocean:index/getVpcPeering:getVpcPeering', __args__, opts=opts, typ=GetVpcPeeringResult)
239
+ return __ret__.apply(lambda __response__: GetVpcPeeringResult(
240
+ created_at=pulumi.get(__response__, 'created_at'),
241
+ id=pulumi.get(__response__, 'id'),
242
+ name=pulumi.get(__response__, 'name'),
243
+ status=pulumi.get(__response__, 'status'),
244
+ vpc_ids=pulumi.get(__response__, 'vpc_ids')))