pulumi-vsphere 4.14.0a1739946909__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 +12 -1
- pulumi_vsphere/_inputs.py +1172 -1172
- pulumi_vsphere/_utilities.py +1 -1
- pulumi_vsphere/compute_cluster.py +1226 -1484
- pulumi_vsphere/compute_cluster_host_group.py +124 -53
- pulumi_vsphere/compute_cluster_vm_affinity_rule.py +88 -87
- pulumi_vsphere/compute_cluster_vm_anti_affinity_rule.py +92 -87
- pulumi_vsphere/compute_cluster_vm_dependency_rule.py +109 -104
- pulumi_vsphere/compute_cluster_vm_group.py +58 -53
- pulumi_vsphere/compute_cluster_vm_host_rule.py +126 -121
- pulumi_vsphere/config/__init__.py +2 -1
- pulumi_vsphere/config/__init__.pyi +2 -2
- pulumi_vsphere/config/vars.py +15 -15
- pulumi_vsphere/configuration_profile.py +286 -0
- pulumi_vsphere/content_library.py +64 -59
- pulumi_vsphere/content_library_item.py +109 -104
- pulumi_vsphere/custom_attribute.py +41 -36
- pulumi_vsphere/datacenter.py +80 -79
- pulumi_vsphere/datastore_cluster.py +531 -477
- pulumi_vsphere/datastore_cluster_vm_anti_affinity_rule.py +92 -87
- pulumi_vsphere/distributed_port_group.py +802 -818
- pulumi_vsphere/distributed_virtual_switch.py +1590 -1620
- pulumi_vsphere/distributed_virtual_switch_pvlan_mapping.py +71 -70
- pulumi_vsphere/dpm_host_override.py +159 -70
- pulumi_vsphere/drs_vm_override.py +75 -70
- pulumi_vsphere/entity_permissions.py +40 -39
- pulumi_vsphere/file.py +148 -162
- pulumi_vsphere/folder.py +104 -99
- pulumi_vsphere/get_compute_cluster.py +18 -18
- pulumi_vsphere/get_compute_cluster_host_group.py +18 -22
- pulumi_vsphere/get_configuration_profile.py +145 -0
- pulumi_vsphere/get_content_library.py +10 -10
- pulumi_vsphere/get_content_library_item.py +22 -22
- pulumi_vsphere/get_custom_attribute.py +12 -12
- pulumi_vsphere/get_datacenter.py +12 -12
- pulumi_vsphere/get_datastore.py +22 -22
- pulumi_vsphere/get_datastore_cluster.py +19 -19
- pulumi_vsphere/get_datastore_stats.py +22 -26
- pulumi_vsphere/get_distributed_virtual_switch.py +18 -18
- pulumi_vsphere/get_dynamic.py +22 -26
- pulumi_vsphere/get_folder.py +140 -18
- pulumi_vsphere/get_guest_os_customization.py +74 -21
- pulumi_vsphere/get_host.py +18 -18
- pulumi_vsphere/get_host_base_images.py +6 -6
- pulumi_vsphere/get_host_pci_device.py +30 -30
- pulumi_vsphere/get_host_thumbprint.py +22 -22
- pulumi_vsphere/get_host_vgpu_profile.py +17 -17
- pulumi_vsphere/get_license.py +26 -24
- pulumi_vsphere/get_network.py +80 -29
- pulumi_vsphere/get_ovf_vm_template.py +126 -126
- pulumi_vsphere/get_policy.py +10 -10
- pulumi_vsphere/get_resource_pool.py +77 -26
- pulumi_vsphere/get_role.py +26 -26
- pulumi_vsphere/get_tag.py +18 -18
- pulumi_vsphere/get_tag_category.py +16 -16
- pulumi_vsphere/get_vapp_container.py +16 -16
- pulumi_vsphere/get_virtual_machine.py +273 -273
- pulumi_vsphere/get_vmfs_disks.py +24 -24
- pulumi_vsphere/guest_os_customization.py +75 -74
- pulumi_vsphere/ha_vm_override.py +295 -374
- pulumi_vsphere/host.py +304 -249
- pulumi_vsphere/host_port_group.py +321 -341
- pulumi_vsphere/host_virtual_switch.py +373 -389
- pulumi_vsphere/license.py +125 -84
- pulumi_vsphere/nas_datastore.py +324 -261
- pulumi_vsphere/offline_software_depot.py +26 -21
- pulumi_vsphere/outputs.py +1003 -970
- pulumi_vsphere/provider.py +165 -146
- pulumi_vsphere/pulumi-plugin.json +1 -1
- pulumi_vsphere/resource_pool.py +691 -364
- pulumi_vsphere/role.py +46 -45
- pulumi_vsphere/storage_drs_vm_override.py +92 -87
- pulumi_vsphere/supervisor.py +210 -209
- pulumi_vsphere/tag.py +58 -53
- pulumi_vsphere/tag_category.py +75 -70
- pulumi_vsphere/vapp_container.py +262 -257
- pulumi_vsphere/vapp_entity.py +177 -172
- pulumi_vsphere/virtual_disk.py +130 -125
- pulumi_vsphere/virtual_machine.py +1339 -1443
- pulumi_vsphere/virtual_machine_class.py +109 -108
- pulumi_vsphere/virtual_machine_snapshot.py +122 -121
- pulumi_vsphere/vm_storage_policy.py +40 -39
- pulumi_vsphere/vmfs_datastore.py +189 -184
- pulumi_vsphere/vnic.py +145 -144
- {pulumi_vsphere-4.14.0a1739946909.dist-info → pulumi_vsphere-4.17.0a1763710194.dist-info}/METADATA +4 -4
- pulumi_vsphere-4.17.0a1763710194.dist-info/RECORD +89 -0
- {pulumi_vsphere-4.14.0a1739946909.dist-info → pulumi_vsphere-4.17.0a1763710194.dist-info}/WHEEL +1 -1
- pulumi_vsphere-4.14.0a1739946909.dist-info/RECORD +0 -87
- {pulumi_vsphere-4.14.0a1739946909.dist-info → pulumi_vsphere-4.17.0a1763710194.dist-info}/top_level.txt +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
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
7
|
import sys
|
|
8
8
|
import pulumi
|
|
@@ -19,22 +19,22 @@ __all__ = ['ComputeClusterHostGroupArgs', 'ComputeClusterHostGroup']
|
|
|
19
19
|
@pulumi.input_type
|
|
20
20
|
class ComputeClusterHostGroupArgs:
|
|
21
21
|
def __init__(__self__, *,
|
|
22
|
-
compute_cluster_id: pulumi.Input[str],
|
|
23
|
-
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
|
|
24
|
-
name: Optional[pulumi.Input[str]] = None):
|
|
22
|
+
compute_cluster_id: pulumi.Input[_builtins.str],
|
|
23
|
+
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
24
|
+
name: Optional[pulumi.Input[_builtins.str]] = None):
|
|
25
25
|
"""
|
|
26
26
|
The set of arguments for constructing a ComputeClusterHostGroup resource.
|
|
27
|
-
:param pulumi.Input[str] compute_cluster_id: The managed object reference
|
|
27
|
+
:param pulumi.Input[_builtins.str] compute_cluster_id: The managed object reference
|
|
28
28
|
ID of the cluster to put the group in. Forces a new
|
|
29
29
|
resource if changed.
|
|
30
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] host_system_ids: The managed object IDs of
|
|
30
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] host_system_ids: The managed object IDs of
|
|
31
31
|
the hosts to put in the cluster.
|
|
32
32
|
|
|
33
33
|
> **NOTE:** The namespace for cluster names on this resource (defined by the
|
|
34
34
|
`name` argument) is shared with the
|
|
35
35
|
`ComputeClusterVmGroup`
|
|
36
36
|
resource. Make sure your names are unique across both resources.
|
|
37
|
-
:param pulumi.Input[str] name: The name of the host group. This must be unique in the
|
|
37
|
+
:param pulumi.Input[_builtins.str] name: The name of the host group. This must be unique in the
|
|
38
38
|
cluster. Forces a new resource if changed.
|
|
39
39
|
"""
|
|
40
40
|
pulumi.set(__self__, "compute_cluster_id", compute_cluster_id)
|
|
@@ -43,9 +43,9 @@ class ComputeClusterHostGroupArgs:
|
|
|
43
43
|
if name is not None:
|
|
44
44
|
pulumi.set(__self__, "name", name)
|
|
45
45
|
|
|
46
|
-
@property
|
|
46
|
+
@_builtins.property
|
|
47
47
|
@pulumi.getter(name="computeClusterId")
|
|
48
|
-
def compute_cluster_id(self) -> pulumi.Input[str]:
|
|
48
|
+
def compute_cluster_id(self) -> pulumi.Input[_builtins.str]:
|
|
49
49
|
"""
|
|
50
50
|
The managed object reference
|
|
51
51
|
ID of the cluster to put the group in. Forces a new
|
|
@@ -54,12 +54,12 @@ class ComputeClusterHostGroupArgs:
|
|
|
54
54
|
return pulumi.get(self, "compute_cluster_id")
|
|
55
55
|
|
|
56
56
|
@compute_cluster_id.setter
|
|
57
|
-
def compute_cluster_id(self, value: pulumi.Input[str]):
|
|
57
|
+
def compute_cluster_id(self, value: pulumi.Input[_builtins.str]):
|
|
58
58
|
pulumi.set(self, "compute_cluster_id", value)
|
|
59
59
|
|
|
60
|
-
@property
|
|
60
|
+
@_builtins.property
|
|
61
61
|
@pulumi.getter(name="hostSystemIds")
|
|
62
|
-
def host_system_ids(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
|
|
62
|
+
def host_system_ids(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]:
|
|
63
63
|
"""
|
|
64
64
|
The managed object IDs of
|
|
65
65
|
the hosts to put in the cluster.
|
|
@@ -72,12 +72,12 @@ class ComputeClusterHostGroupArgs:
|
|
|
72
72
|
return pulumi.get(self, "host_system_ids")
|
|
73
73
|
|
|
74
74
|
@host_system_ids.setter
|
|
75
|
-
def host_system_ids(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
|
|
75
|
+
def host_system_ids(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]):
|
|
76
76
|
pulumi.set(self, "host_system_ids", value)
|
|
77
77
|
|
|
78
|
-
@property
|
|
78
|
+
@_builtins.property
|
|
79
79
|
@pulumi.getter
|
|
80
|
-
def name(self) -> Optional[pulumi.Input[str]]:
|
|
80
|
+
def name(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
81
81
|
"""
|
|
82
82
|
The name of the host group. This must be unique in the
|
|
83
83
|
cluster. Forces a new resource if changed.
|
|
@@ -85,29 +85,29 @@ class ComputeClusterHostGroupArgs:
|
|
|
85
85
|
return pulumi.get(self, "name")
|
|
86
86
|
|
|
87
87
|
@name.setter
|
|
88
|
-
def name(self, value: Optional[pulumi.Input[str]]):
|
|
88
|
+
def name(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
89
89
|
pulumi.set(self, "name", value)
|
|
90
90
|
|
|
91
91
|
|
|
92
92
|
@pulumi.input_type
|
|
93
93
|
class _ComputeClusterHostGroupState:
|
|
94
94
|
def __init__(__self__, *,
|
|
95
|
-
compute_cluster_id: Optional[pulumi.Input[str]] = None,
|
|
96
|
-
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
|
|
97
|
-
name: Optional[pulumi.Input[str]] = None):
|
|
95
|
+
compute_cluster_id: Optional[pulumi.Input[_builtins.str]] = None,
|
|
96
|
+
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
97
|
+
name: Optional[pulumi.Input[_builtins.str]] = None):
|
|
98
98
|
"""
|
|
99
99
|
Input properties used for looking up and filtering ComputeClusterHostGroup resources.
|
|
100
|
-
:param pulumi.Input[str] compute_cluster_id: The managed object reference
|
|
100
|
+
:param pulumi.Input[_builtins.str] compute_cluster_id: The managed object reference
|
|
101
101
|
ID of the cluster to put the group in. Forces a new
|
|
102
102
|
resource if changed.
|
|
103
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] host_system_ids: The managed object IDs of
|
|
103
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] host_system_ids: The managed object IDs of
|
|
104
104
|
the hosts to put in the cluster.
|
|
105
105
|
|
|
106
106
|
> **NOTE:** The namespace for cluster names on this resource (defined by the
|
|
107
107
|
`name` argument) is shared with the
|
|
108
108
|
`ComputeClusterVmGroup`
|
|
109
109
|
resource. Make sure your names are unique across both resources.
|
|
110
|
-
:param pulumi.Input[str] name: The name of the host group. This must be unique in the
|
|
110
|
+
:param pulumi.Input[_builtins.str] name: The name of the host group. This must be unique in the
|
|
111
111
|
cluster. Forces a new resource if changed.
|
|
112
112
|
"""
|
|
113
113
|
if compute_cluster_id is not None:
|
|
@@ -117,9 +117,9 @@ class _ComputeClusterHostGroupState:
|
|
|
117
117
|
if name is not None:
|
|
118
118
|
pulumi.set(__self__, "name", name)
|
|
119
119
|
|
|
120
|
-
@property
|
|
120
|
+
@_builtins.property
|
|
121
121
|
@pulumi.getter(name="computeClusterId")
|
|
122
|
-
def compute_cluster_id(self) -> Optional[pulumi.Input[str]]:
|
|
122
|
+
def compute_cluster_id(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
123
123
|
"""
|
|
124
124
|
The managed object reference
|
|
125
125
|
ID of the cluster to put the group in. Forces a new
|
|
@@ -128,12 +128,12 @@ class _ComputeClusterHostGroupState:
|
|
|
128
128
|
return pulumi.get(self, "compute_cluster_id")
|
|
129
129
|
|
|
130
130
|
@compute_cluster_id.setter
|
|
131
|
-
def compute_cluster_id(self, value: Optional[pulumi.Input[str]]):
|
|
131
|
+
def compute_cluster_id(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
132
132
|
pulumi.set(self, "compute_cluster_id", value)
|
|
133
133
|
|
|
134
|
-
@property
|
|
134
|
+
@_builtins.property
|
|
135
135
|
@pulumi.getter(name="hostSystemIds")
|
|
136
|
-
def host_system_ids(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
|
|
136
|
+
def host_system_ids(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]:
|
|
137
137
|
"""
|
|
138
138
|
The managed object IDs of
|
|
139
139
|
the hosts to put in the cluster.
|
|
@@ -146,12 +146,12 @@ class _ComputeClusterHostGroupState:
|
|
|
146
146
|
return pulumi.get(self, "host_system_ids")
|
|
147
147
|
|
|
148
148
|
@host_system_ids.setter
|
|
149
|
-
def host_system_ids(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
|
|
149
|
+
def host_system_ids(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]]):
|
|
150
150
|
pulumi.set(self, "host_system_ids", value)
|
|
151
151
|
|
|
152
|
-
@property
|
|
152
|
+
@_builtins.property
|
|
153
153
|
@pulumi.getter
|
|
154
|
-
def name(self) -> Optional[pulumi.Input[str]]:
|
|
154
|
+
def name(self) -> Optional[pulumi.Input[_builtins.str]]:
|
|
155
155
|
"""
|
|
156
156
|
The name of the host group. This must be unique in the
|
|
157
157
|
cluster. Forces a new resource if changed.
|
|
@@ -159,18 +159,19 @@ class _ComputeClusterHostGroupState:
|
|
|
159
159
|
return pulumi.get(self, "name")
|
|
160
160
|
|
|
161
161
|
@name.setter
|
|
162
|
-
def name(self, value: Optional[pulumi.Input[str]]):
|
|
162
|
+
def name(self, value: Optional[pulumi.Input[_builtins.str]]):
|
|
163
163
|
pulumi.set(self, "name", value)
|
|
164
164
|
|
|
165
165
|
|
|
166
|
+
@pulumi.type_token("vsphere:index/computeClusterHostGroup:ComputeClusterHostGroup")
|
|
166
167
|
class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
167
168
|
@overload
|
|
168
169
|
def __init__(__self__,
|
|
169
170
|
resource_name: str,
|
|
170
171
|
opts: Optional[pulumi.ResourceOptions] = None,
|
|
171
|
-
compute_cluster_id: Optional[pulumi.Input[str]] = None,
|
|
172
|
-
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
|
|
173
|
-
name: Optional[pulumi.Input[str]] = None,
|
|
172
|
+
compute_cluster_id: Optional[pulumi.Input[_builtins.str]] = None,
|
|
173
|
+
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
174
|
+
name: Optional[pulumi.Input[_builtins.str]] = None,
|
|
174
175
|
__props__=None):
|
|
175
176
|
"""
|
|
176
177
|
The `ComputeClusterHostGroup` resource can be used to manage groups
|
|
@@ -186,6 +187,39 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
186
187
|
> **NOTE:** This resource requires vCenter and is not available on direct ESXi
|
|
187
188
|
connections.
|
|
188
189
|
|
|
190
|
+
## Example Usage
|
|
191
|
+
|
|
192
|
+
```python
|
|
193
|
+
import pulumi
|
|
194
|
+
import pulumi_vsphere as vsphere
|
|
195
|
+
|
|
196
|
+
config = pulumi.Config()
|
|
197
|
+
datacenter = config.get("datacenter")
|
|
198
|
+
if datacenter is None:
|
|
199
|
+
datacenter = "dc-01"
|
|
200
|
+
hosts = config.get_object("hosts")
|
|
201
|
+
if hosts is None:
|
|
202
|
+
hosts = [
|
|
203
|
+
"esxi-01.example.com",
|
|
204
|
+
"esxi-02.example.com",
|
|
205
|
+
"esxi-03.example.com",
|
|
206
|
+
]
|
|
207
|
+
datacenter_get_datacenter = vsphere.get_datacenter(name=datacenter)
|
|
208
|
+
hosts_get_host = [vsphere.get_host(name=hosts[__index],
|
|
209
|
+
datacenter_id=datacenter_get_datacenter.id) for __index in range(len(hosts))]
|
|
210
|
+
compute_cluster = vsphere.ComputeCluster("compute_cluster",
|
|
211
|
+
name="compute-cluster-test",
|
|
212
|
+
datacenter_id=dc["id"],
|
|
213
|
+
host_system_ids=[[__item.id for __item in hosts_get_host]],
|
|
214
|
+
drs_enabled=True,
|
|
215
|
+
drs_automation_level="fullyAutomated",
|
|
216
|
+
ha_enabled=True)
|
|
217
|
+
cluster_host_group = vsphere.ComputeClusterHostGroup("cluster_host_group",
|
|
218
|
+
name="test-cluster-host-group",
|
|
219
|
+
compute_cluster_id=compute_cluster.id,
|
|
220
|
+
host_system_ids=[[__item.id for __item in hosts_get_host]])
|
|
221
|
+
```
|
|
222
|
+
|
|
189
223
|
## Import
|
|
190
224
|
|
|
191
225
|
An existing group can be imported into this resource by
|
|
@@ -196,6 +230,8 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
196
230
|
|
|
197
231
|
will be returned. An example is below:
|
|
198
232
|
|
|
233
|
+
[docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
234
|
+
|
|
199
235
|
```sh
|
|
200
236
|
$ pulumi import vsphere:index/computeClusterHostGroup:ComputeClusterHostGroup cluster_host_group \\
|
|
201
237
|
```
|
|
@@ -206,17 +242,17 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
206
242
|
|
|
207
243
|
:param str resource_name: The name of the resource.
|
|
208
244
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
209
|
-
:param pulumi.Input[str] compute_cluster_id: The managed object reference
|
|
245
|
+
:param pulumi.Input[_builtins.str] compute_cluster_id: The managed object reference
|
|
210
246
|
ID of the cluster to put the group in. Forces a new
|
|
211
247
|
resource if changed.
|
|
212
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] host_system_ids: The managed object IDs of
|
|
248
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] host_system_ids: The managed object IDs of
|
|
213
249
|
the hosts to put in the cluster.
|
|
214
250
|
|
|
215
251
|
> **NOTE:** The namespace for cluster names on this resource (defined by the
|
|
216
252
|
`name` argument) is shared with the
|
|
217
253
|
`ComputeClusterVmGroup`
|
|
218
254
|
resource. Make sure your names are unique across both resources.
|
|
219
|
-
:param pulumi.Input[str] name: The name of the host group. This must be unique in the
|
|
255
|
+
:param pulumi.Input[_builtins.str] name: The name of the host group. This must be unique in the
|
|
220
256
|
cluster. Forces a new resource if changed.
|
|
221
257
|
"""
|
|
222
258
|
...
|
|
@@ -239,6 +275,39 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
239
275
|
> **NOTE:** This resource requires vCenter and is not available on direct ESXi
|
|
240
276
|
connections.
|
|
241
277
|
|
|
278
|
+
## Example Usage
|
|
279
|
+
|
|
280
|
+
```python
|
|
281
|
+
import pulumi
|
|
282
|
+
import pulumi_vsphere as vsphere
|
|
283
|
+
|
|
284
|
+
config = pulumi.Config()
|
|
285
|
+
datacenter = config.get("datacenter")
|
|
286
|
+
if datacenter is None:
|
|
287
|
+
datacenter = "dc-01"
|
|
288
|
+
hosts = config.get_object("hosts")
|
|
289
|
+
if hosts is None:
|
|
290
|
+
hosts = [
|
|
291
|
+
"esxi-01.example.com",
|
|
292
|
+
"esxi-02.example.com",
|
|
293
|
+
"esxi-03.example.com",
|
|
294
|
+
]
|
|
295
|
+
datacenter_get_datacenter = vsphere.get_datacenter(name=datacenter)
|
|
296
|
+
hosts_get_host = [vsphere.get_host(name=hosts[__index],
|
|
297
|
+
datacenter_id=datacenter_get_datacenter.id) for __index in range(len(hosts))]
|
|
298
|
+
compute_cluster = vsphere.ComputeCluster("compute_cluster",
|
|
299
|
+
name="compute-cluster-test",
|
|
300
|
+
datacenter_id=dc["id"],
|
|
301
|
+
host_system_ids=[[__item.id for __item in hosts_get_host]],
|
|
302
|
+
drs_enabled=True,
|
|
303
|
+
drs_automation_level="fullyAutomated",
|
|
304
|
+
ha_enabled=True)
|
|
305
|
+
cluster_host_group = vsphere.ComputeClusterHostGroup("cluster_host_group",
|
|
306
|
+
name="test-cluster-host-group",
|
|
307
|
+
compute_cluster_id=compute_cluster.id,
|
|
308
|
+
host_system_ids=[[__item.id for __item in hosts_get_host]])
|
|
309
|
+
```
|
|
310
|
+
|
|
242
311
|
## Import
|
|
243
312
|
|
|
244
313
|
An existing group can be imported into this resource by
|
|
@@ -249,6 +318,8 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
249
318
|
|
|
250
319
|
will be returned. An example is below:
|
|
251
320
|
|
|
321
|
+
[docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
322
|
+
|
|
252
323
|
```sh
|
|
253
324
|
$ pulumi import vsphere:index/computeClusterHostGroup:ComputeClusterHostGroup cluster_host_group \\
|
|
254
325
|
```
|
|
@@ -272,9 +343,9 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
272
343
|
def _internal_init(__self__,
|
|
273
344
|
resource_name: str,
|
|
274
345
|
opts: Optional[pulumi.ResourceOptions] = None,
|
|
275
|
-
compute_cluster_id: Optional[pulumi.Input[str]] = None,
|
|
276
|
-
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
|
|
277
|
-
name: Optional[pulumi.Input[str]] = None,
|
|
346
|
+
compute_cluster_id: Optional[pulumi.Input[_builtins.str]] = None,
|
|
347
|
+
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
348
|
+
name: Optional[pulumi.Input[_builtins.str]] = None,
|
|
278
349
|
__props__=None):
|
|
279
350
|
opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
|
|
280
351
|
if not isinstance(opts, pulumi.ResourceOptions):
|
|
@@ -299,9 +370,9 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
299
370
|
def get(resource_name: str,
|
|
300
371
|
id: pulumi.Input[str],
|
|
301
372
|
opts: Optional[pulumi.ResourceOptions] = None,
|
|
302
|
-
compute_cluster_id: Optional[pulumi.Input[str]] = None,
|
|
303
|
-
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
|
|
304
|
-
name: Optional[pulumi.Input[str]] = None) -> 'ComputeClusterHostGroup':
|
|
373
|
+
compute_cluster_id: Optional[pulumi.Input[_builtins.str]] = None,
|
|
374
|
+
host_system_ids: Optional[pulumi.Input[Sequence[pulumi.Input[_builtins.str]]]] = None,
|
|
375
|
+
name: Optional[pulumi.Input[_builtins.str]] = None) -> 'ComputeClusterHostGroup':
|
|
305
376
|
"""
|
|
306
377
|
Get an existing ComputeClusterHostGroup resource's state with the given name, id, and optional extra
|
|
307
378
|
properties used to qualify the lookup.
|
|
@@ -309,17 +380,17 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
309
380
|
:param str resource_name: The unique name of the resulting resource.
|
|
310
381
|
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
|
|
311
382
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
312
|
-
:param pulumi.Input[str] compute_cluster_id: The managed object reference
|
|
383
|
+
:param pulumi.Input[_builtins.str] compute_cluster_id: The managed object reference
|
|
313
384
|
ID of the cluster to put the group in. Forces a new
|
|
314
385
|
resource if changed.
|
|
315
|
-
:param pulumi.Input[Sequence[pulumi.Input[str]]] host_system_ids: The managed object IDs of
|
|
386
|
+
:param pulumi.Input[Sequence[pulumi.Input[_builtins.str]]] host_system_ids: The managed object IDs of
|
|
316
387
|
the hosts to put in the cluster.
|
|
317
388
|
|
|
318
389
|
> **NOTE:** The namespace for cluster names on this resource (defined by the
|
|
319
390
|
`name` argument) is shared with the
|
|
320
391
|
`ComputeClusterVmGroup`
|
|
321
392
|
resource. Make sure your names are unique across both resources.
|
|
322
|
-
:param pulumi.Input[str] name: The name of the host group. This must be unique in the
|
|
393
|
+
:param pulumi.Input[_builtins.str] name: The name of the host group. This must be unique in the
|
|
323
394
|
cluster. Forces a new resource if changed.
|
|
324
395
|
"""
|
|
325
396
|
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
|
|
@@ -331,9 +402,9 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
331
402
|
__props__.__dict__["name"] = name
|
|
332
403
|
return ComputeClusterHostGroup(resource_name, opts=opts, __props__=__props__)
|
|
333
404
|
|
|
334
|
-
@property
|
|
405
|
+
@_builtins.property
|
|
335
406
|
@pulumi.getter(name="computeClusterId")
|
|
336
|
-
def compute_cluster_id(self) -> pulumi.Output[str]:
|
|
407
|
+
def compute_cluster_id(self) -> pulumi.Output[_builtins.str]:
|
|
337
408
|
"""
|
|
338
409
|
The managed object reference
|
|
339
410
|
ID of the cluster to put the group in. Forces a new
|
|
@@ -341,9 +412,9 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
341
412
|
"""
|
|
342
413
|
return pulumi.get(self, "compute_cluster_id")
|
|
343
414
|
|
|
344
|
-
@property
|
|
415
|
+
@_builtins.property
|
|
345
416
|
@pulumi.getter(name="hostSystemIds")
|
|
346
|
-
def host_system_ids(self) -> pulumi.Output[Optional[Sequence[str]]]:
|
|
417
|
+
def host_system_ids(self) -> pulumi.Output[Optional[Sequence[_builtins.str]]]:
|
|
347
418
|
"""
|
|
348
419
|
The managed object IDs of
|
|
349
420
|
the hosts to put in the cluster.
|
|
@@ -355,9 +426,9 @@ class ComputeClusterHostGroup(pulumi.CustomResource):
|
|
|
355
426
|
"""
|
|
356
427
|
return pulumi.get(self, "host_system_ids")
|
|
357
428
|
|
|
358
|
-
@property
|
|
429
|
+
@_builtins.property
|
|
359
430
|
@pulumi.getter
|
|
360
|
-
def name(self) -> pulumi.Output[str]:
|
|
431
|
+
def name(self) -> pulumi.Output[_builtins.str]:
|
|
361
432
|
"""
|
|
362
433
|
The name of the host group. This must be unique in the
|
|
363
434
|
cluster. Forces a new resource if changed.
|