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.
- pulumi_hcloud/__init__.py +2 -0
- pulumi_hcloud/_inputs.py +247 -15
- pulumi_hcloud/_utilities.py +41 -5
- pulumi_hcloud/certificate.py +15 -10
- pulumi_hcloud/config/__init__.pyi +5 -0
- pulumi_hcloud/config/vars.py +5 -0
- pulumi_hcloud/firewall.py +77 -70
- pulumi_hcloud/firewall_attachment.py +27 -26
- pulumi_hcloud/floating_ip.py +39 -36
- pulumi_hcloud/floating_ip_assignment.py +11 -8
- pulumi_hcloud/get_certificate.py +25 -10
- pulumi_hcloud/get_certificates.py +14 -9
- pulumi_hcloud/get_datacenter.py +38 -27
- pulumi_hcloud/get_datacenters.py +28 -53
- pulumi_hcloud/get_firewall.py +38 -23
- pulumi_hcloud/get_firewalls.py +16 -9
- pulumi_hcloud/get_floating_ip.py +37 -17
- pulumi_hcloud/get_floating_ips.py +14 -9
- pulumi_hcloud/get_image.py +37 -13
- pulumi_hcloud/get_images.py +22 -9
- pulumi_hcloud/get_load_balancer.py +30 -11
- pulumi_hcloud/get_load_balancer_type.py +202 -0
- pulumi_hcloud/get_load_balancer_types.py +100 -0
- pulumi_hcloud/get_load_balancers.py +14 -9
- pulumi_hcloud/get_location.py +42 -29
- pulumi_hcloud/get_locations.py +28 -53
- pulumi_hcloud/get_network.py +28 -15
- pulumi_hcloud/get_networks.py +14 -9
- pulumi_hcloud/get_placement_group.py +31 -17
- pulumi_hcloud/get_placement_groups.py +16 -9
- pulumi_hcloud/get_primary_ip.py +42 -22
- pulumi_hcloud/get_primary_ips.py +14 -9
- pulumi_hcloud/get_server.py +43 -15
- pulumi_hcloud/get_server_type.py +75 -53
- pulumi_hcloud/get_server_types.py +39 -23
- pulumi_hcloud/get_servers.py +16 -9
- pulumi_hcloud/get_ssh_key.py +58 -36
- pulumi_hcloud/get_ssh_keys.py +35 -24
- pulumi_hcloud/get_volume.py +33 -16
- pulumi_hcloud/get_volumes.py +18 -11
- pulumi_hcloud/load_balancer.py +63 -64
- pulumi_hcloud/load_balancer_network.py +26 -17
- pulumi_hcloud/load_balancer_service.py +57 -54
- pulumi_hcloud/load_balancer_target.py +23 -18
- pulumi_hcloud/managed_certificate.py +57 -20
- pulumi_hcloud/network.py +27 -22
- pulumi_hcloud/network_route.py +13 -8
- pulumi_hcloud/network_subnet.py +13 -8
- pulumi_hcloud/outputs.py +265 -46
- pulumi_hcloud/placement_group.py +27 -22
- pulumi_hcloud/primary_ip.py +66 -47
- pulumi_hcloud/provider.py +5 -0
- pulumi_hcloud/pulumi-plugin.json +2 -1
- pulumi_hcloud/rdns.py +41 -40
- pulumi_hcloud/server.py +123 -176
- pulumi_hcloud/server_network.py +24 -17
- pulumi_hcloud/snapshot.py +25 -22
- pulumi_hcloud/ssh_key.py +52 -51
- pulumi_hcloud/uploaded_certificate.py +73 -20
- pulumi_hcloud/volume.py +37 -32
- pulumi_hcloud/volume_attachment.py +11 -8
- {pulumi_hcloud-1.18.0a1710156455.dist-info → pulumi_hcloud-1.22.0a1736849475.dist-info}/METADATA +7 -6
- pulumi_hcloud-1.22.0a1736849475.dist-info/RECORD +67 -0
- {pulumi_hcloud-1.18.0a1710156455.dist-info → pulumi_hcloud-1.22.0a1736849475.dist-info}/WHEEL +1 -1
- pulumi_hcloud-1.18.0a1710156455.dist-info/RECORD +0 -65
- {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
|
from . import outputs
|
|
12
17
|
|
|
@@ -41,42 +46,33 @@ class GetServerTypesResult:
|
|
|
41
46
|
|
|
42
47
|
@property
|
|
43
48
|
@pulumi.getter
|
|
49
|
+
@_utilities.deprecated("""Use server_types list instead""")
|
|
44
50
|
def descriptions(self) -> Sequence[str]:
|
|
45
|
-
warnings.warn("""Use server_types list instead""", DeprecationWarning)
|
|
46
|
-
pulumi.log.warn("""descriptions is deprecated: Use server_types list instead""")
|
|
47
|
-
|
|
48
51
|
return pulumi.get(self, "descriptions")
|
|
49
52
|
|
|
50
53
|
@property
|
|
51
54
|
@pulumi.getter
|
|
52
55
|
def id(self) -> str:
|
|
53
56
|
"""
|
|
54
|
-
The
|
|
57
|
+
The ID of this resource.
|
|
55
58
|
"""
|
|
56
59
|
return pulumi.get(self, "id")
|
|
57
60
|
|
|
58
61
|
@property
|
|
59
62
|
@pulumi.getter
|
|
63
|
+
@_utilities.deprecated("""Use server_types list instead""")
|
|
60
64
|
def names(self) -> Sequence[str]:
|
|
61
|
-
warnings.warn("""Use server_types list instead""", DeprecationWarning)
|
|
62
|
-
pulumi.log.warn("""names is deprecated: Use server_types list instead""")
|
|
63
|
-
|
|
64
65
|
return pulumi.get(self, "names")
|
|
65
66
|
|
|
66
67
|
@property
|
|
67
68
|
@pulumi.getter(name="serverTypeIds")
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
pulumi.log.warn("""server_type_ids is deprecated: Use server_types list instead""")
|
|
71
|
-
|
|
69
|
+
@_utilities.deprecated("""Use server_types list instead""")
|
|
70
|
+
def server_type_ids(self) -> Sequence[str]:
|
|
72
71
|
return pulumi.get(self, "server_type_ids")
|
|
73
72
|
|
|
74
73
|
@property
|
|
75
74
|
@pulumi.getter(name="serverTypes")
|
|
76
75
|
def server_types(self) -> Sequence['outputs.GetServerTypesServerTypeResult']:
|
|
77
|
-
"""
|
|
78
|
-
(list) List of all server types. See `data.hcloud_type` for schema.
|
|
79
|
-
"""
|
|
80
76
|
return pulumi.get(self, "server_types")
|
|
81
77
|
|
|
82
78
|
|
|
@@ -93,13 +89,20 @@ class AwaitableGetServerTypesResult(GetServerTypesResult):
|
|
|
93
89
|
server_types=self.server_types)
|
|
94
90
|
|
|
95
91
|
|
|
96
|
-
def get_server_types(
|
|
97
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetServerTypesResult:
|
|
92
|
+
def get_server_types(opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetServerTypesResult:
|
|
98
93
|
"""
|
|
99
94
|
Provides a list of available Hetzner Cloud Server Types.
|
|
95
|
+
|
|
96
|
+
## Example Usage
|
|
97
|
+
|
|
98
|
+
```python
|
|
99
|
+
import pulumi
|
|
100
|
+
import pulumi_hcloud as hcloud
|
|
101
|
+
|
|
102
|
+
all = hcloud.get_server_types()
|
|
103
|
+
```
|
|
100
104
|
"""
|
|
101
105
|
__args__ = dict()
|
|
102
|
-
__args__['serverTypeIds'] = server_type_ids
|
|
103
106
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
104
107
|
__ret__ = pulumi.runtime.invoke('hcloud:index/getServerTypes:getServerTypes', __args__, opts=opts, typ=GetServerTypesResult).value
|
|
105
108
|
|
|
@@ -109,12 +112,25 @@ def get_server_types(server_type_ids: Optional[Sequence[str]] = None,
|
|
|
109
112
|
names=pulumi.get(__ret__, 'names'),
|
|
110
113
|
server_type_ids=pulumi.get(__ret__, 'server_type_ids'),
|
|
111
114
|
server_types=pulumi.get(__ret__, 'server_types'))
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
@_utilities.lift_output_func(get_server_types)
|
|
115
|
-
def get_server_types_output(server_type_ids: Optional[pulumi.Input[Optional[Sequence[str]]]] = None,
|
|
116
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetServerTypesResult]:
|
|
115
|
+
def get_server_types_output(opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetServerTypesResult]:
|
|
117
116
|
"""
|
|
118
117
|
Provides a list of available Hetzner Cloud Server Types.
|
|
118
|
+
|
|
119
|
+
## Example Usage
|
|
120
|
+
|
|
121
|
+
```python
|
|
122
|
+
import pulumi
|
|
123
|
+
import pulumi_hcloud as hcloud
|
|
124
|
+
|
|
125
|
+
all = hcloud.get_server_types()
|
|
126
|
+
```
|
|
119
127
|
"""
|
|
120
|
-
|
|
128
|
+
__args__ = dict()
|
|
129
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
130
|
+
__ret__ = pulumi.runtime.invoke_output('hcloud:index/getServerTypes:getServerTypes', __args__, opts=opts, typ=GetServerTypesResult)
|
|
131
|
+
return __ret__.apply(lambda __response__: GetServerTypesResult(
|
|
132
|
+
descriptions=pulumi.get(__response__, 'descriptions'),
|
|
133
|
+
id=pulumi.get(__response__, 'id'),
|
|
134
|
+
names=pulumi.get(__response__, 'names'),
|
|
135
|
+
server_type_ids=pulumi.get(__response__, 'server_type_ids'),
|
|
136
|
+
server_types=pulumi.get(__response__, 'server_types')))
|
pulumi_hcloud/get_servers.py
CHANGED
|
@@ -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
|
|
|
@@ -81,14 +86,12 @@ def get_servers(with_selector: Optional[str] = None,
|
|
|
81
86
|
"""
|
|
82
87
|
## Example Usage
|
|
83
88
|
|
|
84
|
-
<!--Start PulumiCodeChooser -->
|
|
85
89
|
```python
|
|
86
90
|
import pulumi
|
|
87
91
|
import pulumi_hcloud as hcloud
|
|
88
92
|
|
|
89
93
|
s3 = hcloud.get_servers(with_selector="key=value")
|
|
90
94
|
```
|
|
91
|
-
<!--End PulumiCodeChooser -->
|
|
92
95
|
|
|
93
96
|
|
|
94
97
|
:param str with_selector: Label Selector. For more information about possible values, visit the [Hetzner Cloud Documentation](https://docs.hetzner.cloud/#overview-label-selector).
|
|
@@ -105,26 +108,30 @@ def get_servers(with_selector: Optional[str] = None,
|
|
|
105
108
|
servers=pulumi.get(__ret__, 'servers'),
|
|
106
109
|
with_selector=pulumi.get(__ret__, 'with_selector'),
|
|
107
110
|
with_statuses=pulumi.get(__ret__, 'with_statuses'))
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
@_utilities.lift_output_func(get_servers)
|
|
111
111
|
def get_servers_output(with_selector: Optional[pulumi.Input[Optional[str]]] = None,
|
|
112
112
|
with_statuses: Optional[pulumi.Input[Optional[Sequence[str]]]] = None,
|
|
113
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetServersResult]:
|
|
113
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetServersResult]:
|
|
114
114
|
"""
|
|
115
115
|
## Example Usage
|
|
116
116
|
|
|
117
|
-
<!--Start PulumiCodeChooser -->
|
|
118
117
|
```python
|
|
119
118
|
import pulumi
|
|
120
119
|
import pulumi_hcloud as hcloud
|
|
121
120
|
|
|
122
121
|
s3 = hcloud.get_servers(with_selector="key=value")
|
|
123
122
|
```
|
|
124
|
-
<!--End PulumiCodeChooser -->
|
|
125
123
|
|
|
126
124
|
|
|
127
125
|
:param str with_selector: Label Selector. For more information about possible values, visit the [Hetzner Cloud Documentation](https://docs.hetzner.cloud/#overview-label-selector).
|
|
128
126
|
:param Sequence[str] with_statuses: List only servers with the specified status, could contain `initializing`, `starting`, `running`, `stopping`, `off`, `deleting`, `rebuilding`, `migrating`, `unknown`.
|
|
129
127
|
"""
|
|
130
|
-
|
|
128
|
+
__args__ = dict()
|
|
129
|
+
__args__['withSelector'] = with_selector
|
|
130
|
+
__args__['withStatuses'] = with_statuses
|
|
131
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
132
|
+
__ret__ = pulumi.runtime.invoke_output('hcloud:index/getServers:getServers', __args__, opts=opts, typ=GetServersResult)
|
|
133
|
+
return __ret__.apply(lambda __response__: GetServersResult(
|
|
134
|
+
id=pulumi.get(__response__, 'id'),
|
|
135
|
+
servers=pulumi.get(__response__, 'servers'),
|
|
136
|
+
with_selector=pulumi.get(__response__, 'with_selector'),
|
|
137
|
+
with_statuses=pulumi.get(__response__, 'with_statuses')))
|
pulumi_hcloud/get_ssh_key.py
CHANGED
|
@@ -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__ = [
|
|
@@ -46,30 +51,33 @@ class GetSshKeyResult:
|
|
|
46
51
|
|
|
47
52
|
@property
|
|
48
53
|
@pulumi.getter
|
|
49
|
-
def fingerprint(self) -> str:
|
|
54
|
+
def fingerprint(self) -> Optional[str]:
|
|
50
55
|
"""
|
|
51
|
-
|
|
56
|
+
Fingerprint of the SSH Key.
|
|
52
57
|
"""
|
|
53
58
|
return pulumi.get(self, "fingerprint")
|
|
54
59
|
|
|
55
60
|
@property
|
|
56
61
|
@pulumi.getter
|
|
57
|
-
def id(self) -> int:
|
|
62
|
+
def id(self) -> Optional[int]:
|
|
58
63
|
"""
|
|
59
|
-
|
|
64
|
+
ID of the SSH Key.
|
|
60
65
|
"""
|
|
61
66
|
return pulumi.get(self, "id")
|
|
62
67
|
|
|
63
68
|
@property
|
|
64
69
|
@pulumi.getter
|
|
65
|
-
def labels(self) -> Mapping[str,
|
|
70
|
+
def labels(self) -> Mapping[str, str]:
|
|
71
|
+
"""
|
|
72
|
+
User-defined [labels](https://docs.hetzner.cloud/#labels) (key-value pairs) for the resource.
|
|
73
|
+
"""
|
|
66
74
|
return pulumi.get(self, "labels")
|
|
67
75
|
|
|
68
76
|
@property
|
|
69
77
|
@pulumi.getter
|
|
70
|
-
def name(self) -> str:
|
|
78
|
+
def name(self) -> Optional[str]:
|
|
71
79
|
"""
|
|
72
|
-
|
|
80
|
+
Name of the SSH Key.
|
|
73
81
|
"""
|
|
74
82
|
return pulumi.get(self, "name")
|
|
75
83
|
|
|
@@ -77,21 +85,25 @@ class GetSshKeyResult:
|
|
|
77
85
|
@pulumi.getter(name="publicKey")
|
|
78
86
|
def public_key(self) -> str:
|
|
79
87
|
"""
|
|
80
|
-
|
|
88
|
+
Public key of the SSH Key pair.
|
|
81
89
|
"""
|
|
82
90
|
return pulumi.get(self, "public_key")
|
|
83
91
|
|
|
84
92
|
@property
|
|
85
93
|
@pulumi.getter
|
|
94
|
+
@_utilities.deprecated("""Please use the with_selector property instead.""")
|
|
86
95
|
def selector(self) -> Optional[str]:
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
96
|
+
"""
|
|
97
|
+
Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector).
|
|
98
|
+
"""
|
|
90
99
|
return pulumi.get(self, "selector")
|
|
91
100
|
|
|
92
101
|
@property
|
|
93
102
|
@pulumi.getter(name="withSelector")
|
|
94
103
|
def with_selector(self) -> Optional[str]:
|
|
104
|
+
"""
|
|
105
|
+
Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector).
|
|
106
|
+
"""
|
|
95
107
|
return pulumi.get(self, "with_selector")
|
|
96
108
|
|
|
97
109
|
|
|
@@ -119,28 +131,27 @@ def get_ssh_key(fingerprint: Optional[str] = None,
|
|
|
119
131
|
"""
|
|
120
132
|
## Example Usage
|
|
121
133
|
|
|
122
|
-
<!--Start PulumiCodeChooser -->
|
|
123
134
|
```python
|
|
124
135
|
import pulumi
|
|
125
136
|
import pulumi_hcloud as hcloud
|
|
126
137
|
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
138
|
+
by_id = hcloud.get_ssh_key(id=24332897)
|
|
139
|
+
by_name = hcloud.get_ssh_key(name="my-ssh-key")
|
|
140
|
+
by_fingerprint = hcloud.get_ssh_key(fingerprint="55:58:dc:bd:61:6e:7d:24:07:a7:7d:9b:be:99:83:a8")
|
|
141
|
+
by_label = hcloud.get_ssh_key(with_selector="key=value")
|
|
131
142
|
main = hcloud.Server("main", ssh_keys=[
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
143
|
+
by_id.id,
|
|
144
|
+
by_name.id,
|
|
145
|
+
by_fingerprint.id,
|
|
135
146
|
])
|
|
136
147
|
```
|
|
137
|
-
<!--End PulumiCodeChooser -->
|
|
138
148
|
|
|
139
149
|
|
|
140
150
|
:param str fingerprint: Fingerprint of the SSH Key.
|
|
141
151
|
:param int id: ID of the SSH Key.
|
|
142
152
|
:param str name: Name of the SSH Key.
|
|
143
|
-
:param str
|
|
153
|
+
:param str selector: Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector).
|
|
154
|
+
:param str with_selector: Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector).
|
|
144
155
|
"""
|
|
145
156
|
__args__ = dict()
|
|
146
157
|
__args__['fingerprint'] = fingerprint
|
|
@@ -159,39 +170,50 @@ def get_ssh_key(fingerprint: Optional[str] = None,
|
|
|
159
170
|
public_key=pulumi.get(__ret__, 'public_key'),
|
|
160
171
|
selector=pulumi.get(__ret__, 'selector'),
|
|
161
172
|
with_selector=pulumi.get(__ret__, 'with_selector'))
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
@_utilities.lift_output_func(get_ssh_key)
|
|
165
173
|
def get_ssh_key_output(fingerprint: Optional[pulumi.Input[Optional[str]]] = None,
|
|
166
174
|
id: Optional[pulumi.Input[Optional[int]]] = None,
|
|
167
175
|
name: Optional[pulumi.Input[Optional[str]]] = None,
|
|
168
176
|
selector: Optional[pulumi.Input[Optional[str]]] = None,
|
|
169
177
|
with_selector: Optional[pulumi.Input[Optional[str]]] = None,
|
|
170
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetSshKeyResult]:
|
|
178
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetSshKeyResult]:
|
|
171
179
|
"""
|
|
172
180
|
## Example Usage
|
|
173
181
|
|
|
174
|
-
<!--Start PulumiCodeChooser -->
|
|
175
182
|
```python
|
|
176
183
|
import pulumi
|
|
177
184
|
import pulumi_hcloud as hcloud
|
|
178
185
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
186
|
+
by_id = hcloud.get_ssh_key(id=24332897)
|
|
187
|
+
by_name = hcloud.get_ssh_key(name="my-ssh-key")
|
|
188
|
+
by_fingerprint = hcloud.get_ssh_key(fingerprint="55:58:dc:bd:61:6e:7d:24:07:a7:7d:9b:be:99:83:a8")
|
|
189
|
+
by_label = hcloud.get_ssh_key(with_selector="key=value")
|
|
183
190
|
main = hcloud.Server("main", ssh_keys=[
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
191
|
+
by_id.id,
|
|
192
|
+
by_name.id,
|
|
193
|
+
by_fingerprint.id,
|
|
187
194
|
])
|
|
188
195
|
```
|
|
189
|
-
<!--End PulumiCodeChooser -->
|
|
190
196
|
|
|
191
197
|
|
|
192
198
|
:param str fingerprint: Fingerprint of the SSH Key.
|
|
193
199
|
:param int id: ID of the SSH Key.
|
|
194
200
|
:param str name: Name of the SSH Key.
|
|
195
|
-
:param str
|
|
201
|
+
:param str selector: Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector).
|
|
202
|
+
:param str with_selector: Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector).
|
|
196
203
|
"""
|
|
197
|
-
|
|
204
|
+
__args__ = dict()
|
|
205
|
+
__args__['fingerprint'] = fingerprint
|
|
206
|
+
__args__['id'] = id
|
|
207
|
+
__args__['name'] = name
|
|
208
|
+
__args__['selector'] = selector
|
|
209
|
+
__args__['withSelector'] = with_selector
|
|
210
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
211
|
+
__ret__ = pulumi.runtime.invoke_output('hcloud:index/getSshKey:getSshKey', __args__, opts=opts, typ=GetSshKeyResult)
|
|
212
|
+
return __ret__.apply(lambda __response__: GetSshKeyResult(
|
|
213
|
+
fingerprint=pulumi.get(__response__, 'fingerprint'),
|
|
214
|
+
id=pulumi.get(__response__, 'id'),
|
|
215
|
+
labels=pulumi.get(__response__, 'labels'),
|
|
216
|
+
name=pulumi.get(__response__, 'name'),
|
|
217
|
+
public_key=pulumi.get(__response__, 'public_key'),
|
|
218
|
+
selector=pulumi.get(__response__, 'selector'),
|
|
219
|
+
with_selector=pulumi.get(__response__, 'with_selector')))
|
pulumi_hcloud/get_ssh_keys.py
CHANGED
|
@@ -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
|
|
|
@@ -35,23 +40,23 @@ class GetSshKeysResult:
|
|
|
35
40
|
|
|
36
41
|
@property
|
|
37
42
|
@pulumi.getter
|
|
38
|
-
def id(self) -> str:
|
|
43
|
+
def id(self) -> Optional[str]:
|
|
39
44
|
"""
|
|
40
|
-
The
|
|
45
|
+
The ID of this resource.
|
|
41
46
|
"""
|
|
42
47
|
return pulumi.get(self, "id")
|
|
43
48
|
|
|
44
49
|
@property
|
|
45
50
|
@pulumi.getter(name="sshKeys")
|
|
46
51
|
def ssh_keys(self) -> Sequence['outputs.GetSshKeysSshKeyResult']:
|
|
47
|
-
"""
|
|
48
|
-
(list) List of all matches SSH keys. See `data.hcloud_ssh_key` for schema.
|
|
49
|
-
"""
|
|
50
52
|
return pulumi.get(self, "ssh_keys")
|
|
51
53
|
|
|
52
54
|
@property
|
|
53
55
|
@pulumi.getter(name="withSelector")
|
|
54
56
|
def with_selector(self) -> Optional[str]:
|
|
57
|
+
"""
|
|
58
|
+
Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector)
|
|
59
|
+
"""
|
|
55
60
|
return pulumi.get(self, "with_selector")
|
|
56
61
|
|
|
57
62
|
|
|
@@ -66,26 +71,27 @@ class AwaitableGetSshKeysResult(GetSshKeysResult):
|
|
|
66
71
|
with_selector=self.with_selector)
|
|
67
72
|
|
|
68
73
|
|
|
69
|
-
def get_ssh_keys(
|
|
74
|
+
def get_ssh_keys(id: Optional[str] = None,
|
|
75
|
+
with_selector: Optional[str] = None,
|
|
70
76
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetSshKeysResult:
|
|
71
77
|
"""
|
|
72
78
|
## Example Usage
|
|
73
79
|
|
|
74
|
-
<!--Start PulumiCodeChooser -->
|
|
75
80
|
```python
|
|
76
81
|
import pulumi
|
|
77
82
|
import pulumi_hcloud as hcloud
|
|
78
83
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
main = hcloud.Server("main", ssh_keys=[__item.name for __item in
|
|
84
|
+
all = hcloud.get_ssh_keys()
|
|
85
|
+
by_label = hcloud.get_ssh_keys(with_selector="foo=bar")
|
|
86
|
+
main = hcloud.Server("main", ssh_keys=[__item.name for __item in all.ssh_keys])
|
|
82
87
|
```
|
|
83
|
-
<!--End PulumiCodeChooser -->
|
|
84
88
|
|
|
85
89
|
|
|
86
|
-
:param str
|
|
90
|
+
:param str id: The ID of this resource.
|
|
91
|
+
:param str with_selector: Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector)
|
|
87
92
|
"""
|
|
88
93
|
__args__ = dict()
|
|
94
|
+
__args__['id'] = id
|
|
89
95
|
__args__['withSelector'] = with_selector
|
|
90
96
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
91
97
|
__ret__ = pulumi.runtime.invoke('hcloud:index/getSshKeys:getSshKeys', __args__, opts=opts, typ=GetSshKeysResult).value
|
|
@@ -94,26 +100,31 @@ def get_ssh_keys(with_selector: Optional[str] = None,
|
|
|
94
100
|
id=pulumi.get(__ret__, 'id'),
|
|
95
101
|
ssh_keys=pulumi.get(__ret__, 'ssh_keys'),
|
|
96
102
|
with_selector=pulumi.get(__ret__, 'with_selector'))
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
def get_ssh_keys_output(with_selector: Optional[pulumi.Input[Optional[str]]] = None,
|
|
101
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetSshKeysResult]:
|
|
103
|
+
def get_ssh_keys_output(id: Optional[pulumi.Input[Optional[str]]] = None,
|
|
104
|
+
with_selector: Optional[pulumi.Input[Optional[str]]] = None,
|
|
105
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetSshKeysResult]:
|
|
102
106
|
"""
|
|
103
107
|
## Example Usage
|
|
104
108
|
|
|
105
|
-
<!--Start PulumiCodeChooser -->
|
|
106
109
|
```python
|
|
107
110
|
import pulumi
|
|
108
111
|
import pulumi_hcloud as hcloud
|
|
109
112
|
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
main = hcloud.Server("main", ssh_keys=[__item.name for __item in
|
|
113
|
+
all = hcloud.get_ssh_keys()
|
|
114
|
+
by_label = hcloud.get_ssh_keys(with_selector="foo=bar")
|
|
115
|
+
main = hcloud.Server("main", ssh_keys=[__item.name for __item in all.ssh_keys])
|
|
113
116
|
```
|
|
114
|
-
<!--End PulumiCodeChooser -->
|
|
115
117
|
|
|
116
118
|
|
|
117
|
-
:param str
|
|
119
|
+
:param str id: The ID of this resource.
|
|
120
|
+
:param str with_selector: Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector)
|
|
118
121
|
"""
|
|
119
|
-
|
|
122
|
+
__args__ = dict()
|
|
123
|
+
__args__['id'] = id
|
|
124
|
+
__args__['withSelector'] = with_selector
|
|
125
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
126
|
+
__ret__ = pulumi.runtime.invoke_output('hcloud:index/getSshKeys:getSshKeys', __args__, opts=opts, typ=GetSshKeysResult)
|
|
127
|
+
return __ret__.apply(lambda __response__: GetSshKeysResult(
|
|
128
|
+
id=pulumi.get(__response__, 'id'),
|
|
129
|
+
ssh_keys=pulumi.get(__response__, 'ssh_keys'),
|
|
130
|
+
with_selector=pulumi.get(__response__, 'with_selector')))
|
pulumi_hcloud/get_volume.py
CHANGED
|
@@ -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__ = [
|
|
@@ -74,7 +79,7 @@ class GetVolumeResult:
|
|
|
74
79
|
|
|
75
80
|
@property
|
|
76
81
|
@pulumi.getter
|
|
77
|
-
def labels(self) -> Mapping[str,
|
|
82
|
+
def labels(self) -> Mapping[str, str]:
|
|
78
83
|
"""
|
|
79
84
|
(map) User-defined labels (key-value pairs).
|
|
80
85
|
"""
|
|
@@ -92,7 +97,7 @@ class GetVolumeResult:
|
|
|
92
97
|
@pulumi.getter
|
|
93
98
|
def location(self) -> Optional[str]:
|
|
94
99
|
"""
|
|
95
|
-
(string) The location name.
|
|
100
|
+
(string) The location name. See the [Hetzner Docs](https://docs.hetzner.com/cloud/general/locations/#what-locations-are-there) for more details about locations.
|
|
96
101
|
"""
|
|
97
102
|
return pulumi.get(self, "location")
|
|
98
103
|
|
|
@@ -106,10 +111,8 @@ class GetVolumeResult:
|
|
|
106
111
|
|
|
107
112
|
@property
|
|
108
113
|
@pulumi.getter
|
|
114
|
+
@_utilities.deprecated("""Please use the with_selector property instead.""")
|
|
109
115
|
def selector(self) -> Optional[str]:
|
|
110
|
-
warnings.warn("""Please use the with_selector property instead.""", DeprecationWarning)
|
|
111
|
-
pulumi.log.warn("""selector is deprecated: Please use the with_selector property instead.""")
|
|
112
|
-
|
|
113
116
|
return pulumi.get(self, "selector")
|
|
114
117
|
|
|
115
118
|
@property
|
|
@@ -169,7 +172,6 @@ def get_volume(id: Optional[int] = None,
|
|
|
169
172
|
"""
|
|
170
173
|
## Example Usage
|
|
171
174
|
|
|
172
|
-
<!--Start PulumiCodeChooser -->
|
|
173
175
|
```python
|
|
174
176
|
import pulumi
|
|
175
177
|
import pulumi_hcloud as hcloud
|
|
@@ -178,11 +180,10 @@ def get_volume(id: Optional[int] = None,
|
|
|
178
180
|
volume2 = hcloud.get_volume(name="my-volume")
|
|
179
181
|
volume3 = hcloud.get_volume(with_selector="key=value")
|
|
180
182
|
```
|
|
181
|
-
<!--End PulumiCodeChooser -->
|
|
182
183
|
|
|
183
184
|
|
|
184
185
|
:param int id: ID of the volume.
|
|
185
|
-
:param str location: (string) The location name.
|
|
186
|
+
:param str location: (string) The location name. See the [Hetzner Docs](https://docs.hetzner.com/cloud/general/locations/#what-locations-are-there) for more details about locations.
|
|
186
187
|
:param str name: Name of the volume.
|
|
187
188
|
:param int server_id: (Optional, int) Server ID the volume is attached to
|
|
188
189
|
:param str with_selector: Label Selector. For more information about possible values, visit the [Hetzner Cloud Documentation](https://docs.hetzner.cloud/#overview-label-selector).
|
|
@@ -211,9 +212,6 @@ def get_volume(id: Optional[int] = None,
|
|
|
211
212
|
size=pulumi.get(__ret__, 'size'),
|
|
212
213
|
with_selector=pulumi.get(__ret__, 'with_selector'),
|
|
213
214
|
with_statuses=pulumi.get(__ret__, 'with_statuses'))
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
@_utilities.lift_output_func(get_volume)
|
|
217
215
|
def get_volume_output(id: Optional[pulumi.Input[Optional[int]]] = None,
|
|
218
216
|
location: Optional[pulumi.Input[Optional[str]]] = None,
|
|
219
217
|
name: Optional[pulumi.Input[Optional[str]]] = None,
|
|
@@ -221,11 +219,10 @@ def get_volume_output(id: Optional[pulumi.Input[Optional[int]]] = None,
|
|
|
221
219
|
server_id: Optional[pulumi.Input[Optional[int]]] = None,
|
|
222
220
|
with_selector: Optional[pulumi.Input[Optional[str]]] = None,
|
|
223
221
|
with_statuses: Optional[pulumi.Input[Optional[Sequence[str]]]] = None,
|
|
224
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetVolumeResult]:
|
|
222
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetVolumeResult]:
|
|
225
223
|
"""
|
|
226
224
|
## Example Usage
|
|
227
225
|
|
|
228
|
-
<!--Start PulumiCodeChooser -->
|
|
229
226
|
```python
|
|
230
227
|
import pulumi
|
|
231
228
|
import pulumi_hcloud as hcloud
|
|
@@ -234,14 +231,34 @@ def get_volume_output(id: Optional[pulumi.Input[Optional[int]]] = None,
|
|
|
234
231
|
volume2 = hcloud.get_volume(name="my-volume")
|
|
235
232
|
volume3 = hcloud.get_volume(with_selector="key=value")
|
|
236
233
|
```
|
|
237
|
-
<!--End PulumiCodeChooser -->
|
|
238
234
|
|
|
239
235
|
|
|
240
236
|
:param int id: ID of the volume.
|
|
241
|
-
:param str location: (string) The location name.
|
|
237
|
+
:param str location: (string) The location name. See the [Hetzner Docs](https://docs.hetzner.com/cloud/general/locations/#what-locations-are-there) for more details about locations.
|
|
242
238
|
:param str name: Name of the volume.
|
|
243
239
|
:param int server_id: (Optional, int) Server ID the volume is attached to
|
|
244
240
|
:param str with_selector: Label Selector. For more information about possible values, visit the [Hetzner Cloud Documentation](https://docs.hetzner.cloud/#overview-label-selector).
|
|
245
241
|
:param Sequence[str] with_statuses: List only volumes with the specified status, could contain `creating` or `available`.
|
|
246
242
|
"""
|
|
247
|
-
|
|
243
|
+
__args__ = dict()
|
|
244
|
+
__args__['id'] = id
|
|
245
|
+
__args__['location'] = location
|
|
246
|
+
__args__['name'] = name
|
|
247
|
+
__args__['selector'] = selector
|
|
248
|
+
__args__['serverId'] = server_id
|
|
249
|
+
__args__['withSelector'] = with_selector
|
|
250
|
+
__args__['withStatuses'] = with_statuses
|
|
251
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
252
|
+
__ret__ = pulumi.runtime.invoke_output('hcloud:index/getVolume:getVolume', __args__, opts=opts, typ=GetVolumeResult)
|
|
253
|
+
return __ret__.apply(lambda __response__: GetVolumeResult(
|
|
254
|
+
delete_protection=pulumi.get(__response__, 'delete_protection'),
|
|
255
|
+
id=pulumi.get(__response__, 'id'),
|
|
256
|
+
labels=pulumi.get(__response__, 'labels'),
|
|
257
|
+
linux_device=pulumi.get(__response__, 'linux_device'),
|
|
258
|
+
location=pulumi.get(__response__, 'location'),
|
|
259
|
+
name=pulumi.get(__response__, 'name'),
|
|
260
|
+
selector=pulumi.get(__response__, 'selector'),
|
|
261
|
+
server_id=pulumi.get(__response__, 'server_id'),
|
|
262
|
+
size=pulumi.get(__response__, 'size'),
|
|
263
|
+
with_selector=pulumi.get(__response__, 'with_selector'),
|
|
264
|
+
with_statuses=pulumi.get(__response__, 'with_statuses')))
|