pulumi-hcloud 1.18.0a1710156455__py3-none-any.whl → 1.22.0a1736849475__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.
Files changed (66) hide show
  1. pulumi_hcloud/__init__.py +2 -0
  2. pulumi_hcloud/_inputs.py +247 -15
  3. pulumi_hcloud/_utilities.py +41 -5
  4. pulumi_hcloud/certificate.py +15 -10
  5. pulumi_hcloud/config/__init__.pyi +5 -0
  6. pulumi_hcloud/config/vars.py +5 -0
  7. pulumi_hcloud/firewall.py +77 -70
  8. pulumi_hcloud/firewall_attachment.py +27 -26
  9. pulumi_hcloud/floating_ip.py +39 -36
  10. pulumi_hcloud/floating_ip_assignment.py +11 -8
  11. pulumi_hcloud/get_certificate.py +25 -10
  12. pulumi_hcloud/get_certificates.py +14 -9
  13. pulumi_hcloud/get_datacenter.py +38 -27
  14. pulumi_hcloud/get_datacenters.py +28 -53
  15. pulumi_hcloud/get_firewall.py +38 -23
  16. pulumi_hcloud/get_firewalls.py +16 -9
  17. pulumi_hcloud/get_floating_ip.py +37 -17
  18. pulumi_hcloud/get_floating_ips.py +14 -9
  19. pulumi_hcloud/get_image.py +37 -13
  20. pulumi_hcloud/get_images.py +22 -9
  21. pulumi_hcloud/get_load_balancer.py +30 -11
  22. pulumi_hcloud/get_load_balancer_type.py +202 -0
  23. pulumi_hcloud/get_load_balancer_types.py +100 -0
  24. pulumi_hcloud/get_load_balancers.py +14 -9
  25. pulumi_hcloud/get_location.py +42 -29
  26. pulumi_hcloud/get_locations.py +28 -53
  27. pulumi_hcloud/get_network.py +28 -15
  28. pulumi_hcloud/get_networks.py +14 -9
  29. pulumi_hcloud/get_placement_group.py +31 -17
  30. pulumi_hcloud/get_placement_groups.py +16 -9
  31. pulumi_hcloud/get_primary_ip.py +42 -22
  32. pulumi_hcloud/get_primary_ips.py +14 -9
  33. pulumi_hcloud/get_server.py +43 -15
  34. pulumi_hcloud/get_server_type.py +75 -53
  35. pulumi_hcloud/get_server_types.py +39 -23
  36. pulumi_hcloud/get_servers.py +16 -9
  37. pulumi_hcloud/get_ssh_key.py +58 -36
  38. pulumi_hcloud/get_ssh_keys.py +35 -24
  39. pulumi_hcloud/get_volume.py +33 -16
  40. pulumi_hcloud/get_volumes.py +18 -11
  41. pulumi_hcloud/load_balancer.py +63 -64
  42. pulumi_hcloud/load_balancer_network.py +26 -17
  43. pulumi_hcloud/load_balancer_service.py +57 -54
  44. pulumi_hcloud/load_balancer_target.py +23 -18
  45. pulumi_hcloud/managed_certificate.py +57 -20
  46. pulumi_hcloud/network.py +27 -22
  47. pulumi_hcloud/network_route.py +13 -8
  48. pulumi_hcloud/network_subnet.py +13 -8
  49. pulumi_hcloud/outputs.py +265 -46
  50. pulumi_hcloud/placement_group.py +27 -22
  51. pulumi_hcloud/primary_ip.py +66 -47
  52. pulumi_hcloud/provider.py +5 -0
  53. pulumi_hcloud/pulumi-plugin.json +2 -1
  54. pulumi_hcloud/rdns.py +41 -40
  55. pulumi_hcloud/server.py +123 -176
  56. pulumi_hcloud/server_network.py +24 -17
  57. pulumi_hcloud/snapshot.py +25 -22
  58. pulumi_hcloud/ssh_key.py +52 -51
  59. pulumi_hcloud/uploaded_certificate.py +73 -20
  60. pulumi_hcloud/volume.py +37 -32
  61. pulumi_hcloud/volume_attachment.py +11 -8
  62. {pulumi_hcloud-1.18.0a1710156455.dist-info → pulumi_hcloud-1.22.0a1736849475.dist-info}/METADATA +7 -6
  63. pulumi_hcloud-1.22.0a1736849475.dist-info/RECORD +67 -0
  64. {pulumi_hcloud-1.18.0a1710156455.dist-info → pulumi_hcloud-1.22.0a1736849475.dist-info}/WHEEL +1 -1
  65. pulumi_hcloud-1.18.0a1710156455.dist-info/RECORD +0 -65
  66. {pulumi_hcloud-1.18.0a1710156455.dist-info → pulumi_hcloud-1.22.0a1736849475.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__ = ['FloatingIpArgs', 'FloatingIp']
@@ -18,7 +23,7 @@ class FloatingIpArgs:
18
23
  delete_protection: Optional[pulumi.Input[bool]] = None,
19
24
  description: Optional[pulumi.Input[str]] = None,
20
25
  home_location: Optional[pulumi.Input[str]] = None,
21
- labels: Optional[pulumi.Input[Mapping[str, Any]]] = None,
26
+ labels: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
22
27
  name: Optional[pulumi.Input[str]] = None,
23
28
  server_id: Optional[pulumi.Input[int]] = None):
24
29
  """
@@ -26,10 +31,10 @@ class FloatingIpArgs:
26
31
  :param pulumi.Input[str] type: Type of the Floating IP. `ipv4` `ipv6`
27
32
  :param pulumi.Input[bool] delete_protection: Enable or disable delete protection. See "Delete Protection" in the Provider Docs for details.
28
33
  :param pulumi.Input[str] description: Description of the Floating IP.
29
- :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if server_id argument is passed.
30
- :param pulumi.Input[Mapping[str, Any]] labels: User-defined labels (key-value pairs) should be created with.
34
+ :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if `server_id` argument is passed.
35
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] labels: User-defined labels (key-value pairs) should be created with.
31
36
  :param pulumi.Input[str] name: Name of the Floating IP.
32
- :param pulumi.Input[int] server_id: Server to assign the Floating IP to.
37
+ :param pulumi.Input[int] server_id: Server to assign the Floating IP to. Optional if `home_location` argument is passed.
33
38
  """
34
39
  pulumi.set(__self__, "type", type)
35
40
  if delete_protection is not None:
@@ -85,7 +90,7 @@ class FloatingIpArgs:
85
90
  @pulumi.getter(name="homeLocation")
86
91
  def home_location(self) -> Optional[pulumi.Input[str]]:
87
92
  """
88
- Name of home location (routing is optimized for that location). Optional if server_id argument is passed.
93
+ Name of home location (routing is optimized for that location). Optional if `server_id` argument is passed.
89
94
  """
90
95
  return pulumi.get(self, "home_location")
91
96
 
@@ -95,14 +100,14 @@ class FloatingIpArgs:
95
100
 
96
101
  @property
97
102
  @pulumi.getter
98
- def labels(self) -> Optional[pulumi.Input[Mapping[str, Any]]]:
103
+ def labels(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
99
104
  """
100
105
  User-defined labels (key-value pairs) should be created with.
101
106
  """
102
107
  return pulumi.get(self, "labels")
103
108
 
104
109
  @labels.setter
105
- def labels(self, value: Optional[pulumi.Input[Mapping[str, Any]]]):
110
+ def labels(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]):
106
111
  pulumi.set(self, "labels", value)
107
112
 
108
113
  @property
@@ -121,7 +126,7 @@ class FloatingIpArgs:
121
126
  @pulumi.getter(name="serverId")
122
127
  def server_id(self) -> Optional[pulumi.Input[int]]:
123
128
  """
124
- Server to assign the Floating IP to.
129
+ Server to assign the Floating IP to. Optional if `home_location` argument is passed.
125
130
  """
126
131
  return pulumi.get(self, "server_id")
127
132
 
@@ -138,7 +143,7 @@ class _FloatingIpState:
138
143
  home_location: Optional[pulumi.Input[str]] = None,
139
144
  ip_address: Optional[pulumi.Input[str]] = None,
140
145
  ip_network: Optional[pulumi.Input[str]] = None,
141
- labels: Optional[pulumi.Input[Mapping[str, Any]]] = None,
146
+ labels: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
142
147
  name: Optional[pulumi.Input[str]] = None,
143
148
  server_id: Optional[pulumi.Input[int]] = None,
144
149
  type: Optional[pulumi.Input[str]] = None):
@@ -146,12 +151,12 @@ class _FloatingIpState:
146
151
  Input properties used for looking up and filtering FloatingIp resources.
147
152
  :param pulumi.Input[bool] delete_protection: Enable or disable delete protection. See "Delete Protection" in the Provider Docs for details.
148
153
  :param pulumi.Input[str] description: Description of the Floating IP.
149
- :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if server_id argument is passed.
154
+ :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if `server_id` argument is passed.
150
155
  :param pulumi.Input[str] ip_address: (string) IP Address of the Floating IP.
151
156
  :param pulumi.Input[str] ip_network: (string) IPv6 subnet. (Only set if `type` is `ipv6`)
152
- :param pulumi.Input[Mapping[str, Any]] labels: User-defined labels (key-value pairs) should be created with.
157
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] labels: User-defined labels (key-value pairs) should be created with.
153
158
  :param pulumi.Input[str] name: Name of the Floating IP.
154
- :param pulumi.Input[int] server_id: Server to assign the Floating IP to.
159
+ :param pulumi.Input[int] server_id: Server to assign the Floating IP to. Optional if `home_location` argument is passed.
155
160
  :param pulumi.Input[str] type: Type of the Floating IP. `ipv4` `ipv6`
156
161
  """
157
162
  if delete_protection is not None:
@@ -201,7 +206,7 @@ class _FloatingIpState:
201
206
  @pulumi.getter(name="homeLocation")
202
207
  def home_location(self) -> Optional[pulumi.Input[str]]:
203
208
  """
204
- Name of home location (routing is optimized for that location). Optional if server_id argument is passed.
209
+ Name of home location (routing is optimized for that location). Optional if `server_id` argument is passed.
205
210
  """
206
211
  return pulumi.get(self, "home_location")
207
212
 
@@ -235,14 +240,14 @@ class _FloatingIpState:
235
240
 
236
241
  @property
237
242
  @pulumi.getter
238
- def labels(self) -> Optional[pulumi.Input[Mapping[str, Any]]]:
243
+ def labels(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
239
244
  """
240
245
  User-defined labels (key-value pairs) should be created with.
241
246
  """
242
247
  return pulumi.get(self, "labels")
243
248
 
244
249
  @labels.setter
245
- def labels(self, value: Optional[pulumi.Input[Mapping[str, Any]]]):
250
+ def labels(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]):
246
251
  pulumi.set(self, "labels", value)
247
252
 
248
253
  @property
@@ -261,7 +266,7 @@ class _FloatingIpState:
261
266
  @pulumi.getter(name="serverId")
262
267
  def server_id(self) -> Optional[pulumi.Input[int]]:
263
268
  """
264
- Server to assign the Floating IP to.
269
+ Server to assign the Floating IP to. Optional if `home_location` argument is passed.
265
270
  """
266
271
  return pulumi.get(self, "server_id")
267
272
 
@@ -290,7 +295,7 @@ class FloatingIp(pulumi.CustomResource):
290
295
  delete_protection: Optional[pulumi.Input[bool]] = None,
291
296
  description: Optional[pulumi.Input[str]] = None,
292
297
  home_location: Optional[pulumi.Input[str]] = None,
293
- labels: Optional[pulumi.Input[Mapping[str, Any]]] = None,
298
+ labels: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
294
299
  name: Optional[pulumi.Input[str]] = None,
295
300
  server_id: Optional[pulumi.Input[int]] = None,
296
301
  type: Optional[pulumi.Input[str]] = None,
@@ -300,36 +305,35 @@ class FloatingIp(pulumi.CustomResource):
300
305
 
301
306
  ## Example Usage
302
307
 
303
- <!--Start PulumiCodeChooser -->
304
308
  ```python
305
309
  import pulumi
306
310
  import pulumi_hcloud as hcloud
307
311
 
308
312
  node1 = hcloud.Server("node1",
313
+ name="node1",
309
314
  image="debian-11",
310
- server_type="cx11")
315
+ server_type="cx22")
311
316
  master = hcloud.FloatingIp("master",
312
317
  type="ipv4",
313
318
  server_id=node1.id)
314
319
  ```
315
- <!--End PulumiCodeChooser -->
316
320
 
317
321
  ## Import
318
322
 
319
323
  Floating IPs can be imported using its `id`:
320
324
 
321
325
  ```sh
322
- $ pulumi import hcloud:index/floatingIp:FloatingIp myip id
326
+ $ pulumi import hcloud:index/floatingIp:FloatingIp example "$FLOATING_IP_ID"
323
327
  ```
324
328
 
325
329
  :param str resource_name: The name of the resource.
326
330
  :param pulumi.ResourceOptions opts: Options for the resource.
327
331
  :param pulumi.Input[bool] delete_protection: Enable or disable delete protection. See "Delete Protection" in the Provider Docs for details.
328
332
  :param pulumi.Input[str] description: Description of the Floating IP.
329
- :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if server_id argument is passed.
330
- :param pulumi.Input[Mapping[str, Any]] labels: User-defined labels (key-value pairs) should be created with.
333
+ :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if `server_id` argument is passed.
334
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] labels: User-defined labels (key-value pairs) should be created with.
331
335
  :param pulumi.Input[str] name: Name of the Floating IP.
332
- :param pulumi.Input[int] server_id: Server to assign the Floating IP to.
336
+ :param pulumi.Input[int] server_id: Server to assign the Floating IP to. Optional if `home_location` argument is passed.
333
337
  :param pulumi.Input[str] type: Type of the Floating IP. `ipv4` `ipv6`
334
338
  """
335
339
  ...
@@ -343,26 +347,25 @@ class FloatingIp(pulumi.CustomResource):
343
347
 
344
348
  ## Example Usage
345
349
 
346
- <!--Start PulumiCodeChooser -->
347
350
  ```python
348
351
  import pulumi
349
352
  import pulumi_hcloud as hcloud
350
353
 
351
354
  node1 = hcloud.Server("node1",
355
+ name="node1",
352
356
  image="debian-11",
353
- server_type="cx11")
357
+ server_type="cx22")
354
358
  master = hcloud.FloatingIp("master",
355
359
  type="ipv4",
356
360
  server_id=node1.id)
357
361
  ```
358
- <!--End PulumiCodeChooser -->
359
362
 
360
363
  ## Import
361
364
 
362
365
  Floating IPs can be imported using its `id`:
363
366
 
364
367
  ```sh
365
- $ pulumi import hcloud:index/floatingIp:FloatingIp myip id
368
+ $ pulumi import hcloud:index/floatingIp:FloatingIp example "$FLOATING_IP_ID"
366
369
  ```
367
370
 
368
371
  :param str resource_name: The name of the resource.
@@ -383,7 +386,7 @@ class FloatingIp(pulumi.CustomResource):
383
386
  delete_protection: Optional[pulumi.Input[bool]] = None,
384
387
  description: Optional[pulumi.Input[str]] = None,
385
388
  home_location: Optional[pulumi.Input[str]] = None,
386
- labels: Optional[pulumi.Input[Mapping[str, Any]]] = None,
389
+ labels: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
387
390
  name: Optional[pulumi.Input[str]] = None,
388
391
  server_id: Optional[pulumi.Input[int]] = None,
389
392
  type: Optional[pulumi.Input[str]] = None,
@@ -422,7 +425,7 @@ class FloatingIp(pulumi.CustomResource):
422
425
  home_location: Optional[pulumi.Input[str]] = None,
423
426
  ip_address: Optional[pulumi.Input[str]] = None,
424
427
  ip_network: Optional[pulumi.Input[str]] = None,
425
- labels: Optional[pulumi.Input[Mapping[str, Any]]] = None,
428
+ labels: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
426
429
  name: Optional[pulumi.Input[str]] = None,
427
430
  server_id: Optional[pulumi.Input[int]] = None,
428
431
  type: Optional[pulumi.Input[str]] = None) -> 'FloatingIp':
@@ -435,12 +438,12 @@ class FloatingIp(pulumi.CustomResource):
435
438
  :param pulumi.ResourceOptions opts: Options for the resource.
436
439
  :param pulumi.Input[bool] delete_protection: Enable or disable delete protection. See "Delete Protection" in the Provider Docs for details.
437
440
  :param pulumi.Input[str] description: Description of the Floating IP.
438
- :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if server_id argument is passed.
441
+ :param pulumi.Input[str] home_location: Name of home location (routing is optimized for that location). Optional if `server_id` argument is passed.
439
442
  :param pulumi.Input[str] ip_address: (string) IP Address of the Floating IP.
440
443
  :param pulumi.Input[str] ip_network: (string) IPv6 subnet. (Only set if `type` is `ipv6`)
441
- :param pulumi.Input[Mapping[str, Any]] labels: User-defined labels (key-value pairs) should be created with.
444
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] labels: User-defined labels (key-value pairs) should be created with.
442
445
  :param pulumi.Input[str] name: Name of the Floating IP.
443
- :param pulumi.Input[int] server_id: Server to assign the Floating IP to.
446
+ :param pulumi.Input[int] server_id: Server to assign the Floating IP to. Optional if `home_location` argument is passed.
444
447
  :param pulumi.Input[str] type: Type of the Floating IP. `ipv4` `ipv6`
445
448
  """
446
449
  opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
@@ -478,7 +481,7 @@ class FloatingIp(pulumi.CustomResource):
478
481
  @pulumi.getter(name="homeLocation")
479
482
  def home_location(self) -> pulumi.Output[str]:
480
483
  """
481
- Name of home location (routing is optimized for that location). Optional if server_id argument is passed.
484
+ Name of home location (routing is optimized for that location). Optional if `server_id` argument is passed.
482
485
  """
483
486
  return pulumi.get(self, "home_location")
484
487
 
@@ -500,7 +503,7 @@ class FloatingIp(pulumi.CustomResource):
500
503
 
501
504
  @property
502
505
  @pulumi.getter
503
- def labels(self) -> pulumi.Output[Optional[Mapping[str, Any]]]:
506
+ def labels(self) -> pulumi.Output[Optional[Mapping[str, str]]]:
504
507
  """
505
508
  User-defined labels (key-value pairs) should be created with.
506
509
  """
@@ -518,7 +521,7 @@ class FloatingIp(pulumi.CustomResource):
518
521
  @pulumi.getter(name="serverId")
519
522
  def server_id(self) -> pulumi.Output[int]:
520
523
  """
521
- Server to assign the Floating IP to.
524
+ Server to assign the Floating IP to. Optional if `home_location` argument is passed.
522
525
  """
523
526
  return pulumi.get(self, "server_id")
524
527
 
@@ -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__ = ['FloatingIpAssignmentArgs', 'FloatingIpAssignment']
@@ -102,14 +107,14 @@ class FloatingIpAssignment(pulumi.CustomResource):
102
107
 
103
108
  ## Example Usage
104
109
 
105
- <!--Start PulumiCodeChooser -->
106
110
  ```python
107
111
  import pulumi
108
112
  import pulumi_hcloud as hcloud
109
113
 
110
114
  node1 = hcloud.Server("node1",
115
+ name="node1",
111
116
  image="debian-11",
112
- server_type="cx11",
117
+ server_type="cx22",
113
118
  datacenter="fsn1-dc8")
114
119
  master = hcloud.FloatingIp("master",
115
120
  type="ipv4",
@@ -118,14 +123,13 @@ class FloatingIpAssignment(pulumi.CustomResource):
118
123
  floating_ip_id=master.id,
119
124
  server_id=node1.id)
120
125
  ```
121
- <!--End PulumiCodeChooser -->
122
126
 
123
127
  ## Import
124
128
 
125
129
  Floating IP Assignments can be imported using the `floating_ip_id`:
126
130
 
127
131
  ```sh
128
- $ pulumi import hcloud:index/floatingIpAssignment:FloatingIpAssignment myfloatingipassignment <floating_ip_id>
132
+ $ pulumi import hcloud:index/floatingIpAssignment:FloatingIpAssignment example "$FLOATING_IP_ID"
129
133
  ```
130
134
 
131
135
  :param str resource_name: The name of the resource.
@@ -144,14 +148,14 @@ class FloatingIpAssignment(pulumi.CustomResource):
144
148
 
145
149
  ## Example Usage
146
150
 
147
- <!--Start PulumiCodeChooser -->
148
151
  ```python
149
152
  import pulumi
150
153
  import pulumi_hcloud as hcloud
151
154
 
152
155
  node1 = hcloud.Server("node1",
156
+ name="node1",
153
157
  image="debian-11",
154
- server_type="cx11",
158
+ server_type="cx22",
155
159
  datacenter="fsn1-dc8")
156
160
  master = hcloud.FloatingIp("master",
157
161
  type="ipv4",
@@ -160,14 +164,13 @@ class FloatingIpAssignment(pulumi.CustomResource):
160
164
  floating_ip_id=master.id,
161
165
  server_id=node1.id)
162
166
  ```
163
- <!--End PulumiCodeChooser -->
164
167
 
165
168
  ## Import
166
169
 
167
170
  Floating IP Assignments can be imported using the `floating_ip_id`:
168
171
 
169
172
  ```sh
170
- $ pulumi import hcloud:index/floatingIpAssignment:FloatingIpAssignment myfloatingipassignment <floating_ip_id>
173
+ $ pulumi import hcloud:index/floatingIpAssignment:FloatingIpAssignment example "$FLOATING_IP_ID"
171
174
  ```
172
175
 
173
176
  :param str resource_name: The name of the resource.
@@ -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__ = [
@@ -98,7 +103,7 @@ class GetCertificateResult:
98
103
 
99
104
  @property
100
105
  @pulumi.getter
101
- def labels(self) -> Mapping[str, Any]:
106
+ def labels(self) -> Mapping[str, str]:
102
107
  """
103
108
  (map) User-defined labels (key-value pairs) assigned to the certificate.
104
109
  """
@@ -165,7 +170,6 @@ def get_certificate(id: Optional[int] = None,
165
170
  """
166
171
  Provides details about a specific Hetzner Cloud Certificate.
167
172
 
168
- <!--Start PulumiCodeChooser -->
169
173
  ```python
170
174
  import pulumi
171
175
  import pulumi_hcloud as hcloud
@@ -173,7 +177,6 @@ def get_certificate(id: Optional[int] = None,
173
177
  sample_certificate1 = hcloud.get_certificate(name="sample-certificate-1")
174
178
  sample_certificate2 = hcloud.get_certificate(id=4711)
175
179
  ```
176
- <!--End PulumiCodeChooser -->
177
180
 
178
181
 
179
182
  :param int id: ID of the certificate.
@@ -199,17 +202,13 @@ def get_certificate(id: Optional[int] = None,
199
202
  not_valid_before=pulumi.get(__ret__, 'not_valid_before'),
200
203
  type=pulumi.get(__ret__, 'type'),
201
204
  with_selector=pulumi.get(__ret__, 'with_selector'))
202
-
203
-
204
- @_utilities.lift_output_func(get_certificate)
205
205
  def get_certificate_output(id: Optional[pulumi.Input[Optional[int]]] = None,
206
206
  name: Optional[pulumi.Input[Optional[str]]] = None,
207
207
  with_selector: Optional[pulumi.Input[Optional[str]]] = None,
208
- opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetCertificateResult]:
208
+ opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetCertificateResult]:
209
209
  """
210
210
  Provides details about a specific Hetzner Cloud Certificate.
211
211
 
212
- <!--Start PulumiCodeChooser -->
213
212
  ```python
214
213
  import pulumi
215
214
  import pulumi_hcloud as hcloud
@@ -217,11 +216,27 @@ def get_certificate_output(id: Optional[pulumi.Input[Optional[int]]] = None,
217
216
  sample_certificate1 = hcloud.get_certificate(name="sample-certificate-1")
218
217
  sample_certificate2 = hcloud.get_certificate(id=4711)
219
218
  ```
220
- <!--End PulumiCodeChooser -->
221
219
 
222
220
 
223
221
  :param int id: ID of the certificate.
224
222
  :param str name: Name of the certificate.
225
223
  :param str with_selector: [Label selector](https://docs.hetzner.cloud/#overview-label-selector)
226
224
  """
227
- ...
225
+ __args__ = dict()
226
+ __args__['id'] = id
227
+ __args__['name'] = name
228
+ __args__['withSelector'] = with_selector
229
+ opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
230
+ __ret__ = pulumi.runtime.invoke_output('hcloud:index/getCertificate:getCertificate', __args__, opts=opts, typ=GetCertificateResult)
231
+ return __ret__.apply(lambda __response__: GetCertificateResult(
232
+ certificate=pulumi.get(__response__, 'certificate'),
233
+ created=pulumi.get(__response__, 'created'),
234
+ domain_names=pulumi.get(__response__, 'domain_names'),
235
+ fingerprint=pulumi.get(__response__, 'fingerprint'),
236
+ id=pulumi.get(__response__, 'id'),
237
+ labels=pulumi.get(__response__, 'labels'),
238
+ name=pulumi.get(__response__, 'name'),
239
+ not_valid_after=pulumi.get(__response__, 'not_valid_after'),
240
+ not_valid_before=pulumi.get(__response__, 'not_valid_before'),
241
+ type=pulumi.get(__response__, 'type'),
242
+ with_selector=pulumi.get(__response__, 'with_selector')))
@@ -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
  from . import outputs
12
17
 
@@ -73,14 +78,12 @@ def get_certificates(with_selector: Optional[str] = None,
73
78
 
74
79
  ## Example Usage
75
80
 
76
- <!--Start PulumiCodeChooser -->
77
81
  ```python
78
82
  import pulumi
79
83
  import pulumi_hcloud as hcloud
80
84
 
81
85
  sample_certificate1 = hcloud.get_certificates(with_selector="key=value")
82
86
  ```
83
- <!--End PulumiCodeChooser -->
84
87
 
85
88
 
86
89
  :param str with_selector: [Label selector](https://docs.hetzner.cloud/#overview-label-selector)
@@ -94,26 +97,28 @@ def get_certificates(with_selector: Optional[str] = None,
94
97
  certificates=pulumi.get(__ret__, 'certificates'),
95
98
  id=pulumi.get(__ret__, 'id'),
96
99
  with_selector=pulumi.get(__ret__, 'with_selector'))
97
-
98
-
99
- @_utilities.lift_output_func(get_certificates)
100
100
  def get_certificates_output(with_selector: Optional[pulumi.Input[Optional[str]]] = None,
101
- opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetCertificatesResult]:
101
+ opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetCertificatesResult]:
102
102
  """
103
103
  Provides details about multiple Hetzner Cloud Certificates.
104
104
 
105
105
  ## Example Usage
106
106
 
107
- <!--Start PulumiCodeChooser -->
108
107
  ```python
109
108
  import pulumi
110
109
  import pulumi_hcloud as hcloud
111
110
 
112
111
  sample_certificate1 = hcloud.get_certificates(with_selector="key=value")
113
112
  ```
114
- <!--End PulumiCodeChooser -->
115
113
 
116
114
 
117
115
  :param str with_selector: [Label selector](https://docs.hetzner.cloud/#overview-label-selector)
118
116
  """
119
- ...
117
+ __args__ = dict()
118
+ __args__['withSelector'] = with_selector
119
+ opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
120
+ __ret__ = pulumi.runtime.invoke_output('hcloud:index/getCertificates:getCertificates', __args__, opts=opts, typ=GetCertificatesResult)
121
+ return __ret__.apply(lambda __response__: GetCertificatesResult(
122
+ certificates=pulumi.get(__response__, 'certificates'),
123
+ id=pulumi.get(__response__, 'id'),
124
+ with_selector=pulumi.get(__response__, 'with_selector')))
@@ -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__ = [
@@ -45,7 +50,7 @@ class GetDatacenterResult:
45
50
  @pulumi.getter(name="availableServerTypeIds")
46
51
  def available_server_type_ids(self) -> Sequence[int]:
47
52
  """
48
- (list) List of available server types.
53
+ List of currently available Server Types in the Datacenter.
49
54
  """
50
55
  return pulumi.get(self, "available_server_type_ids")
51
56
 
@@ -53,15 +58,15 @@ class GetDatacenterResult:
53
58
  @pulumi.getter
54
59
  def description(self) -> str:
55
60
  """
56
- (string) Description of the datacenter.
61
+ Description of the Datacenter.
57
62
  """
58
63
  return pulumi.get(self, "description")
59
64
 
60
65
  @property
61
66
  @pulumi.getter
62
- def id(self) -> int:
67
+ def id(self) -> Optional[int]:
63
68
  """
64
- (int) Unique ID of the datacenter.
69
+ ID of the Datacenter.
65
70
  """
66
71
  return pulumi.get(self, "id")
67
72
 
@@ -69,15 +74,15 @@ class GetDatacenterResult:
69
74
  @pulumi.getter
70
75
  def location(self) -> Mapping[str, str]:
71
76
  """
72
- (map) Physical datacenter location.
77
+ Location of the Datacenter. See the [Hetzner Docs](https://docs.hetzner.com/cloud/general/locations/#what-locations-are-there) for more details about locations.
73
78
  """
74
79
  return pulumi.get(self, "location")
75
80
 
76
81
  @property
77
82
  @pulumi.getter
78
- def name(self) -> str:
83
+ def name(self) -> Optional[str]:
79
84
  """
80
- (string) Name of the datacenter.
85
+ Name of the Datacenter.
81
86
  """
82
87
  return pulumi.get(self, "name")
83
88
 
@@ -85,7 +90,7 @@ class GetDatacenterResult:
85
90
  @pulumi.getter(name="supportedServerTypeIds")
86
91
  def supported_server_type_ids(self) -> Sequence[int]:
87
92
  """
88
- (list) List of server types supported by the datacenter.
93
+ List of supported Server Types in the Datacenter.
89
94
  """
90
95
  return pulumi.get(self, "supported_server_type_ids")
91
96
 
@@ -109,23 +114,22 @@ def get_datacenter(id: Optional[int] = None,
109
114
  opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetDatacenterResult:
110
115
  """
111
116
  Provides details about a specific Hetzner Cloud Datacenter.
112
- Use this resource to get detailed information about specific datacenter.
117
+
118
+ Use this resource to get detailed information about a specific Datacenter.
113
119
 
114
120
  ## Example Usage
115
121
 
116
- <!--Start PulumiCodeChooser -->
117
122
  ```python
118
123
  import pulumi
119
124
  import pulumi_hcloud as hcloud
120
125
 
121
- ds1 = hcloud.get_datacenter(name="fsn1-dc8")
122
- ds2 = hcloud.get_datacenter(id=4)
126
+ by_id = hcloud.get_datacenter(id=4)
127
+ by_name = hcloud.get_datacenter(name="fsn1-dc14")
123
128
  ```
124
- <!--End PulumiCodeChooser -->
125
129
 
126
130
 
127
- :param int id: ID of the datacenter.
128
- :param str name: Name of the datacenter.
131
+ :param int id: ID of the Datacenter.
132
+ :param str name: Name of the Datacenter.
129
133
  """
130
134
  __args__ = dict()
131
135
  __args__['id'] = id
@@ -140,30 +144,37 @@ def get_datacenter(id: Optional[int] = None,
140
144
  location=pulumi.get(__ret__, 'location'),
141
145
  name=pulumi.get(__ret__, 'name'),
142
146
  supported_server_type_ids=pulumi.get(__ret__, 'supported_server_type_ids'))
143
-
144
-
145
- @_utilities.lift_output_func(get_datacenter)
146
147
  def get_datacenter_output(id: Optional[pulumi.Input[Optional[int]]] = None,
147
148
  name: Optional[pulumi.Input[Optional[str]]] = None,
148
- opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDatacenterResult]:
149
+ opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatacenterResult]:
149
150
  """
150
151
  Provides details about a specific Hetzner Cloud Datacenter.
151
- Use this resource to get detailed information about specific datacenter.
152
+
153
+ Use this resource to get detailed information about a specific Datacenter.
152
154
 
153
155
  ## Example Usage
154
156
 
155
- <!--Start PulumiCodeChooser -->
156
157
  ```python
157
158
  import pulumi
158
159
  import pulumi_hcloud as hcloud
159
160
 
160
- ds1 = hcloud.get_datacenter(name="fsn1-dc8")
161
- ds2 = hcloud.get_datacenter(id=4)
161
+ by_id = hcloud.get_datacenter(id=4)
162
+ by_name = hcloud.get_datacenter(name="fsn1-dc14")
162
163
  ```
163
- <!--End PulumiCodeChooser -->
164
164
 
165
165
 
166
- :param int id: ID of the datacenter.
167
- :param str name: Name of the datacenter.
166
+ :param int id: ID of the Datacenter.
167
+ :param str name: Name of the Datacenter.
168
168
  """
169
- ...
169
+ __args__ = dict()
170
+ __args__['id'] = id
171
+ __args__['name'] = name
172
+ opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
173
+ __ret__ = pulumi.runtime.invoke_output('hcloud:index/getDatacenter:getDatacenter', __args__, opts=opts, typ=GetDatacenterResult)
174
+ return __ret__.apply(lambda __response__: GetDatacenterResult(
175
+ available_server_type_ids=pulumi.get(__response__, 'available_server_type_ids'),
176
+ description=pulumi.get(__response__, 'description'),
177
+ id=pulumi.get(__response__, 'id'),
178
+ location=pulumi.get(__response__, 'location'),
179
+ name=pulumi.get(__response__, 'name'),
180
+ supported_server_type_ids=pulumi.get(__response__, 'supported_server_type_ids')))