pulumi-vsphere 4.10.0a1709017641__py3-none-any.whl → 4.17.0a1763710194__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-vsphere might be problematic. Click here for more details.
- pulumi_vsphere/__init__.py +51 -1
- pulumi_vsphere/_inputs.py +2568 -1025
- pulumi_vsphere/_utilities.py +50 -10
- pulumi_vsphere/compute_cluster.py +1564 -2373
- pulumi_vsphere/compute_cluster_host_group.py +191 -55
- pulumi_vsphere/compute_cluster_vm_affinity_rule.py +157 -113
- pulumi_vsphere/compute_cluster_vm_anti_affinity_rule.py +133 -89
- pulumi_vsphere/compute_cluster_vm_dependency_rule.py +314 -106
- pulumi_vsphere/compute_cluster_vm_group.py +256 -55
- pulumi_vsphere/compute_cluster_vm_host_rule.py +323 -123
- pulumi_vsphere/config/__init__.py +2 -1
- pulumi_vsphere/config/__init__.pyi +7 -2
- pulumi_vsphere/config/vars.py +20 -15
- pulumi_vsphere/configuration_profile.py +286 -0
- pulumi_vsphere/content_library.py +177 -71
- pulumi_vsphere/content_library_item.py +252 -106
- pulumi_vsphere/custom_attribute.py +118 -38
- pulumi_vsphere/datacenter.py +128 -107
- pulumi_vsphere/datastore_cluster.py +636 -731
- pulumi_vsphere/datastore_cluster_vm_anti_affinity_rule.py +251 -89
- pulumi_vsphere/distributed_port_group.py +1129 -967
- pulumi_vsphere/distributed_virtual_switch.py +1971 -2239
- pulumi_vsphere/distributed_virtual_switch_pvlan_mapping.py +294 -0
- pulumi_vsphere/dpm_host_override.py +222 -72
- pulumi_vsphere/drs_vm_override.py +236 -72
- pulumi_vsphere/entity_permissions.py +96 -69
- pulumi_vsphere/file.py +173 -178
- pulumi_vsphere/folder.py +236 -113
- pulumi_vsphere/get_compute_cluster.py +34 -23
- pulumi_vsphere/get_compute_cluster_host_group.py +52 -41
- pulumi_vsphere/get_configuration_profile.py +145 -0
- pulumi_vsphere/get_content_library.py +33 -21
- pulumi_vsphere/get_content_library_item.py +47 -31
- pulumi_vsphere/get_custom_attribute.py +26 -17
- pulumi_vsphere/get_datacenter.py +40 -18
- pulumi_vsphere/get_datastore.py +60 -24
- pulumi_vsphere/get_datastore_cluster.py +47 -22
- pulumi_vsphere/get_datastore_stats.py +204 -0
- pulumi_vsphere/get_distributed_virtual_switch.py +36 -23
- pulumi_vsphere/get_dynamic.py +55 -45
- pulumi_vsphere/get_folder.py +163 -25
- pulumi_vsphere/get_guest_os_customization.py +68 -37
- pulumi_vsphere/get_host.py +34 -23
- pulumi_vsphere/get_host_base_images.py +104 -0
- pulumi_vsphere/get_host_pci_device.py +78 -35
- pulumi_vsphere/get_host_thumbprint.py +58 -38
- pulumi_vsphere/get_host_vgpu_profile.py +195 -0
- pulumi_vsphere/get_license.py +44 -28
- pulumi_vsphere/get_network.py +157 -46
- pulumi_vsphere/get_ovf_vm_template.py +184 -301
- pulumi_vsphere/get_policy.py +23 -15
- pulumi_vsphere/get_resource_pool.py +107 -40
- pulumi_vsphere/get_role.py +49 -35
- pulumi_vsphere/get_tag.py +34 -23
- pulumi_vsphere/get_tag_category.py +32 -21
- pulumi_vsphere/get_vapp_container.py +31 -21
- pulumi_vsphere/get_virtual_machine.py +499 -287
- pulumi_vsphere/get_vmfs_disks.py +42 -29
- pulumi_vsphere/guest_os_customization.py +135 -79
- pulumi_vsphere/ha_vm_override.py +470 -577
- pulumi_vsphere/host.py +515 -262
- pulumi_vsphere/host_port_group.py +352 -355
- pulumi_vsphere/host_virtual_switch.py +580 -580
- pulumi_vsphere/license.py +110 -92
- pulumi_vsphere/nas_datastore.py +398 -270
- pulumi_vsphere/offline_software_depot.py +190 -0
- pulumi_vsphere/outputs.py +1582 -1027
- pulumi_vsphere/provider.py +172 -152
- pulumi_vsphere/pulumi-plugin.json +2 -1
- pulumi_vsphere/resource_pool.py +357 -273
- pulumi_vsphere/role.py +79 -47
- pulumi_vsphere/storage_drs_vm_override.py +225 -89
- pulumi_vsphere/supervisor.py +1064 -0
- pulumi_vsphere/tag.py +217 -55
- pulumi_vsphere/tag_category.py +158 -72
- pulumi_vsphere/vapp_container.py +425 -259
- pulumi_vsphere/vapp_entity.py +324 -174
- pulumi_vsphere/virtual_disk.py +245 -153
- pulumi_vsphere/virtual_machine.py +1696 -1836
- pulumi_vsphere/virtual_machine_class.py +448 -0
- pulumi_vsphere/virtual_machine_snapshot.py +137 -131
- pulumi_vsphere/vm_storage_policy.py +160 -154
- pulumi_vsphere/vmfs_datastore.py +460 -186
- pulumi_vsphere/vnic.py +249 -231
- {pulumi_vsphere-4.10.0a1709017641.dist-info → pulumi_vsphere-4.17.0a1763710194.dist-info}/METADATA +7 -6
- pulumi_vsphere-4.17.0a1763710194.dist-info/RECORD +89 -0
- {pulumi_vsphere-4.10.0a1709017641.dist-info → pulumi_vsphere-4.17.0a1763710194.dist-info}/WHEEL +1 -1
- pulumi_vsphere-4.10.0a1709017641.dist-info/RECORD +0 -80
- {pulumi_vsphere-4.10.0a1709017641.dist-info → pulumi_vsphere-4.17.0a1763710194.dist-info}/top_level.txt +0 -0
pulumi_vsphere/host.py
CHANGED
|
@@ -1,49 +1,57 @@
|
|
|
1
1
|
# coding=utf-8
|
|
2
|
-
# *** WARNING: this file was generated by
|
|
2
|
+
# *** WARNING: this file was generated by pulumi-language-python. ***
|
|
3
3
|
# *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
4
|
|
|
5
|
-
import
|
|
5
|
+
import builtins as _builtins
|
|
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
|
|
16
|
+
from . import outputs
|
|
17
|
+
from ._inputs import *
|
|
11
18
|
|
|
12
19
|
__all__ = ['HostArgs', 'Host']
|
|
13
20
|
|
|
14
21
|
@pulumi.input_type
|
|
15
22
|
class HostArgs:
|
|
16
23
|
def __init__(__self__, *,
|
|
17
|
-
hostname: pulumi.Input[str],
|
|
18
|
-
password: pulumi.Input[str],
|
|
19
|
-
username: pulumi.Input[str],
|
|
20
|
-
cluster: Optional[pulumi.Input[str]] = None,
|
|
21
|
-
cluster_managed: Optional[pulumi.Input[bool]] = None,
|
|
22
|
-
connected: Optional[pulumi.Input[bool]] = None,
|
|
23
|
-
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
|
|
24
|
-
datacenter: Optional[pulumi.Input[str]] = None,
|
|
25
|
-
force: Optional[pulumi.Input[bool]] = None,
|
|
26
|
-
license: Optional[pulumi.Input[str]] = None,
|
|
27
|
-
lockdown: Optional[pulumi.Input[str]] = None,
|
|
28
|
-
maintenance: Optional[pulumi.Input[bool]] = None,
|
|
29
|
-
|
|
30
|
-
|
|
24
|
+
hostname: pulumi.Input[_builtins.str],
|
|
25
|
+
password: pulumi.Input[_builtins.str],
|
|
26
|
+
username: pulumi.Input[_builtins.str],
|
|
27
|
+
cluster: Optional[pulumi.Input[_builtins.str]] = None,
|
|
28
|
+
cluster_managed: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
29
|
+
connected: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
30
|
+
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]] = None,
|
|
31
|
+
datacenter: Optional[pulumi.Input[_builtins.str]] = None,
|
|
32
|
+
force: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
33
|
+
license: Optional[pulumi.Input[_builtins.str]] = None,
|
|
34
|
+
lockdown: Optional[pulumi.Input[_builtins.str]] = None,
|
|
35
|
+
maintenance: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
36
|
+
services: Optional[pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]]] = None,
|
|
37
|
+
tags: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
38
|
+
thumbprint: Optional[pulumi.Input[_builtins.str]] = None):
|
|
31
39
|
"""
|
|
32
40
|
The set of arguments for constructing a Host resource.
|
|
33
|
-
:param pulumi.Input[str] hostname: FQDN or IP address of the host to be added.
|
|
34
|
-
:param pulumi.Input[str] password: Password that will be used by vSphere to authenticate
|
|
41
|
+
:param pulumi.Input[_builtins.str] hostname: FQDN or IP address of the host to be added.
|
|
42
|
+
:param pulumi.Input[_builtins.str] password: Password that will be used by vSphere to authenticate
|
|
35
43
|
to the host.
|
|
36
|
-
:param pulumi.Input[str] username: Username that will be used by vSphere to authenticate
|
|
44
|
+
:param pulumi.Input[_builtins.str] username: Username that will be used by vSphere to authenticate
|
|
37
45
|
to the host.
|
|
38
|
-
:param pulumi.Input[str] cluster: The ID of the Compute Cluster this host should
|
|
46
|
+
:param pulumi.Input[_builtins.str] cluster: The ID of the Compute Cluster this host should
|
|
39
47
|
be added to. This should not be set if `datacenter` is set. Conflicts with:
|
|
40
48
|
`cluster_managed`.
|
|
41
|
-
:param pulumi.Input[bool] cluster_managed: Can be set to `true` if compute cluster
|
|
49
|
+
:param pulumi.Input[_builtins.bool] cluster_managed: Can be set to `true` if compute cluster
|
|
42
50
|
membership will be managed through the `compute_cluster` resource rather
|
|
43
51
|
than the`host` resource. Conflicts with: `cluster`.
|
|
44
|
-
:param pulumi.Input[bool] connected: If set to false then the host will be disconnected.
|
|
52
|
+
:param pulumi.Input[_builtins.bool] connected: If set to false then the host will be disconnected.
|
|
45
53
|
Default is `false`.
|
|
46
|
-
:param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: A map of custom attribute IDs and string
|
|
54
|
+
:param pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]] custom_attributes: A map of custom attribute IDs and string
|
|
47
55
|
values to apply to the resource. Please refer to the
|
|
48
56
|
`vsphere_custom_attributes` resource for more information on applying
|
|
49
57
|
tags to resources.
|
|
@@ -52,24 +60,25 @@ class HostArgs:
|
|
|
52
60
|
connections and require vCenter Server.
|
|
53
61
|
|
|
54
62
|
[docs-host-thumbprint-data-source]: /docs/providers/vsphere/d/host_thumbprint.html
|
|
55
|
-
:param pulumi.Input[str] datacenter: The ID of the datacenter this host should
|
|
63
|
+
:param pulumi.Input[_builtins.str] datacenter: The ID of the datacenter this host should
|
|
56
64
|
be added to. This should not be set if `cluster` is set.
|
|
57
|
-
:param pulumi.Input[bool] force: If set to `true` then it will force the host to be added,
|
|
65
|
+
:param pulumi.Input[_builtins.bool] force: If set to `true` then it will force the host to be added,
|
|
58
66
|
even if the host is already connected to a different vCenter Server instance.
|
|
59
67
|
Default is `false`.
|
|
60
|
-
:param pulumi.Input[str] license: The license key that will be applied to the host.
|
|
68
|
+
:param pulumi.Input[_builtins.str] license: The license key that will be applied to the host.
|
|
61
69
|
The license key is expected to be present in vSphere.
|
|
62
|
-
:param pulumi.Input[str] lockdown: Set the lockdown state of the host. Valid options are
|
|
70
|
+
:param pulumi.Input[_builtins.str] lockdown: Set the lockdown state of the host. Valid options are
|
|
63
71
|
`disabled`, `normal`, and `strict`. Default is `disabled`.
|
|
64
|
-
:param pulumi.Input[bool] maintenance: Set the management state of the host.
|
|
72
|
+
:param pulumi.Input[_builtins.bool] maintenance: Set the management state of the host.
|
|
65
73
|
Default is `false`.
|
|
66
|
-
:param pulumi.Input[Sequence[pulumi.Input[
|
|
74
|
+
:param pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]] services: Set Services on host, the settings to be set are based on service being set as part of import.
|
|
75
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] tags: The IDs of any tags to attach to this resource. Please
|
|
67
76
|
refer to the `Tag` resource for more information on applying
|
|
68
77
|
tags to resources.
|
|
69
78
|
|
|
70
79
|
> **NOTE:** Tagging support is not supported on direct ESXi host
|
|
71
80
|
connections and require vCenter Server.
|
|
72
|
-
:param pulumi.Input[str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
81
|
+
:param pulumi.Input[_builtins.str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
73
82
|
CA that signed the host's certificate should be trusted. If the CA is not
|
|
74
83
|
trusted and no thumbprint is set then the operation will fail. See data source
|
|
75
84
|
[`get_host_thumbprint`][docs-host-thumbprint-data-source].
|
|
@@ -95,26 +104,28 @@ class HostArgs:
|
|
|
95
104
|
pulumi.set(__self__, "lockdown", lockdown)
|
|
96
105
|
if maintenance is not None:
|
|
97
106
|
pulumi.set(__self__, "maintenance", maintenance)
|
|
107
|
+
if services is not None:
|
|
108
|
+
pulumi.set(__self__, "services", services)
|
|
98
109
|
if tags is not None:
|
|
99
110
|
pulumi.set(__self__, "tags", tags)
|
|
100
111
|
if thumbprint is not None:
|
|
101
112
|
pulumi.set(__self__, "thumbprint", thumbprint)
|
|
102
113
|
|
|
103
|
-
@property
|
|
114
|
+
@_builtins.property
|
|
104
115
|
@pulumi.getter
|
|
105
|
-
def hostname(self) -> pulumi.Input[str]:
|
|
116
|
+
def hostname(self) -> pulumi.Input[_builtins.str]:
|
|
106
117
|
"""
|
|
107
118
|
FQDN or IP address of the host to be added.
|
|
108
119
|
"""
|
|
109
120
|
return pulumi.get(self, "hostname")
|
|
110
121
|
|
|
111
122
|
@hostname.setter
|
|
112
|
-
def hostname(self, value: pulumi.Input[str]):
|
|
123
|
+
def hostname(self, value: pulumi.Input[_builtins.str]):
|
|
113
124
|
pulumi.set(self, "hostname", value)
|
|
114
125
|
|
|
115
|
-
@property
|
|
126
|
+
@_builtins.property
|
|
116
127
|
@pulumi.getter
|
|
117
|
-
def password(self) -> pulumi.Input[str]:
|
|
128
|
+
def password(self) -> pulumi.Input[_builtins.str]:
|
|
118
129
|
"""
|
|
119
130
|
Password that will be used by vSphere to authenticate
|
|
120
131
|
to the host.
|
|
@@ -122,12 +133,12 @@ class HostArgs:
|
|
|
122
133
|
return pulumi.get(self, "password")
|
|
123
134
|
|
|
124
135
|
@password.setter
|
|
125
|
-
def password(self, value: pulumi.Input[str]):
|
|
136
|
+
def password(self, value: pulumi.Input[_builtins.str]):
|
|
126
137
|
pulumi.set(self, "password", value)
|
|
127
138
|
|
|
128
|
-
@property
|
|
139
|
+
@_builtins.property
|
|
129
140
|
@pulumi.getter
|
|
130
|
-
def username(self) -> pulumi.Input[str]:
|
|
141
|
+
def username(self) -> pulumi.Input[_builtins.str]:
|
|
131
142
|
"""
|
|
132
143
|
Username that will be used by vSphere to authenticate
|
|
133
144
|
to the host.
|
|
@@ -135,12 +146,12 @@ class HostArgs:
|
|
|
135
146
|
return pulumi.get(self, "username")
|
|
136
147
|
|
|
137
148
|
@username.setter
|
|
138
|
-
def username(self, value: pulumi.Input[str]):
|
|
149
|
+
def username(self, value: pulumi.Input[_builtins.str]):
|
|
139
150
|
pulumi.set(self, "username", value)
|
|
140
151
|
|
|
141
|
-
@property
|
|
152
|
+
@_builtins.property
|
|
142
153
|
@pulumi.getter
|
|
143
|
-
def cluster(self) -> Optional[pulumi.Input[str]]:
|
|
154
|
+
def cluster(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
144
155
|
"""
|
|
145
156
|
The ID of the Compute Cluster this host should
|
|
146
157
|
be added to. This should not be set if `datacenter` is set. Conflicts with:
|
|
@@ -149,12 +160,12 @@ class HostArgs:
|
|
|
149
160
|
return pulumi.get(self, "cluster")
|
|
150
161
|
|
|
151
162
|
@cluster.setter
|
|
152
|
-
def cluster(self, value: Optional[pulumi.Input[str]]):
|
|
163
|
+
def cluster(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
153
164
|
pulumi.set(self, "cluster", value)
|
|
154
165
|
|
|
155
|
-
@property
|
|
166
|
+
@_builtins.property
|
|
156
167
|
@pulumi.getter(name="clusterManaged")
|
|
157
|
-
def cluster_managed(self) -> Optional[pulumi.Input[bool]]:
|
|
168
|
+
def cluster_managed(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
158
169
|
"""
|
|
159
170
|
Can be set to `true` if compute cluster
|
|
160
171
|
membership will be managed through the `compute_cluster` resource rather
|
|
@@ -163,12 +174,12 @@ class HostArgs:
|
|
|
163
174
|
return pulumi.get(self, "cluster_managed")
|
|
164
175
|
|
|
165
176
|
@cluster_managed.setter
|
|
166
|
-
def cluster_managed(self, value: Optional[pulumi.Input[bool]]):
|
|
177
|
+
def cluster_managed(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
167
178
|
pulumi.set(self, "cluster_managed", value)
|
|
168
179
|
|
|
169
|
-
@property
|
|
180
|
+
@_builtins.property
|
|
170
181
|
@pulumi.getter
|
|
171
|
-
def connected(self) -> Optional[pulumi.Input[bool]]:
|
|
182
|
+
def connected(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
172
183
|
"""
|
|
173
184
|
If set to false then the host will be disconnected.
|
|
174
185
|
Default is `false`.
|
|
@@ -176,12 +187,12 @@ class HostArgs:
|
|
|
176
187
|
return pulumi.get(self, "connected")
|
|
177
188
|
|
|
178
189
|
@connected.setter
|
|
179
|
-
def connected(self, value: Optional[pulumi.Input[bool]]):
|
|
190
|
+
def connected(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
180
191
|
pulumi.set(self, "connected", value)
|
|
181
192
|
|
|
182
|
-
@property
|
|
193
|
+
@_builtins.property
|
|
183
194
|
@pulumi.getter(name="customAttributes")
|
|
184
|
-
def custom_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
|
|
195
|
+
def custom_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]]:
|
|
185
196
|
"""
|
|
186
197
|
A map of custom attribute IDs and string
|
|
187
198
|
values to apply to the resource. Please refer to the
|
|
@@ -196,12 +207,12 @@ class HostArgs:
|
|
|
196
207
|
return pulumi.get(self, "custom_attributes")
|
|
197
208
|
|
|
198
209
|
@custom_attributes.setter
|
|
199
|
-
def custom_attributes(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]):
|
|
210
|
+
def custom_attributes(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]]):
|
|
200
211
|
pulumi.set(self, "custom_attributes", value)
|
|
201
212
|
|
|
202
|
-
@property
|
|
213
|
+
@_builtins.property
|
|
203
214
|
@pulumi.getter
|
|
204
|
-
def datacenter(self) -> Optional[pulumi.Input[str]]:
|
|
215
|
+
def datacenter(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
205
216
|
"""
|
|
206
217
|
The ID of the datacenter this host should
|
|
207
218
|
be added to. This should not be set if `cluster` is set.
|
|
@@ -209,12 +220,12 @@ class HostArgs:
|
|
|
209
220
|
return pulumi.get(self, "datacenter")
|
|
210
221
|
|
|
211
222
|
@datacenter.setter
|
|
212
|
-
def datacenter(self, value: Optional[pulumi.Input[str]]):
|
|
223
|
+
def datacenter(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
213
224
|
pulumi.set(self, "datacenter", value)
|
|
214
225
|
|
|
215
|
-
@property
|
|
226
|
+
@_builtins.property
|
|
216
227
|
@pulumi.getter
|
|
217
|
-
def force(self) -> Optional[pulumi.Input[bool]]:
|
|
228
|
+
def force(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
218
229
|
"""
|
|
219
230
|
If set to `true` then it will force the host to be added,
|
|
220
231
|
even if the host is already connected to a different vCenter Server instance.
|
|
@@ -223,12 +234,12 @@ class HostArgs:
|
|
|
223
234
|
return pulumi.get(self, "force")
|
|
224
235
|
|
|
225
236
|
@force.setter
|
|
226
|
-
def force(self, value: Optional[pulumi.Input[bool]]):
|
|
237
|
+
def force(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
227
238
|
pulumi.set(self, "force", value)
|
|
228
239
|
|
|
229
|
-
@property
|
|
240
|
+
@_builtins.property
|
|
230
241
|
@pulumi.getter
|
|
231
|
-
def license(self) -> Optional[pulumi.Input[str]]:
|
|
242
|
+
def license(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
232
243
|
"""
|
|
233
244
|
The license key that will be applied to the host.
|
|
234
245
|
The license key is expected to be present in vSphere.
|
|
@@ -236,12 +247,12 @@ class HostArgs:
|
|
|
236
247
|
return pulumi.get(self, "license")
|
|
237
248
|
|
|
238
249
|
@license.setter
|
|
239
|
-
def license(self, value: Optional[pulumi.Input[str]]):
|
|
250
|
+
def license(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
240
251
|
pulumi.set(self, "license", value)
|
|
241
252
|
|
|
242
|
-
@property
|
|
253
|
+
@_builtins.property
|
|
243
254
|
@pulumi.getter
|
|
244
|
-
def lockdown(self) -> Optional[pulumi.Input[str]]:
|
|
255
|
+
def lockdown(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
245
256
|
"""
|
|
246
257
|
Set the lockdown state of the host. Valid options are
|
|
247
258
|
`disabled`, `normal`, and `strict`. Default is `disabled`.
|
|
@@ -249,12 +260,12 @@ class HostArgs:
|
|
|
249
260
|
return pulumi.get(self, "lockdown")
|
|
250
261
|
|
|
251
262
|
@lockdown.setter
|
|
252
|
-
def lockdown(self, value: Optional[pulumi.Input[str]]):
|
|
263
|
+
def lockdown(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
253
264
|
pulumi.set(self, "lockdown", value)
|
|
254
265
|
|
|
255
|
-
@property
|
|
266
|
+
@_builtins.property
|
|
256
267
|
@pulumi.getter
|
|
257
|
-
def maintenance(self) -> Optional[pulumi.Input[bool]]:
|
|
268
|
+
def maintenance(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
258
269
|
"""
|
|
259
270
|
Set the management state of the host.
|
|
260
271
|
Default is `false`.
|
|
@@ -262,12 +273,24 @@ class HostArgs:
|
|
|
262
273
|
return pulumi.get(self, "maintenance")
|
|
263
274
|
|
|
264
275
|
@maintenance.setter
|
|
265
|
-
def maintenance(self, value: Optional[pulumi.Input[bool]]):
|
|
276
|
+
def maintenance(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
266
277
|
pulumi.set(self, "maintenance", value)
|
|
267
278
|
|
|
268
|
-
@property
|
|
279
|
+
@_builtins.property
|
|
269
280
|
@pulumi.getter
|
|
270
|
-
def
|
|
281
|
+
def services(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]]]:
|
|
282
|
+
"""
|
|
283
|
+
Set Services on host, the settings to be set are based on service being set as part of import.
|
|
284
|
+
"""
|
|
285
|
+
return pulumi.get(self, "services")
|
|
286
|
+
|
|
287
|
+
@services.setter
|
|
288
|
+
def services(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]]]):
|
|
289
|
+
pulumi.set(self, "services", value)
|
|
290
|
+
|
|
291
|
+
@_builtins.property
|
|
292
|
+
@pulumi.getter
|
|
293
|
+
def tags(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]:
|
|
271
294
|
"""
|
|
272
295
|
The IDs of any tags to attach to this resource. Please
|
|
273
296
|
refer to the `Tag` resource for more information on applying
|
|
@@ -279,12 +302,12 @@ class HostArgs:
|
|
|
279
302
|
return pulumi.get(self, "tags")
|
|
280
303
|
|
|
281
304
|
@tags.setter
|
|
282
|
-
def tags(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
|
|
305
|
+
def tags(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]):
|
|
283
306
|
pulumi.set(self, "tags", value)
|
|
284
307
|
|
|
285
|
-
@property
|
|
308
|
+
@_builtins.property
|
|
286
309
|
@pulumi.getter
|
|
287
|
-
def thumbprint(self) -> Optional[pulumi.Input[str]]:
|
|
310
|
+
def thumbprint(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
288
311
|
"""
|
|
289
312
|
Host's certificate SHA-1 thumbprint. If not set the
|
|
290
313
|
CA that signed the host's certificate should be trusted. If the CA is not
|
|
@@ -294,38 +317,39 @@ class HostArgs:
|
|
|
294
317
|
return pulumi.get(self, "thumbprint")
|
|
295
318
|
|
|
296
319
|
@thumbprint.setter
|
|
297
|
-
def thumbprint(self, value: Optional[pulumi.Input[str]]):
|
|
320
|
+
def thumbprint(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
298
321
|
pulumi.set(self, "thumbprint", value)
|
|
299
322
|
|
|
300
323
|
|
|
301
324
|
@pulumi.input_type
|
|
302
325
|
class _HostState:
|
|
303
326
|
def __init__(__self__, *,
|
|
304
|
-
cluster: Optional[pulumi.Input[str]] = None,
|
|
305
|
-
cluster_managed: Optional[pulumi.Input[bool]] = None,
|
|
306
|
-
connected: Optional[pulumi.Input[bool]] = None,
|
|
307
|
-
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
|
|
308
|
-
datacenter: Optional[pulumi.Input[str]] = None,
|
|
309
|
-
force: Optional[pulumi.Input[bool]] = None,
|
|
310
|
-
hostname: Optional[pulumi.Input[str]] = None,
|
|
311
|
-
license: Optional[pulumi.Input[str]] = None,
|
|
312
|
-
lockdown: Optional[pulumi.Input[str]] = None,
|
|
313
|
-
maintenance: Optional[pulumi.Input[bool]] = None,
|
|
314
|
-
password: Optional[pulumi.Input[str]] = None,
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
327
|
+
cluster: Optional[pulumi.Input[_builtins.str]] = None,
|
|
328
|
+
cluster_managed: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
329
|
+
connected: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
330
|
+
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]] = None,
|
|
331
|
+
datacenter: Optional[pulumi.Input[_builtins.str]] = None,
|
|
332
|
+
force: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
333
|
+
hostname: Optional[pulumi.Input[_builtins.str]] = None,
|
|
334
|
+
license: Optional[pulumi.Input[_builtins.str]] = None,
|
|
335
|
+
lockdown: Optional[pulumi.Input[_builtins.str]] = None,
|
|
336
|
+
maintenance: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
337
|
+
password: Optional[pulumi.Input[_builtins.str]] = None,
|
|
338
|
+
services: Optional[pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]]] = None,
|
|
339
|
+
tags: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
340
|
+
thumbprint: Optional[pulumi.Input[_builtins.str]] = None,
|
|
341
|
+
username: Optional[pulumi.Input[_builtins.str]] = None):
|
|
318
342
|
"""
|
|
319
343
|
Input properties used for looking up and filtering Host resources.
|
|
320
|
-
:param pulumi.Input[str] cluster: The ID of the Compute Cluster this host should
|
|
344
|
+
:param pulumi.Input[_builtins.str] cluster: The ID of the Compute Cluster this host should
|
|
321
345
|
be added to. This should not be set if `datacenter` is set. Conflicts with:
|
|
322
346
|
`cluster_managed`.
|
|
323
|
-
:param pulumi.Input[bool] cluster_managed: Can be set to `true` if compute cluster
|
|
347
|
+
:param pulumi.Input[_builtins.bool] cluster_managed: Can be set to `true` if compute cluster
|
|
324
348
|
membership will be managed through the `compute_cluster` resource rather
|
|
325
349
|
than the`host` resource. Conflicts with: `cluster`.
|
|
326
|
-
:param pulumi.Input[bool] connected: If set to false then the host will be disconnected.
|
|
350
|
+
:param pulumi.Input[_builtins.bool] connected: If set to false then the host will be disconnected.
|
|
327
351
|
Default is `false`.
|
|
328
|
-
:param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: A map of custom attribute IDs and string
|
|
352
|
+
:param pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]] custom_attributes: A map of custom attribute IDs and string
|
|
329
353
|
values to apply to the resource. Please refer to the
|
|
330
354
|
`vsphere_custom_attributes` resource for more information on applying
|
|
331
355
|
tags to resources.
|
|
@@ -334,31 +358,32 @@ class _HostState:
|
|
|
334
358
|
connections and require vCenter Server.
|
|
335
359
|
|
|
336
360
|
[docs-host-thumbprint-data-source]: /docs/providers/vsphere/d/host_thumbprint.html
|
|
337
|
-
:param pulumi.Input[str] datacenter: The ID of the datacenter this host should
|
|
361
|
+
:param pulumi.Input[_builtins.str] datacenter: The ID of the datacenter this host should
|
|
338
362
|
be added to. This should not be set if `cluster` is set.
|
|
339
|
-
:param pulumi.Input[bool] force: If set to `true` then it will force the host to be added,
|
|
363
|
+
:param pulumi.Input[_builtins.bool] force: If set to `true` then it will force the host to be added,
|
|
340
364
|
even if the host is already connected to a different vCenter Server instance.
|
|
341
365
|
Default is `false`.
|
|
342
|
-
:param pulumi.Input[str] hostname: FQDN or IP address of the host to be added.
|
|
343
|
-
:param pulumi.Input[str] license: The license key that will be applied to the host.
|
|
366
|
+
:param pulumi.Input[_builtins.str] hostname: FQDN or IP address of the host to be added.
|
|
367
|
+
:param pulumi.Input[_builtins.str] license: The license key that will be applied to the host.
|
|
344
368
|
The license key is expected to be present in vSphere.
|
|
345
|
-
:param pulumi.Input[str] lockdown: Set the lockdown state of the host. Valid options are
|
|
369
|
+
:param pulumi.Input[_builtins.str] lockdown: Set the lockdown state of the host. Valid options are
|
|
346
370
|
`disabled`, `normal`, and `strict`. Default is `disabled`.
|
|
347
|
-
:param pulumi.Input[bool] maintenance: Set the management state of the host.
|
|
371
|
+
:param pulumi.Input[_builtins.bool] maintenance: Set the management state of the host.
|
|
348
372
|
Default is `false`.
|
|
349
|
-
:param pulumi.Input[str] password: Password that will be used by vSphere to authenticate
|
|
373
|
+
:param pulumi.Input[_builtins.str] password: Password that will be used by vSphere to authenticate
|
|
350
374
|
to the host.
|
|
351
|
-
:param pulumi.Input[Sequence[pulumi.Input[
|
|
375
|
+
:param pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]] services: Set Services on host, the settings to be set are based on service being set as part of import.
|
|
376
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] tags: The IDs of any tags to attach to this resource. Please
|
|
352
377
|
refer to the `Tag` resource for more information on applying
|
|
353
378
|
tags to resources.
|
|
354
379
|
|
|
355
380
|
> **NOTE:** Tagging support is not supported on direct ESXi host
|
|
356
381
|
connections and require vCenter Server.
|
|
357
|
-
:param pulumi.Input[str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
382
|
+
:param pulumi.Input[_builtins.str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
358
383
|
CA that signed the host's certificate should be trusted. If the CA is not
|
|
359
384
|
trusted and no thumbprint is set then the operation will fail. See data source
|
|
360
385
|
[`get_host_thumbprint`][docs-host-thumbprint-data-source].
|
|
361
|
-
:param pulumi.Input[str] username: Username that will be used by vSphere to authenticate
|
|
386
|
+
:param pulumi.Input[_builtins.str] username: Username that will be used by vSphere to authenticate
|
|
362
387
|
to the host.
|
|
363
388
|
"""
|
|
364
389
|
if cluster is not None:
|
|
@@ -383,6 +408,8 @@ class _HostState:
|
|
|
383
408
|
pulumi.set(__self__, "maintenance", maintenance)
|
|
384
409
|
if password is not None:
|
|
385
410
|
pulumi.set(__self__, "password", password)
|
|
411
|
+
if services is not None:
|
|
412
|
+
pulumi.set(__self__, "services", services)
|
|
386
413
|
if tags is not None:
|
|
387
414
|
pulumi.set(__self__, "tags", tags)
|
|
388
415
|
if thumbprint is not None:
|
|
@@ -390,9 +417,9 @@ class _HostState:
|
|
|
390
417
|
if username is not None:
|
|
391
418
|
pulumi.set(__self__, "username", username)
|
|
392
419
|
|
|
393
|
-
@property
|
|
420
|
+
@_builtins.property
|
|
394
421
|
@pulumi.getter
|
|
395
|
-
def cluster(self) -> Optional[pulumi.Input[str]]:
|
|
422
|
+
def cluster(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
396
423
|
"""
|
|
397
424
|
The ID of the Compute Cluster this host should
|
|
398
425
|
be added to. This should not be set if `datacenter` is set. Conflicts with:
|
|
@@ -401,12 +428,12 @@ class _HostState:
|
|
|
401
428
|
return pulumi.get(self, "cluster")
|
|
402
429
|
|
|
403
430
|
@cluster.setter
|
|
404
|
-
def cluster(self, value: Optional[pulumi.Input[str]]):
|
|
431
|
+
def cluster(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
405
432
|
pulumi.set(self, "cluster", value)
|
|
406
433
|
|
|
407
|
-
@property
|
|
434
|
+
@_builtins.property
|
|
408
435
|
@pulumi.getter(name="clusterManaged")
|
|
409
|
-
def cluster_managed(self) -> Optional[pulumi.Input[bool]]:
|
|
436
|
+
def cluster_managed(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
410
437
|
"""
|
|
411
438
|
Can be set to `true` if compute cluster
|
|
412
439
|
membership will be managed through the `compute_cluster` resource rather
|
|
@@ -415,12 +442,12 @@ class _HostState:
|
|
|
415
442
|
return pulumi.get(self, "cluster_managed")
|
|
416
443
|
|
|
417
444
|
@cluster_managed.setter
|
|
418
|
-
def cluster_managed(self, value: Optional[pulumi.Input[bool]]):
|
|
445
|
+
def cluster_managed(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
419
446
|
pulumi.set(self, "cluster_managed", value)
|
|
420
447
|
|
|
421
|
-
@property
|
|
448
|
+
@_builtins.property
|
|
422
449
|
@pulumi.getter
|
|
423
|
-
def connected(self) -> Optional[pulumi.Input[bool]]:
|
|
450
|
+
def connected(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
424
451
|
"""
|
|
425
452
|
If set to false then the host will be disconnected.
|
|
426
453
|
Default is `false`.
|
|
@@ -428,12 +455,12 @@ class _HostState:
|
|
|
428
455
|
return pulumi.get(self, "connected")
|
|
429
456
|
|
|
430
457
|
@connected.setter
|
|
431
|
-
def connected(self, value: Optional[pulumi.Input[bool]]):
|
|
458
|
+
def connected(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
432
459
|
pulumi.set(self, "connected", value)
|
|
433
460
|
|
|
434
|
-
@property
|
|
461
|
+
@_builtins.property
|
|
435
462
|
@pulumi.getter(name="customAttributes")
|
|
436
|
-
def custom_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
|
|
463
|
+
def custom_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]]:
|
|
437
464
|
"""
|
|
438
465
|
A map of custom attribute IDs and string
|
|
439
466
|
values to apply to the resource. Please refer to the
|
|
@@ -448,12 +475,12 @@ class _HostState:
|
|
|
448
475
|
return pulumi.get(self, "custom_attributes")
|
|
449
476
|
|
|
450
477
|
@custom_attributes.setter
|
|
451
|
-
def custom_attributes(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]):
|
|
478
|
+
def custom_attributes(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]]):
|
|
452
479
|
pulumi.set(self, "custom_attributes", value)
|
|
453
480
|
|
|
454
|
-
@property
|
|
481
|
+
@_builtins.property
|
|
455
482
|
@pulumi.getter
|
|
456
|
-
def datacenter(self) -> Optional[pulumi.Input[str]]:
|
|
483
|
+
def datacenter(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
457
484
|
"""
|
|
458
485
|
The ID of the datacenter this host should
|
|
459
486
|
be added to. This should not be set if `cluster` is set.
|
|
@@ -461,12 +488,12 @@ class _HostState:
|
|
|
461
488
|
return pulumi.get(self, "datacenter")
|
|
462
489
|
|
|
463
490
|
@datacenter.setter
|
|
464
|
-
def datacenter(self, value: Optional[pulumi.Input[str]]):
|
|
491
|
+
def datacenter(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
465
492
|
pulumi.set(self, "datacenter", value)
|
|
466
493
|
|
|
467
|
-
@property
|
|
494
|
+
@_builtins.property
|
|
468
495
|
@pulumi.getter
|
|
469
|
-
def force(self) -> Optional[pulumi.Input[bool]]:
|
|
496
|
+
def force(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
470
497
|
"""
|
|
471
498
|
If set to `true` then it will force the host to be added,
|
|
472
499
|
even if the host is already connected to a different vCenter Server instance.
|
|
@@ -475,24 +502,24 @@ class _HostState:
|
|
|
475
502
|
return pulumi.get(self, "force")
|
|
476
503
|
|
|
477
504
|
@force.setter
|
|
478
|
-
def force(self, value: Optional[pulumi.Input[bool]]):
|
|
505
|
+
def force(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
479
506
|
pulumi.set(self, "force", value)
|
|
480
507
|
|
|
481
|
-
@property
|
|
508
|
+
@_builtins.property
|
|
482
509
|
@pulumi.getter
|
|
483
|
-
def hostname(self) -> Optional[pulumi.Input[str]]:
|
|
510
|
+
def hostname(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
484
511
|
"""
|
|
485
512
|
FQDN or IP address of the host to be added.
|
|
486
513
|
"""
|
|
487
514
|
return pulumi.get(self, "hostname")
|
|
488
515
|
|
|
489
516
|
@hostname.setter
|
|
490
|
-
def hostname(self, value: Optional[pulumi.Input[str]]):
|
|
517
|
+
def hostname(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
491
518
|
pulumi.set(self, "hostname", value)
|
|
492
519
|
|
|
493
|
-
@property
|
|
520
|
+
@_builtins.property
|
|
494
521
|
@pulumi.getter
|
|
495
|
-
def license(self) -> Optional[pulumi.Input[str]]:
|
|
522
|
+
def license(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
496
523
|
"""
|
|
497
524
|
The license key that will be applied to the host.
|
|
498
525
|
The license key is expected to be present in vSphere.
|
|
@@ -500,12 +527,12 @@ class _HostState:
|
|
|
500
527
|
return pulumi.get(self, "license")
|
|
501
528
|
|
|
502
529
|
@license.setter
|
|
503
|
-
def license(self, value: Optional[pulumi.Input[str]]):
|
|
530
|
+
def license(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
504
531
|
pulumi.set(self, "license", value)
|
|
505
532
|
|
|
506
|
-
@property
|
|
533
|
+
@_builtins.property
|
|
507
534
|
@pulumi.getter
|
|
508
|
-
def lockdown(self) -> Optional[pulumi.Input[str]]:
|
|
535
|
+
def lockdown(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
509
536
|
"""
|
|
510
537
|
Set the lockdown state of the host. Valid options are
|
|
511
538
|
`disabled`, `normal`, and `strict`. Default is `disabled`.
|
|
@@ -513,12 +540,12 @@ class _HostState:
|
|
|
513
540
|
return pulumi.get(self, "lockdown")
|
|
514
541
|
|
|
515
542
|
@lockdown.setter
|
|
516
|
-
def lockdown(self, value: Optional[pulumi.Input[str]]):
|
|
543
|
+
def lockdown(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
517
544
|
pulumi.set(self, "lockdown", value)
|
|
518
545
|
|
|
519
|
-
@property
|
|
546
|
+
@_builtins.property
|
|
520
547
|
@pulumi.getter
|
|
521
|
-
def maintenance(self) -> Optional[pulumi.Input[bool]]:
|
|
548
|
+
def maintenance(self) -> Optional[pulumi.Input[_builtins.bool]]:
|
|
522
549
|
"""
|
|
523
550
|
Set the management state of the host.
|
|
524
551
|
Default is `false`.
|
|
@@ -526,12 +553,12 @@ class _HostState:
|
|
|
526
553
|
return pulumi.get(self, "maintenance")
|
|
527
554
|
|
|
528
555
|
@maintenance.setter
|
|
529
|
-
def maintenance(self, value: Optional[pulumi.Input[bool]]):
|
|
556
|
+
def maintenance(self, value: Optional[pulumi.Input[_builtins.bool]]):
|
|
530
557
|
pulumi.set(self, "maintenance", value)
|
|
531
558
|
|
|
532
|
-
@property
|
|
559
|
+
@_builtins.property
|
|
533
560
|
@pulumi.getter
|
|
534
|
-
def password(self) -> Optional[pulumi.Input[str]]:
|
|
561
|
+
def password(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
535
562
|
"""
|
|
536
563
|
Password that will be used by vSphere to authenticate
|
|
537
564
|
to the host.
|
|
@@ -539,12 +566,24 @@ class _HostState:
|
|
|
539
566
|
return pulumi.get(self, "password")
|
|
540
567
|
|
|
541
568
|
@password.setter
|
|
542
|
-
def password(self, value: Optional[pulumi.Input[str]]):
|
|
569
|
+
def password(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
543
570
|
pulumi.set(self, "password", value)
|
|
544
571
|
|
|
545
|
-
@property
|
|
572
|
+
@_builtins.property
|
|
573
|
+
@pulumi.getter
|
|
574
|
+
def services(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]]]:
|
|
575
|
+
"""
|
|
576
|
+
Set Services on host, the settings to be set are based on service being set as part of import.
|
|
577
|
+
"""
|
|
578
|
+
return pulumi.get(self, "services")
|
|
579
|
+
|
|
580
|
+
@services.setter
|
|
581
|
+
def services(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['HostServiceArgs']]]]):
|
|
582
|
+
pulumi.set(self, "services", value)
|
|
583
|
+
|
|
584
|
+
@_builtins.property
|
|
546
585
|
@pulumi.getter
|
|
547
|
-
def tags(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
|
|
586
|
+
def tags(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]:
|
|
548
587
|
"""
|
|
549
588
|
The IDs of any tags to attach to this resource. Please
|
|
550
589
|
refer to the `Tag` resource for more information on applying
|
|
@@ -556,12 +595,12 @@ class _HostState:
|
|
|
556
595
|
return pulumi.get(self, "tags")
|
|
557
596
|
|
|
558
597
|
@tags.setter
|
|
559
|
-
def tags(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
|
|
598
|
+
def tags(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]):
|
|
560
599
|
pulumi.set(self, "tags", value)
|
|
561
600
|
|
|
562
|
-
@property
|
|
601
|
+
@_builtins.property
|
|
563
602
|
@pulumi.getter
|
|
564
|
-
def thumbprint(self) -> Optional[pulumi.Input[str]]:
|
|
603
|
+
def thumbprint(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
565
604
|
"""
|
|
566
605
|
Host's certificate SHA-1 thumbprint. If not set the
|
|
567
606
|
CA that signed the host's certificate should be trusted. If the CA is not
|
|
@@ -571,12 +610,12 @@ class _HostState:
|
|
|
571
610
|
return pulumi.get(self, "thumbprint")
|
|
572
611
|
|
|
573
612
|
@thumbprint.setter
|
|
574
|
-
def thumbprint(self, value: Optional[pulumi.Input[str]]):
|
|
613
|
+
def thumbprint(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
575
614
|
pulumi.set(self, "thumbprint", value)
|
|
576
615
|
|
|
577
|
-
@property
|
|
616
|
+
@_builtins.property
|
|
578
617
|
@pulumi.getter
|
|
579
|
-
def username(self) -> Optional[pulumi.Input[str]]:
|
|
618
|
+
def username(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
580
619
|
"""
|
|
581
620
|
Username that will be used by vSphere to authenticate
|
|
582
621
|
to the host.
|
|
@@ -584,35 +623,38 @@ class _HostState:
|
|
|
584
623
|
return pulumi.get(self, "username")
|
|
585
624
|
|
|
586
625
|
@username.setter
|
|
587
|
-
def username(self, value: Optional[pulumi.Input[str]]):
|
|
626
|
+
def username(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
588
627
|
pulumi.set(self, "username", value)
|
|
589
628
|
|
|
590
629
|
|
|
630
|
+
@pulumi.type_token("vsphere:index/host:Host")
|
|
591
631
|
class Host(pulumi.CustomResource):
|
|
592
632
|
@overload
|
|
593
633
|
def __init__(__self__,
|
|
594
634
|
resource_name: str,
|
|
595
635
|
opts: Optional[pulumi.ResourceOptions] = None,
|
|
596
|
-
cluster: Optional[pulumi.Input[str]] = None,
|
|
597
|
-
cluster_managed: Optional[pulumi.Input[bool]] = None,
|
|
598
|
-
connected: Optional[pulumi.Input[bool]] = None,
|
|
599
|
-
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
|
|
600
|
-
datacenter: Optional[pulumi.Input[str]] = None,
|
|
601
|
-
force: Optional[pulumi.Input[bool]] = None,
|
|
602
|
-
hostname: Optional[pulumi.Input[str]] = None,
|
|
603
|
-
license: Optional[pulumi.Input[str]] = None,
|
|
604
|
-
lockdown: Optional[pulumi.Input[str]] = None,
|
|
605
|
-
maintenance: Optional[pulumi.Input[bool]] = None,
|
|
606
|
-
password: Optional[pulumi.Input[str]] = None,
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
636
|
+
cluster: Optional[pulumi.Input[_builtins.str]] = None,
|
|
637
|
+
cluster_managed: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
638
|
+
connected: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
639
|
+
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]] = None,
|
|
640
|
+
datacenter: Optional[pulumi.Input[_builtins.str]] = None,
|
|
641
|
+
force: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
642
|
+
hostname: Optional[pulumi.Input[_builtins.str]] = None,
|
|
643
|
+
license: Optional[pulumi.Input[_builtins.str]] = None,
|
|
644
|
+
lockdown: Optional[pulumi.Input[_builtins.str]] = None,
|
|
645
|
+
maintenance: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
646
|
+
password: Optional[pulumi.Input[_builtins.str]] = None,
|
|
647
|
+
services: Optional[pulumi.Input[Sequence[pulumi.Input[Union['HostServiceArgs', 'HostServiceArgsDict']]]]] = None,
|
|
648
|
+
tags: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
649
|
+
thumbprint: Optional[pulumi.Input[_builtins.str]] = None,
|
|
650
|
+
username: Optional[pulumi.Input[_builtins.str]] = None,
|
|
610
651
|
__props__=None):
|
|
611
652
|
"""
|
|
612
653
|
Provides a VMware vSphere host resource. This represents an ESXi host that
|
|
613
654
|
can be used either as a member of a cluster or as a standalone host.
|
|
614
655
|
|
|
615
656
|
## Example Usage
|
|
657
|
+
|
|
616
658
|
### Create a standalone host
|
|
617
659
|
|
|
618
660
|
```python
|
|
@@ -620,16 +662,17 @@ class Host(pulumi.CustomResource):
|
|
|
620
662
|
import pulumi_vsphere as vsphere
|
|
621
663
|
|
|
622
664
|
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
623
|
-
thumbprint = vsphere.get_host_thumbprint(address="
|
|
665
|
+
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com",
|
|
624
666
|
insecure=True)
|
|
625
667
|
esx_01 = vsphere.Host("esx-01",
|
|
626
|
-
hostname="
|
|
668
|
+
hostname="esxi-01.example.com",
|
|
627
669
|
username="root",
|
|
628
670
|
password="password",
|
|
629
671
|
license="00000-00000-00000-00000-00000",
|
|
630
672
|
thumbprint=thumbprint.id,
|
|
631
673
|
datacenter=datacenter.id)
|
|
632
674
|
```
|
|
675
|
+
|
|
633
676
|
### Create host in a compute cluster
|
|
634
677
|
|
|
635
678
|
```python
|
|
@@ -639,40 +682,137 @@ class Host(pulumi.CustomResource):
|
|
|
639
682
|
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
640
683
|
cluster = vsphere.get_compute_cluster(name="cluster-01",
|
|
641
684
|
datacenter_id=datacenter.id)
|
|
642
|
-
thumbprint = vsphere.get_host_thumbprint(address="
|
|
685
|
+
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com",
|
|
643
686
|
insecure=True)
|
|
644
687
|
esx_01 = vsphere.Host("esx-01",
|
|
645
|
-
hostname="
|
|
688
|
+
hostname="esxi-01.example.com",
|
|
646
689
|
username="root",
|
|
647
690
|
password="password",
|
|
648
691
|
license="00000-00000-00000-00000-00000",
|
|
649
692
|
thumbprint=thumbprint.id,
|
|
650
|
-
cluster=cluster.id
|
|
693
|
+
cluster=cluster.id,
|
|
694
|
+
services=[{
|
|
695
|
+
"ntpd": {
|
|
696
|
+
"enabled": True,
|
|
697
|
+
"policy": "on",
|
|
698
|
+
"ntp_servers": ["pool.ntp.org"],
|
|
699
|
+
},
|
|
700
|
+
}])
|
|
651
701
|
```
|
|
652
|
-
## Importing
|
|
653
702
|
|
|
654
|
-
|
|
655
|
-
|
|
703
|
+
## Import
|
|
704
|
+
|
|
705
|
+
An existing host can be imported into this resource by supplying
|
|
706
|
+
|
|
707
|
+
the host's ID.
|
|
656
708
|
|
|
657
709
|
[docs-import]: /docs/import/index.html
|
|
658
710
|
|
|
659
|
-
|
|
660
|
-
|
|
711
|
+
Obtain the host's ID using the data source. For example:
|
|
712
|
+
|
|
713
|
+
hcl
|
|
714
|
+
|
|
715
|
+
data "vsphere_datacenter" "datacenter" {
|
|
716
|
+
|
|
717
|
+
name = "dc-01"
|
|
718
|
+
|
|
719
|
+
}
|
|
720
|
+
|
|
721
|
+
data "vsphere_host" "host" {
|
|
722
|
+
|
|
723
|
+
name = "esxi-01.example.com"
|
|
724
|
+
|
|
725
|
+
datacenter_id = data.vsphere_datacenter.datacenter.id
|
|
726
|
+
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
output "host_id" {
|
|
730
|
+
|
|
731
|
+
value = data.vsphere_host.host.id
|
|
732
|
+
|
|
733
|
+
}
|
|
734
|
+
|
|
735
|
+
Next, create a resource configuration, For example:
|
|
736
|
+
|
|
737
|
+
hcl
|
|
738
|
+
|
|
739
|
+
data "vsphere_datacenter" "datacenter" {
|
|
740
|
+
|
|
741
|
+
name = "dc-01"
|
|
742
|
+
|
|
743
|
+
}
|
|
744
|
+
|
|
745
|
+
data "vsphere_host_thumbprint" "thumbprint" {
|
|
746
|
+
|
|
747
|
+
address = "esxi-01.example.com"
|
|
748
|
+
|
|
749
|
+
insecure = true
|
|
750
|
+
|
|
751
|
+
}
|
|
752
|
+
|
|
753
|
+
resource "vsphere_host" "esx-01" {
|
|
754
|
+
|
|
755
|
+
hostname = "esxi-01.example.com"
|
|
756
|
+
|
|
757
|
+
username = "root"
|
|
758
|
+
|
|
759
|
+
password = "password"
|
|
760
|
+
|
|
761
|
+
thumbprint = data.vsphere_host_thumbprint.thumbprint.id
|
|
762
|
+
|
|
763
|
+
datacenter = data.vsphere_datacenter.datacenter.id
|
|
764
|
+
|
|
765
|
+
}
|
|
766
|
+
|
|
767
|
+
hcl
|
|
768
|
+
|
|
769
|
+
resource "vsphere_host" "esx-01" {
|
|
770
|
+
|
|
771
|
+
hostname = "esxi-01.example.com"
|
|
772
|
+
|
|
773
|
+
username = "root"
|
|
774
|
+
|
|
775
|
+
password = "password"
|
|
776
|
+
|
|
777
|
+
license = "00000-00000-00000-00000-00000"
|
|
778
|
+
|
|
779
|
+
thumbprint = data.vsphere_host_thumbprint.thumbprint.id
|
|
780
|
+
|
|
781
|
+
cluster = data.vsphere_compute_cluster.cluster.id
|
|
782
|
+
|
|
783
|
+
services {
|
|
784
|
+
|
|
785
|
+
ntpd {
|
|
786
|
+
|
|
787
|
+
enabled = true
|
|
788
|
+
|
|
789
|
+
policy = "on"
|
|
790
|
+
|
|
791
|
+
ntp_servers = ["pool.ntp.org"]
|
|
792
|
+
|
|
793
|
+
}
|
|
794
|
+
|
|
795
|
+
}
|
|
796
|
+
|
|
797
|
+
}
|
|
798
|
+
|
|
799
|
+
```sh
|
|
800
|
+
$ pulumi import vsphere:index/host:Host esx-01 host-123
|
|
661
801
|
```
|
|
662
802
|
|
|
663
|
-
The above would import the host with ID `host-123`.
|
|
803
|
+
The above would import the host `esxi-01.example.com` with the host ID `host-123`.
|
|
664
804
|
|
|
665
805
|
:param str resource_name: The name of the resource.
|
|
666
806
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
667
|
-
:param pulumi.Input[str] cluster: The ID of the Compute Cluster this host should
|
|
807
|
+
:param pulumi.Input[_builtins.str] cluster: The ID of the Compute Cluster this host should
|
|
668
808
|
be added to. This should not be set if `datacenter` is set. Conflicts with:
|
|
669
809
|
`cluster_managed`.
|
|
670
|
-
:param pulumi.Input[bool] cluster_managed: Can be set to `true` if compute cluster
|
|
810
|
+
:param pulumi.Input[_builtins.bool] cluster_managed: Can be set to `true` if compute cluster
|
|
671
811
|
membership will be managed through the `compute_cluster` resource rather
|
|
672
812
|
than the`host` resource. Conflicts with: `cluster`.
|
|
673
|
-
:param pulumi.Input[bool] connected: If set to false then the host will be disconnected.
|
|
813
|
+
:param pulumi.Input[_builtins.bool] connected: If set to false then the host will be disconnected.
|
|
674
814
|
Default is `false`.
|
|
675
|
-
:param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: A map of custom attribute IDs and string
|
|
815
|
+
:param pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]] custom_attributes: A map of custom attribute IDs and string
|
|
676
816
|
values to apply to the resource. Please refer to the
|
|
677
817
|
`vsphere_custom_attributes` resource for more information on applying
|
|
678
818
|
tags to resources.
|
|
@@ -681,31 +821,32 @@ class Host(pulumi.CustomResource):
|
|
|
681
821
|
connections and require vCenter Server.
|
|
682
822
|
|
|
683
823
|
[docs-host-thumbprint-data-source]: /docs/providers/vsphere/d/host_thumbprint.html
|
|
684
|
-
:param pulumi.Input[str] datacenter: The ID of the datacenter this host should
|
|
824
|
+
:param pulumi.Input[_builtins.str] datacenter: The ID of the datacenter this host should
|
|
685
825
|
be added to. This should not be set if `cluster` is set.
|
|
686
|
-
:param pulumi.Input[bool] force: If set to `true` then it will force the host to be added,
|
|
826
|
+
:param pulumi.Input[_builtins.bool] force: If set to `true` then it will force the host to be added,
|
|
687
827
|
even if the host is already connected to a different vCenter Server instance.
|
|
688
828
|
Default is `false`.
|
|
689
|
-
:param pulumi.Input[str] hostname: FQDN or IP address of the host to be added.
|
|
690
|
-
:param pulumi.Input[str] license: The license key that will be applied to the host.
|
|
829
|
+
:param pulumi.Input[_builtins.str] hostname: FQDN or IP address of the host to be added.
|
|
830
|
+
:param pulumi.Input[_builtins.str] license: The license key that will be applied to the host.
|
|
691
831
|
The license key is expected to be present in vSphere.
|
|
692
|
-
:param pulumi.Input[str] lockdown: Set the lockdown state of the host. Valid options are
|
|
832
|
+
:param pulumi.Input[_builtins.str] lockdown: Set the lockdown state of the host. Valid options are
|
|
693
833
|
`disabled`, `normal`, and `strict`. Default is `disabled`.
|
|
694
|
-
:param pulumi.Input[bool] maintenance: Set the management state of the host.
|
|
834
|
+
:param pulumi.Input[_builtins.bool] maintenance: Set the management state of the host.
|
|
695
835
|
Default is `false`.
|
|
696
|
-
:param pulumi.Input[str] password: Password that will be used by vSphere to authenticate
|
|
836
|
+
:param pulumi.Input[_builtins.str] password: Password that will be used by vSphere to authenticate
|
|
697
837
|
to the host.
|
|
698
|
-
:param pulumi.Input[Sequence[pulumi.Input[
|
|
838
|
+
:param pulumi.Input[Sequence[pulumi.Input[Union['HostServiceArgs', 'HostServiceArgsDict']]]] services: Set Services on host, the settings to be set are based on service being set as part of import.
|
|
839
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] tags: The IDs of any tags to attach to this resource. Please
|
|
699
840
|
refer to the `Tag` resource for more information on applying
|
|
700
841
|
tags to resources.
|
|
701
842
|
|
|
702
843
|
> **NOTE:** Tagging support is not supported on direct ESXi host
|
|
703
844
|
connections and require vCenter Server.
|
|
704
|
-
:param pulumi.Input[str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
845
|
+
:param pulumi.Input[_builtins.str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
705
846
|
CA that signed the host's certificate should be trusted. If the CA is not
|
|
706
847
|
trusted and no thumbprint is set then the operation will fail. See data source
|
|
707
848
|
[`get_host_thumbprint`][docs-host-thumbprint-data-source].
|
|
708
|
-
:param pulumi.Input[str] username: Username that will be used by vSphere to authenticate
|
|
849
|
+
:param pulumi.Input[_builtins.str] username: Username that will be used by vSphere to authenticate
|
|
709
850
|
to the host.
|
|
710
851
|
"""
|
|
711
852
|
...
|
|
@@ -719,6 +860,7 @@ class Host(pulumi.CustomResource):
|
|
|
719
860
|
can be used either as a member of a cluster or as a standalone host.
|
|
720
861
|
|
|
721
862
|
## Example Usage
|
|
863
|
+
|
|
722
864
|
### Create a standalone host
|
|
723
865
|
|
|
724
866
|
```python
|
|
@@ -726,16 +868,17 @@ class Host(pulumi.CustomResource):
|
|
|
726
868
|
import pulumi_vsphere as vsphere
|
|
727
869
|
|
|
728
870
|
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
729
|
-
thumbprint = vsphere.get_host_thumbprint(address="
|
|
871
|
+
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com",
|
|
730
872
|
insecure=True)
|
|
731
873
|
esx_01 = vsphere.Host("esx-01",
|
|
732
|
-
hostname="
|
|
874
|
+
hostname="esxi-01.example.com",
|
|
733
875
|
username="root",
|
|
734
876
|
password="password",
|
|
735
877
|
license="00000-00000-00000-00000-00000",
|
|
736
878
|
thumbprint=thumbprint.id,
|
|
737
879
|
datacenter=datacenter.id)
|
|
738
880
|
```
|
|
881
|
+
|
|
739
882
|
### Create host in a compute cluster
|
|
740
883
|
|
|
741
884
|
```python
|
|
@@ -745,28 +888,125 @@ class Host(pulumi.CustomResource):
|
|
|
745
888
|
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
746
889
|
cluster = vsphere.get_compute_cluster(name="cluster-01",
|
|
747
890
|
datacenter_id=datacenter.id)
|
|
748
|
-
thumbprint = vsphere.get_host_thumbprint(address="
|
|
891
|
+
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com",
|
|
749
892
|
insecure=True)
|
|
750
893
|
esx_01 = vsphere.Host("esx-01",
|
|
751
|
-
hostname="
|
|
894
|
+
hostname="esxi-01.example.com",
|
|
752
895
|
username="root",
|
|
753
896
|
password="password",
|
|
754
897
|
license="00000-00000-00000-00000-00000",
|
|
755
898
|
thumbprint=thumbprint.id,
|
|
756
|
-
cluster=cluster.id
|
|
899
|
+
cluster=cluster.id,
|
|
900
|
+
services=[{
|
|
901
|
+
"ntpd": {
|
|
902
|
+
"enabled": True,
|
|
903
|
+
"policy": "on",
|
|
904
|
+
"ntp_servers": ["pool.ntp.org"],
|
|
905
|
+
},
|
|
906
|
+
}])
|
|
757
907
|
```
|
|
758
|
-
## Importing
|
|
759
908
|
|
|
760
|
-
|
|
761
|
-
|
|
909
|
+
## Import
|
|
910
|
+
|
|
911
|
+
An existing host can be imported into this resource by supplying
|
|
912
|
+
|
|
913
|
+
the host's ID.
|
|
762
914
|
|
|
763
915
|
[docs-import]: /docs/import/index.html
|
|
764
916
|
|
|
765
|
-
|
|
766
|
-
|
|
917
|
+
Obtain the host's ID using the data source. For example:
|
|
918
|
+
|
|
919
|
+
hcl
|
|
920
|
+
|
|
921
|
+
data "vsphere_datacenter" "datacenter" {
|
|
922
|
+
|
|
923
|
+
name = "dc-01"
|
|
924
|
+
|
|
925
|
+
}
|
|
926
|
+
|
|
927
|
+
data "vsphere_host" "host" {
|
|
928
|
+
|
|
929
|
+
name = "esxi-01.example.com"
|
|
930
|
+
|
|
931
|
+
datacenter_id = data.vsphere_datacenter.datacenter.id
|
|
932
|
+
|
|
933
|
+
}
|
|
934
|
+
|
|
935
|
+
output "host_id" {
|
|
936
|
+
|
|
937
|
+
value = data.vsphere_host.host.id
|
|
938
|
+
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
Next, create a resource configuration, For example:
|
|
942
|
+
|
|
943
|
+
hcl
|
|
944
|
+
|
|
945
|
+
data "vsphere_datacenter" "datacenter" {
|
|
946
|
+
|
|
947
|
+
name = "dc-01"
|
|
948
|
+
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
data "vsphere_host_thumbprint" "thumbprint" {
|
|
952
|
+
|
|
953
|
+
address = "esxi-01.example.com"
|
|
954
|
+
|
|
955
|
+
insecure = true
|
|
956
|
+
|
|
957
|
+
}
|
|
958
|
+
|
|
959
|
+
resource "vsphere_host" "esx-01" {
|
|
960
|
+
|
|
961
|
+
hostname = "esxi-01.example.com"
|
|
962
|
+
|
|
963
|
+
username = "root"
|
|
964
|
+
|
|
965
|
+
password = "password"
|
|
966
|
+
|
|
967
|
+
thumbprint = data.vsphere_host_thumbprint.thumbprint.id
|
|
968
|
+
|
|
969
|
+
datacenter = data.vsphere_datacenter.datacenter.id
|
|
970
|
+
|
|
971
|
+
}
|
|
972
|
+
|
|
973
|
+
hcl
|
|
974
|
+
|
|
975
|
+
resource "vsphere_host" "esx-01" {
|
|
976
|
+
|
|
977
|
+
hostname = "esxi-01.example.com"
|
|
978
|
+
|
|
979
|
+
username = "root"
|
|
980
|
+
|
|
981
|
+
password = "password"
|
|
982
|
+
|
|
983
|
+
license = "00000-00000-00000-00000-00000"
|
|
984
|
+
|
|
985
|
+
thumbprint = data.vsphere_host_thumbprint.thumbprint.id
|
|
986
|
+
|
|
987
|
+
cluster = data.vsphere_compute_cluster.cluster.id
|
|
988
|
+
|
|
989
|
+
services {
|
|
990
|
+
|
|
991
|
+
ntpd {
|
|
992
|
+
|
|
993
|
+
enabled = true
|
|
994
|
+
|
|
995
|
+
policy = "on"
|
|
996
|
+
|
|
997
|
+
ntp_servers = ["pool.ntp.org"]
|
|
998
|
+
|
|
999
|
+
}
|
|
1000
|
+
|
|
1001
|
+
}
|
|
1002
|
+
|
|
1003
|
+
}
|
|
1004
|
+
|
|
1005
|
+
```sh
|
|
1006
|
+
$ pulumi import vsphere:index/host:Host esx-01 host-123
|
|
767
1007
|
```
|
|
768
1008
|
|
|
769
|
-
The above would import the host with ID `host-123`.
|
|
1009
|
+
The above would import the host `esxi-01.example.com` with the host ID `host-123`.
|
|
770
1010
|
|
|
771
1011
|
:param str resource_name: The name of the resource.
|
|
772
1012
|
:param HostArgs args: The arguments to use to populate this resource's properties.
|
|
@@ -783,20 +1023,21 @@ class Host(pulumi.CustomResource):
|
|
|
783
1023
|
def _internal_init(__self__,
|
|
784
1024
|
resource_name: str,
|
|
785
1025
|
opts: Optional[pulumi.ResourceOptions] = None,
|
|
786
|
-
cluster: Optional[pulumi.Input[str]] = None,
|
|
787
|
-
cluster_managed: Optional[pulumi.Input[bool]] = None,
|
|
788
|
-
connected: Optional[pulumi.Input[bool]] = None,
|
|
789
|
-
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
|
|
790
|
-
datacenter: Optional[pulumi.Input[str]] = None,
|
|
791
|
-
force: Optional[pulumi.Input[bool]] = None,
|
|
792
|
-
hostname: Optional[pulumi.Input[str]] = None,
|
|
793
|
-
license: Optional[pulumi.Input[str]] = None,
|
|
794
|
-
lockdown: Optional[pulumi.Input[str]] = None,
|
|
795
|
-
maintenance: Optional[pulumi.Input[bool]] = None,
|
|
796
|
-
password: Optional[pulumi.Input[str]] = None,
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
1026
|
+
cluster: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1027
|
+
cluster_managed: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1028
|
+
connected: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1029
|
+
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]] = None,
|
|
1030
|
+
datacenter: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1031
|
+
force: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1032
|
+
hostname: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1033
|
+
license: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1034
|
+
lockdown: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1035
|
+
maintenance: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1036
|
+
password: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1037
|
+
services: Optional[pulumi.Input[Sequence[pulumi.Input[Union['HostServiceArgs', 'HostServiceArgsDict']]]]] = None,
|
|
1038
|
+
tags: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
1039
|
+
thumbprint: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1040
|
+
username: Optional[pulumi.Input[_builtins.str]] = None,
|
|
800
1041
|
__props__=None):
|
|
801
1042
|
opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
|
|
802
1043
|
if not isinstance(opts, pulumi.ResourceOptions):
|
|
@@ -821,6 +1062,7 @@ class Host(pulumi.CustomResource):
|
|
|
821
1062
|
if password is None and not opts.urn:
|
|
822
1063
|
raise TypeError("Missing required property 'password'")
|
|
823
1064
|
__props__.__dict__["password"] = None if password is None else pulumi.Output.secret(password)
|
|
1065
|
+
__props__.__dict__["services"] = services
|
|
824
1066
|
__props__.__dict__["tags"] = tags
|
|
825
1067
|
__props__.__dict__["thumbprint"] = thumbprint
|
|
826
1068
|
if username is None and not opts.urn:
|
|
@@ -838,20 +1080,21 @@ class Host(pulumi.CustomResource):
|
|
|
838
1080
|
def get(resource_name: str,
|
|
839
1081
|
id: pulumi.Input[str],
|
|
840
1082
|
opts: Optional[pulumi.ResourceOptions] = None,
|
|
841
|
-
cluster: Optional[pulumi.Input[str]] = None,
|
|
842
|
-
cluster_managed: Optional[pulumi.Input[bool]] = None,
|
|
843
|
-
connected: Optional[pulumi.Input[bool]] = None,
|
|
844
|
-
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
|
|
845
|
-
datacenter: Optional[pulumi.Input[str]] = None,
|
|
846
|
-
force: Optional[pulumi.Input[bool]] = None,
|
|
847
|
-
hostname: Optional[pulumi.Input[str]] = None,
|
|
848
|
-
license: Optional[pulumi.Input[str]] = None,
|
|
849
|
-
lockdown: Optional[pulumi.Input[str]] = None,
|
|
850
|
-
maintenance: Optional[pulumi.Input[bool]] = None,
|
|
851
|
-
password: Optional[pulumi.Input[str]] = None,
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
1083
|
+
cluster: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1084
|
+
cluster_managed: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1085
|
+
connected: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1086
|
+
custom_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]]] = None,
|
|
1087
|
+
datacenter: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1088
|
+
force: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1089
|
+
hostname: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1090
|
+
license: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1091
|
+
lockdown: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1092
|
+
maintenance: Optional[pulumi.Input[_builtins.bool]] = None,
|
|
1093
|
+
password: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1094
|
+
services: Optional[pulumi.Input[Sequence[pulumi.Input[Union['HostServiceArgs', 'HostServiceArgsDict']]]]] = None,
|
|
1095
|
+
tags: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
1096
|
+
thumbprint: Optional[pulumi.Input[_builtins.str]] = None,
|
|
1097
|
+
username: Optional[pulumi.Input[_builtins.str]] = None) -> 'Host':
|
|
855
1098
|
"""
|
|
856
1099
|
Get an existing Host resource's state with the given name, id, and optional extra
|
|
857
1100
|
properties used to qualify the lookup.
|
|
@@ -859,15 +1102,15 @@ class Host(pulumi.CustomResource):
|
|
|
859
1102
|
:param str resource_name: The unique name of the resulting resource.
|
|
860
1103
|
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
|
|
861
1104
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
862
|
-
:param pulumi.Input[str] cluster: The ID of the Compute Cluster this host should
|
|
1105
|
+
:param pulumi.Input[_builtins.str] cluster: The ID of the Compute Cluster this host should
|
|
863
1106
|
be added to. This should not be set if `datacenter` is set. Conflicts with:
|
|
864
1107
|
`cluster_managed`.
|
|
865
|
-
:param pulumi.Input[bool] cluster_managed: Can be set to `true` if compute cluster
|
|
1108
|
+
:param pulumi.Input[_builtins.bool] cluster_managed: Can be set to `true` if compute cluster
|
|
866
1109
|
membership will be managed through the `compute_cluster` resource rather
|
|
867
1110
|
than the`host` resource. Conflicts with: `cluster`.
|
|
868
|
-
:param pulumi.Input[bool] connected: If set to false then the host will be disconnected.
|
|
1111
|
+
:param pulumi.Input[_builtins.bool] connected: If set to false then the host will be disconnected.
|
|
869
1112
|
Default is `false`.
|
|
870
|
-
:param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: A map of custom attribute IDs and string
|
|
1113
|
+
:param pulumi.Input[Mapping[str, pulumi.Input[_builtins.str]]] custom_attributes: A map of custom attribute IDs and string
|
|
871
1114
|
values to apply to the resource. Please refer to the
|
|
872
1115
|
`vsphere_custom_attributes` resource for more information on applying
|
|
873
1116
|
tags to resources.
|
|
@@ -876,31 +1119,32 @@ class Host(pulumi.CustomResource):
|
|
|
876
1119
|
connections and require vCenter Server.
|
|
877
1120
|
|
|
878
1121
|
[docs-host-thumbprint-data-source]: /docs/providers/vsphere/d/host_thumbprint.html
|
|
879
|
-
:param pulumi.Input[str] datacenter: The ID of the datacenter this host should
|
|
1122
|
+
:param pulumi.Input[_builtins.str] datacenter: The ID of the datacenter this host should
|
|
880
1123
|
be added to. This should not be set if `cluster` is set.
|
|
881
|
-
:param pulumi.Input[bool] force: If set to `true` then it will force the host to be added,
|
|
1124
|
+
:param pulumi.Input[_builtins.bool] force: If set to `true` then it will force the host to be added,
|
|
882
1125
|
even if the host is already connected to a different vCenter Server instance.
|
|
883
1126
|
Default is `false`.
|
|
884
|
-
:param pulumi.Input[str] hostname: FQDN or IP address of the host to be added.
|
|
885
|
-
:param pulumi.Input[str] license: The license key that will be applied to the host.
|
|
1127
|
+
:param pulumi.Input[_builtins.str] hostname: FQDN or IP address of the host to be added.
|
|
1128
|
+
:param pulumi.Input[_builtins.str] license: The license key that will be applied to the host.
|
|
886
1129
|
The license key is expected to be present in vSphere.
|
|
887
|
-
:param pulumi.Input[str] lockdown: Set the lockdown state of the host. Valid options are
|
|
1130
|
+
:param pulumi.Input[_builtins.str] lockdown: Set the lockdown state of the host. Valid options are
|
|
888
1131
|
`disabled`, `normal`, and `strict`. Default is `disabled`.
|
|
889
|
-
:param pulumi.Input[bool] maintenance: Set the management state of the host.
|
|
1132
|
+
:param pulumi.Input[_builtins.bool] maintenance: Set the management state of the host.
|
|
890
1133
|
Default is `false`.
|
|
891
|
-
:param pulumi.Input[str] password: Password that will be used by vSphere to authenticate
|
|
1134
|
+
:param pulumi.Input[_builtins.str] password: Password that will be used by vSphere to authenticate
|
|
892
1135
|
to the host.
|
|
893
|
-
:param pulumi.Input[Sequence[pulumi.Input[
|
|
1136
|
+
:param pulumi.Input[Sequence[pulumi.Input[Union['HostServiceArgs', 'HostServiceArgsDict']]]] services: Set Services on host, the settings to be set are based on service being set as part of import.
|
|
1137
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] tags: The IDs of any tags to attach to this resource. Please
|
|
894
1138
|
refer to the `Tag` resource for more information on applying
|
|
895
1139
|
tags to resources.
|
|
896
1140
|
|
|
897
1141
|
> **NOTE:** Tagging support is not supported on direct ESXi host
|
|
898
1142
|
connections and require vCenter Server.
|
|
899
|
-
:param pulumi.Input[str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
1143
|
+
:param pulumi.Input[_builtins.str] thumbprint: Host's certificate SHA-1 thumbprint. If not set the
|
|
900
1144
|
CA that signed the host's certificate should be trusted. If the CA is not
|
|
901
1145
|
trusted and no thumbprint is set then the operation will fail. See data source
|
|
902
1146
|
[`get_host_thumbprint`][docs-host-thumbprint-data-source].
|
|
903
|
-
:param pulumi.Input[str] username: Username that will be used by vSphere to authenticate
|
|
1147
|
+
:param pulumi.Input[_builtins.str] username: Username that will be used by vSphere to authenticate
|
|
904
1148
|
to the host.
|
|
905
1149
|
"""
|
|
906
1150
|
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
|
|
@@ -918,14 +1162,15 @@ class Host(pulumi.CustomResource):
|
|
|
918
1162
|
__props__.__dict__["lockdown"] = lockdown
|
|
919
1163
|
__props__.__dict__["maintenance"] = maintenance
|
|
920
1164
|
__props__.__dict__["password"] = password
|
|
1165
|
+
__props__.__dict__["services"] = services
|
|
921
1166
|
__props__.__dict__["tags"] = tags
|
|
922
1167
|
__props__.__dict__["thumbprint"] = thumbprint
|
|
923
1168
|
__props__.__dict__["username"] = username
|
|
924
1169
|
return Host(resource_name, opts=opts, __props__=__props__)
|
|
925
1170
|
|
|
926
|
-
@property
|
|
1171
|
+
@_builtins.property
|
|
927
1172
|
@pulumi.getter
|
|
928
|
-
def cluster(self) -> pulumi.Output[Optional[str]]:
|
|
1173
|
+
def cluster(self) -> pulumi.Output[Optional[_builtins.str]]:
|
|
929
1174
|
"""
|
|
930
1175
|
The ID of the Compute Cluster this host should
|
|
931
1176
|
be added to. This should not be set if `datacenter` is set. Conflicts with:
|
|
@@ -933,9 +1178,9 @@ class Host(pulumi.CustomResource):
|
|
|
933
1178
|
"""
|
|
934
1179
|
return pulumi.get(self, "cluster")
|
|
935
1180
|
|
|
936
|
-
@property
|
|
1181
|
+
@_builtins.property
|
|
937
1182
|
@pulumi.getter(name="clusterManaged")
|
|
938
|
-
def cluster_managed(self) -> pulumi.Output[Optional[bool]]:
|
|
1183
|
+
def cluster_managed(self) -> pulumi.Output[Optional[_builtins.bool]]:
|
|
939
1184
|
"""
|
|
940
1185
|
Can be set to `true` if compute cluster
|
|
941
1186
|
membership will be managed through the `compute_cluster` resource rather
|
|
@@ -943,18 +1188,18 @@ class Host(pulumi.CustomResource):
|
|
|
943
1188
|
"""
|
|
944
1189
|
return pulumi.get(self, "cluster_managed")
|
|
945
1190
|
|
|
946
|
-
@property
|
|
1191
|
+
@_builtins.property
|
|
947
1192
|
@pulumi.getter
|
|
948
|
-
def connected(self) -> pulumi.Output[Optional[bool]]:
|
|
1193
|
+
def connected(self) -> pulumi.Output[Optional[_builtins.bool]]:
|
|
949
1194
|
"""
|
|
950
1195
|
If set to false then the host will be disconnected.
|
|
951
1196
|
Default is `false`.
|
|
952
1197
|
"""
|
|
953
1198
|
return pulumi.get(self, "connected")
|
|
954
1199
|
|
|
955
|
-
@property
|
|
1200
|
+
@_builtins.property
|
|
956
1201
|
@pulumi.getter(name="customAttributes")
|
|
957
|
-
def custom_attributes(self) -> pulumi.Output[Optional[Mapping[str, str]]]:
|
|
1202
|
+
def custom_attributes(self) -> pulumi.Output[Optional[Mapping[str, _builtins.str]]]:
|
|
958
1203
|
"""
|
|
959
1204
|
A map of custom attribute IDs and string
|
|
960
1205
|
values to apply to the resource. Please refer to the
|
|
@@ -968,18 +1213,18 @@ class Host(pulumi.CustomResource):
|
|
|
968
1213
|
"""
|
|
969
1214
|
return pulumi.get(self, "custom_attributes")
|
|
970
1215
|
|
|
971
|
-
@property
|
|
1216
|
+
@_builtins.property
|
|
972
1217
|
@pulumi.getter
|
|
973
|
-
def datacenter(self) -> pulumi.Output[Optional[str]]:
|
|
1218
|
+
def datacenter(self) -> pulumi.Output[Optional[_builtins.str]]:
|
|
974
1219
|
"""
|
|
975
1220
|
The ID of the datacenter this host should
|
|
976
1221
|
be added to. This should not be set if `cluster` is set.
|
|
977
1222
|
"""
|
|
978
1223
|
return pulumi.get(self, "datacenter")
|
|
979
1224
|
|
|
980
|
-
@property
|
|
1225
|
+
@_builtins.property
|
|
981
1226
|
@pulumi.getter
|
|
982
|
-
def force(self) -> pulumi.Output[Optional[bool]]:
|
|
1227
|
+
def force(self) -> pulumi.Output[Optional[_builtins.bool]]:
|
|
983
1228
|
"""
|
|
984
1229
|
If set to `true` then it will force the host to be added,
|
|
985
1230
|
even if the host is already connected to a different vCenter Server instance.
|
|
@@ -987,53 +1232,61 @@ class Host(pulumi.CustomResource):
|
|
|
987
1232
|
"""
|
|
988
1233
|
return pulumi.get(self, "force")
|
|
989
1234
|
|
|
990
|
-
@property
|
|
1235
|
+
@_builtins.property
|
|
991
1236
|
@pulumi.getter
|
|
992
|
-
def hostname(self) -> pulumi.Output[str]:
|
|
1237
|
+
def hostname(self) -> pulumi.Output[_builtins.str]:
|
|
993
1238
|
"""
|
|
994
1239
|
FQDN or IP address of the host to be added.
|
|
995
1240
|
"""
|
|
996
1241
|
return pulumi.get(self, "hostname")
|
|
997
1242
|
|
|
998
|
-
@property
|
|
1243
|
+
@_builtins.property
|
|
999
1244
|
@pulumi.getter
|
|
1000
|
-
def license(self) -> pulumi.Output[Optional[str]]:
|
|
1245
|
+
def license(self) -> pulumi.Output[Optional[_builtins.str]]:
|
|
1001
1246
|
"""
|
|
1002
1247
|
The license key that will be applied to the host.
|
|
1003
1248
|
The license key is expected to be present in vSphere.
|
|
1004
1249
|
"""
|
|
1005
1250
|
return pulumi.get(self, "license")
|
|
1006
1251
|
|
|
1007
|
-
@property
|
|
1252
|
+
@_builtins.property
|
|
1008
1253
|
@pulumi.getter
|
|
1009
|
-
def lockdown(self) -> pulumi.Output[Optional[str]]:
|
|
1254
|
+
def lockdown(self) -> pulumi.Output[Optional[_builtins.str]]:
|
|
1010
1255
|
"""
|
|
1011
1256
|
Set the lockdown state of the host. Valid options are
|
|
1012
1257
|
`disabled`, `normal`, and `strict`. Default is `disabled`.
|
|
1013
1258
|
"""
|
|
1014
1259
|
return pulumi.get(self, "lockdown")
|
|
1015
1260
|
|
|
1016
|
-
@property
|
|
1261
|
+
@_builtins.property
|
|
1017
1262
|
@pulumi.getter
|
|
1018
|
-
def maintenance(self) -> pulumi.Output[Optional[bool]]:
|
|
1263
|
+
def maintenance(self) -> pulumi.Output[Optional[_builtins.bool]]:
|
|
1019
1264
|
"""
|
|
1020
1265
|
Set the management state of the host.
|
|
1021
1266
|
Default is `false`.
|
|
1022
1267
|
"""
|
|
1023
1268
|
return pulumi.get(self, "maintenance")
|
|
1024
1269
|
|
|
1025
|
-
@property
|
|
1270
|
+
@_builtins.property
|
|
1026
1271
|
@pulumi.getter
|
|
1027
|
-
def password(self) -> pulumi.Output[str]:
|
|
1272
|
+
def password(self) -> pulumi.Output[_builtins.str]:
|
|
1028
1273
|
"""
|
|
1029
1274
|
Password that will be used by vSphere to authenticate
|
|
1030
1275
|
to the host.
|
|
1031
1276
|
"""
|
|
1032
1277
|
return pulumi.get(self, "password")
|
|
1033
1278
|
|
|
1034
|
-
@property
|
|
1279
|
+
@_builtins.property
|
|
1280
|
+
@pulumi.getter
|
|
1281
|
+
def services(self) -> pulumi.Output[Optional[Sequence['outputs.HostService']]]:
|
|
1282
|
+
"""
|
|
1283
|
+
Set Services on host, the settings to be set are based on service being set as part of import.
|
|
1284
|
+
"""
|
|
1285
|
+
return pulumi.get(self, "services")
|
|
1286
|
+
|
|
1287
|
+
@_builtins.property
|
|
1035
1288
|
@pulumi.getter
|
|
1036
|
-
def tags(self) -> pulumi.Output[Optional[Sequence[str]]]:
|
|
1289
|
+
def tags(self) -> pulumi.Output[Optional[Sequence[_builtins.str]]]:
|
|
1037
1290
|
"""
|
|
1038
1291
|
The IDs of any tags to attach to this resource. Please
|
|
1039
1292
|
refer to the `Tag` resource for more information on applying
|
|
@@ -1044,9 +1297,9 @@ class Host(pulumi.CustomResource):
|
|
|
1044
1297
|
"""
|
|
1045
1298
|
return pulumi.get(self, "tags")
|
|
1046
1299
|
|
|
1047
|
-
@property
|
|
1300
|
+
@_builtins.property
|
|
1048
1301
|
@pulumi.getter
|
|
1049
|
-
def thumbprint(self) -> pulumi.Output[Optional[str]]:
|
|
1302
|
+
def thumbprint(self) -> pulumi.Output[Optional[_builtins.str]]:
|
|
1050
1303
|
"""
|
|
1051
1304
|
Host's certificate SHA-1 thumbprint. If not set the
|
|
1052
1305
|
CA that signed the host's certificate should be trusted. If the CA is not
|
|
@@ -1055,9 +1308,9 @@ class Host(pulumi.CustomResource):
|
|
|
1055
1308
|
"""
|
|
1056
1309
|
return pulumi.get(self, "thumbprint")
|
|
1057
1310
|
|
|
1058
|
-
@property
|
|
1311
|
+
@_builtins.property
|
|
1059
1312
|
@pulumi.getter
|
|
1060
|
-
def username(self) -> pulumi.Output[str]:
|
|
1313
|
+
def username(self) -> pulumi.Output[_builtins.str]:
|
|
1061
1314
|
"""
|
|
1062
1315
|
Username that will be used by vSphere to authenticate
|
|
1063
1316
|
to the host.
|