pulumi-vsphere 4.9.0a1698129503__py3-none-any.whl → 4.9.0a1698198425__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/_inputs.py +311 -93
- pulumi_vsphere/_utilities.py +19 -0
- pulumi_vsphere/compute_cluster.py +259 -3
- pulumi_vsphere/compute_cluster_host_group.py +17 -3
- pulumi_vsphere/compute_cluster_vm_affinity_rule.py +20 -130
- pulumi_vsphere/compute_cluster_vm_anti_affinity_rule.py +20 -4
- pulumi_vsphere/compute_cluster_vm_dependency_rule.py +27 -5
- pulumi_vsphere/compute_cluster_vm_group.py +17 -3
- pulumi_vsphere/compute_cluster_vm_host_rule.py +28 -4
- pulumi_vsphere/content_library.py +15 -13
- pulumi_vsphere/content_library_item.py +21 -3
- pulumi_vsphere/custom_attribute.py +10 -2
- pulumi_vsphere/datacenter.py +10 -34
- pulumi_vsphere/datastore_cluster.py +97 -3
- pulumi_vsphere/datastore_cluster_vm_anti_affinity_rule.py +20 -4
- pulumi_vsphere/distributed_port_group.py +175 -3
- pulumi_vsphere/distributed_virtual_switch.py +355 -115
- pulumi_vsphere/dpm_host_override.py +28 -4
- pulumi_vsphere/drs_vm_override.py +28 -4
- pulumi_vsphere/entity_permissions.py +23 -5
- pulumi_vsphere/file.py +35 -61
- pulumi_vsphere/folder.py +20 -4
- pulumi_vsphere/get_compute_cluster.py +0 -22
- pulumi_vsphere/get_compute_cluster_host_group.py +0 -34
- pulumi_vsphere/get_content_library.py +0 -18
- pulumi_vsphere/get_custom_attribute.py +0 -18
- pulumi_vsphere/get_datacenter.py +0 -18
- pulumi_vsphere/get_datastore.py +0 -22
- pulumi_vsphere/get_datastore_cluster.py +0 -22
- pulumi_vsphere/get_distributed_virtual_switch.py +0 -40
- pulumi_vsphere/get_dynamic.py +0 -38
- pulumi_vsphere/get_folder.py +0 -18
- pulumi_vsphere/get_host.py +0 -22
- pulumi_vsphere/get_host_pci_device.py +2 -26
- pulumi_vsphere/get_host_thumbprint.py +0 -18
- pulumi_vsphere/get_license.py +0 -18
- pulumi_vsphere/get_network.py +0 -22
- pulumi_vsphere/get_policy.py +0 -20
- pulumi_vsphere/get_resource_pool.py +0 -64
- pulumi_vsphere/get_role.py +0 -18
- pulumi_vsphere/get_tag.py +0 -22
- pulumi_vsphere/get_tag_category.py +0 -18
- pulumi_vsphere/get_vapp_container.py +0 -22
- pulumi_vsphere/get_virtual_machine.py +0 -54
- pulumi_vsphere/get_vmfs_disks.py +0 -28
- pulumi_vsphere/ha_vm_override.py +72 -4
- pulumi_vsphere/host.py +23 -101
- pulumi_vsphere/host_port_group.py +74 -132
- pulumi_vsphere/host_virtual_switch.py +87 -5
- pulumi_vsphere/license.py +15 -31
- pulumi_vsphere/nas_datastore.py +53 -5
- pulumi_vsphere/outputs.py +364 -104
- pulumi_vsphere/provider.py +31 -3
- pulumi_vsphere/resource_pool.py +61 -83
- pulumi_vsphere/role.py +10 -2
- pulumi_vsphere/storage_drs_vm_override.py +32 -4
- pulumi_vsphere/tag.py +13 -3
- pulumi_vsphere/tag_category.py +16 -4
- pulumi_vsphere/vapp_container.py +61 -3
- pulumi_vsphere/vapp_entity.py +48 -4
- pulumi_vsphere/virtual_disk.py +27 -5
- pulumi_vsphere/virtual_machine.py +284 -18
- pulumi_vsphere/virtual_machine_snapshot.py +33 -39
- pulumi_vsphere/vm_storage_policy.py +13 -205
- pulumi_vsphere/vmfs_datastore.py +32 -4
- pulumi_vsphere/vnic.py +19 -153
- {pulumi_vsphere-4.9.0a1698129503.dist-info → pulumi_vsphere-4.9.0a1698198425.dist-info}/METADATA +1 -1
- pulumi_vsphere-4.9.0a1698198425.dist-info/RECORD +77 -0
- pulumi_vsphere-4.9.0a1698129503.dist-info/RECORD +0 -77
- {pulumi_vsphere-4.9.0a1698129503.dist-info → pulumi_vsphere-4.9.0a1698198425.dist-info}/WHEEL +0 -0
- {pulumi_vsphere-4.9.0a1698129503.dist-info → pulumi_vsphere-4.9.0a1698198425.dist-info}/top_level.txt +0 -0
|
@@ -81,15 +81,6 @@ def get_host_thumbprint(address: Optional[str] = None,
|
|
|
81
81
|
resource. If the ESXi host is using a certificate chain, the first one returned
|
|
82
82
|
will be used to generate the thumbprint.
|
|
83
83
|
|
|
84
|
-
## Example Usage
|
|
85
|
-
|
|
86
|
-
```python
|
|
87
|
-
import pulumi
|
|
88
|
-
import pulumi_vsphere as vsphere
|
|
89
|
-
|
|
90
|
-
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com")
|
|
91
|
-
```
|
|
92
|
-
|
|
93
84
|
|
|
94
85
|
:param str address: The address of the ESXi host to retrieve the
|
|
95
86
|
thumbprint from.
|
|
@@ -122,15 +113,6 @@ def get_host_thumbprint_output(address: Optional[pulumi.Input[str]] = None,
|
|
|
122
113
|
resource. If the ESXi host is using a certificate chain, the first one returned
|
|
123
114
|
will be used to generate the thumbprint.
|
|
124
115
|
|
|
125
|
-
## Example Usage
|
|
126
|
-
|
|
127
|
-
```python
|
|
128
|
-
import pulumi
|
|
129
|
-
import pulumi_vsphere as vsphere
|
|
130
|
-
|
|
131
|
-
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com")
|
|
132
|
-
```
|
|
133
|
-
|
|
134
116
|
|
|
135
117
|
:param str address: The address of the ESXi host to retrieve the
|
|
136
118
|
thumbprint from.
|
pulumi_vsphere/get_license.py
CHANGED
|
@@ -116,15 +116,6 @@ def get_license(license_key: Optional[str] = None,
|
|
|
116
116
|
The `License` data source can be used to get the general attributes of
|
|
117
117
|
a license keys from a vCenter Server instance.
|
|
118
118
|
|
|
119
|
-
## Example Usage
|
|
120
|
-
|
|
121
|
-
```python
|
|
122
|
-
import pulumi
|
|
123
|
-
import pulumi_vsphere as vsphere
|
|
124
|
-
|
|
125
|
-
license = vsphere.get_license(license_key="00000-00000-00000-00000-00000")
|
|
126
|
-
```
|
|
127
|
-
|
|
128
119
|
|
|
129
120
|
:param str license_key: The license key.
|
|
130
121
|
"""
|
|
@@ -150,15 +141,6 @@ def get_license_output(license_key: Optional[pulumi.Input[str]] = None,
|
|
|
150
141
|
The `License` data source can be used to get the general attributes of
|
|
151
142
|
a license keys from a vCenter Server instance.
|
|
152
143
|
|
|
153
|
-
## Example Usage
|
|
154
|
-
|
|
155
|
-
```python
|
|
156
|
-
import pulumi
|
|
157
|
-
import pulumi_vsphere as vsphere
|
|
158
|
-
|
|
159
|
-
license = vsphere.get_license(license_key="00000-00000-00000-00000-00000")
|
|
160
|
-
```
|
|
161
|
-
|
|
162
144
|
|
|
163
145
|
:param str license_key: The license key.
|
|
164
146
|
"""
|
pulumi_vsphere/get_network.py
CHANGED
|
@@ -97,17 +97,6 @@ def get_network(datacenter_id: Optional[str] = None,
|
|
|
97
97
|
that requires a network. This includes standard (host-based) port groups,
|
|
98
98
|
distributed port groups, or opaque networks such as those managed by NSX.
|
|
99
99
|
|
|
100
|
-
## Example Usage
|
|
101
|
-
|
|
102
|
-
```python
|
|
103
|
-
import pulumi
|
|
104
|
-
import pulumi_vsphere as vsphere
|
|
105
|
-
|
|
106
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
107
|
-
network = vsphere.get_network(name="VM Network",
|
|
108
|
-
datacenter_id=datacenter.id)
|
|
109
|
-
```
|
|
110
|
-
|
|
111
100
|
|
|
112
101
|
:param str datacenter_id: The managed object reference ID
|
|
113
102
|
of the datacenter the network is located in. This can be omitted if the
|
|
@@ -146,17 +135,6 @@ def get_network_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = No
|
|
|
146
135
|
that requires a network. This includes standard (host-based) port groups,
|
|
147
136
|
distributed port groups, or opaque networks such as those managed by NSX.
|
|
148
137
|
|
|
149
|
-
## Example Usage
|
|
150
|
-
|
|
151
|
-
```python
|
|
152
|
-
import pulumi
|
|
153
|
-
import pulumi_vsphere as vsphere
|
|
154
|
-
|
|
155
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
156
|
-
network = vsphere.get_network(name="VM Network",
|
|
157
|
-
datacenter_id=datacenter.id)
|
|
158
|
-
```
|
|
159
|
-
|
|
160
138
|
|
|
161
139
|
:param str datacenter_id: The managed object reference ID
|
|
162
140
|
of the datacenter the network is located in. This can be omitted if the
|
pulumi_vsphere/get_policy.py
CHANGED
|
@@ -63,16 +63,6 @@ def get_policy(name: Optional[str] = None,
|
|
|
63
63
|
> **NOTE:** Storage policies are not supported on direct ESXi hosts and
|
|
64
64
|
requires vCenter Server.
|
|
65
65
|
|
|
66
|
-
## Example Usage
|
|
67
|
-
|
|
68
|
-
```python
|
|
69
|
-
import pulumi
|
|
70
|
-
import pulumi_vsphere as vsphere
|
|
71
|
-
|
|
72
|
-
prod_platinum_replicated = vsphere.get_policy(name="prod_platinum_replicated")
|
|
73
|
-
dev_silver_nonreplicated = vsphere.get_policy(name="dev_silver_nonreplicated")
|
|
74
|
-
```
|
|
75
|
-
|
|
76
66
|
|
|
77
67
|
:param str name: The name of the storage policy.
|
|
78
68
|
"""
|
|
@@ -97,16 +87,6 @@ def get_policy_output(name: Optional[pulumi.Input[str]] = None,
|
|
|
97
87
|
> **NOTE:** Storage policies are not supported on direct ESXi hosts and
|
|
98
88
|
requires vCenter Server.
|
|
99
89
|
|
|
100
|
-
## Example Usage
|
|
101
|
-
|
|
102
|
-
```python
|
|
103
|
-
import pulumi
|
|
104
|
-
import pulumi_vsphere as vsphere
|
|
105
|
-
|
|
106
|
-
prod_platinum_replicated = vsphere.get_policy(name="prod_platinum_replicated")
|
|
107
|
-
dev_silver_nonreplicated = vsphere.get_policy(name="dev_silver_nonreplicated")
|
|
108
|
-
```
|
|
109
|
-
|
|
110
90
|
|
|
111
91
|
:param str name: The name of the storage policy.
|
|
112
92
|
"""
|
|
@@ -71,38 +71,6 @@ def get_resource_pool(datacenter_id: Optional[str] = None,
|
|
|
71
71
|
that you want to use to create virtual machines in using the
|
|
72
72
|
`VirtualMachine` resource.
|
|
73
73
|
|
|
74
|
-
## Example Usage
|
|
75
|
-
|
|
76
|
-
```python
|
|
77
|
-
import pulumi
|
|
78
|
-
import pulumi_vsphere as vsphere
|
|
79
|
-
|
|
80
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
81
|
-
pool = vsphere.get_resource_pool(name="resource-pool-01",
|
|
82
|
-
datacenter_id=datacenter.id)
|
|
83
|
-
```
|
|
84
|
-
### Specifying the Root Resource Pool for a Standalone ESXi Host
|
|
85
|
-
|
|
86
|
-
> **NOTE:** Returning the root resource pool for a cluster can be done
|
|
87
|
-
directly via the `ComputeCluster`
|
|
88
|
-
data source.
|
|
89
|
-
|
|
90
|
-
All compute resources in vSphere have a resource pool, even if one has not been
|
|
91
|
-
explicitly created. This resource pool is referred to as the
|
|
92
|
-
_root resource pool_ and can be looked up by specifying the path.
|
|
93
|
-
|
|
94
|
-
```python
|
|
95
|
-
import pulumi
|
|
96
|
-
import pulumi_vsphere as vsphere
|
|
97
|
-
|
|
98
|
-
pool = vsphere.get_resource_pool(name="esxi-01.example.com/Resources",
|
|
99
|
-
datacenter_id=data["vsphere_datacenter"]["datacenter"]["id"])
|
|
100
|
-
```
|
|
101
|
-
|
|
102
|
-
For more information on the root resource pool, see [Managing Resource Pools][vmware-docs-resource-pools] in the vSphere documentation.
|
|
103
|
-
|
|
104
|
-
[vmware-docs-resource-pools]: https://docs.vmware.com/en/VMware-vSphere/7.0/com.vmware.vsphere.resmgmt.doc/GUID-60077B40-66FF-4625-934A-641703ED7601.html
|
|
105
|
-
|
|
106
74
|
|
|
107
75
|
:param str datacenter_id: The managed object reference ID
|
|
108
76
|
of the datacenter in which the resource pool is located. This can be omitted
|
|
@@ -138,38 +106,6 @@ def get_resource_pool_output(datacenter_id: Optional[pulumi.Input[Optional[str]]
|
|
|
138
106
|
that you want to use to create virtual machines in using the
|
|
139
107
|
`VirtualMachine` resource.
|
|
140
108
|
|
|
141
|
-
## Example Usage
|
|
142
|
-
|
|
143
|
-
```python
|
|
144
|
-
import pulumi
|
|
145
|
-
import pulumi_vsphere as vsphere
|
|
146
|
-
|
|
147
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
148
|
-
pool = vsphere.get_resource_pool(name="resource-pool-01",
|
|
149
|
-
datacenter_id=datacenter.id)
|
|
150
|
-
```
|
|
151
|
-
### Specifying the Root Resource Pool for a Standalone ESXi Host
|
|
152
|
-
|
|
153
|
-
> **NOTE:** Returning the root resource pool for a cluster can be done
|
|
154
|
-
directly via the `ComputeCluster`
|
|
155
|
-
data source.
|
|
156
|
-
|
|
157
|
-
All compute resources in vSphere have a resource pool, even if one has not been
|
|
158
|
-
explicitly created. This resource pool is referred to as the
|
|
159
|
-
_root resource pool_ and can be looked up by specifying the path.
|
|
160
|
-
|
|
161
|
-
```python
|
|
162
|
-
import pulumi
|
|
163
|
-
import pulumi_vsphere as vsphere
|
|
164
|
-
|
|
165
|
-
pool = vsphere.get_resource_pool(name="esxi-01.example.com/Resources",
|
|
166
|
-
datacenter_id=data["vsphere_datacenter"]["datacenter"]["id"])
|
|
167
|
-
```
|
|
168
|
-
|
|
169
|
-
For more information on the root resource pool, see [Managing Resource Pools][vmware-docs-resource-pools] in the vSphere documentation.
|
|
170
|
-
|
|
171
|
-
[vmware-docs-resource-pools]: https://docs.vmware.com/en/VMware-vSphere/7.0/com.vmware.vsphere.resmgmt.doc/GUID-60077B40-66FF-4625-934A-641703ED7601.html
|
|
172
|
-
|
|
173
109
|
|
|
174
110
|
:param str datacenter_id: The managed object reference ID
|
|
175
111
|
of the datacenter in which the resource pool is located. This can be omitted
|
pulumi_vsphere/get_role.py
CHANGED
|
@@ -98,15 +98,6 @@ def get_role(description: Optional[str] = None,
|
|
|
98
98
|
The `Role` data source can be used to discover the `id` and privileges associated
|
|
99
99
|
with a role given its name or display label.
|
|
100
100
|
|
|
101
|
-
## Example Usage
|
|
102
|
-
|
|
103
|
-
```python
|
|
104
|
-
import pulumi
|
|
105
|
-
import pulumi_vsphere as vsphere
|
|
106
|
-
|
|
107
|
-
terraform_role = vsphere.get_role(label="Terraform to vSphere Integration Role")
|
|
108
|
-
```
|
|
109
|
-
|
|
110
101
|
|
|
111
102
|
:param str description: The description of the role.
|
|
112
103
|
:param str label: The label of the role.
|
|
@@ -138,15 +129,6 @@ def get_role_output(description: Optional[pulumi.Input[Optional[str]]] = None,
|
|
|
138
129
|
The `Role` data source can be used to discover the `id` and privileges associated
|
|
139
130
|
with a role given its name or display label.
|
|
140
131
|
|
|
141
|
-
## Example Usage
|
|
142
|
-
|
|
143
|
-
```python
|
|
144
|
-
import pulumi
|
|
145
|
-
import pulumi_vsphere as vsphere
|
|
146
|
-
|
|
147
|
-
terraform_role = vsphere.get_role(label="Terraform to vSphere Integration Role")
|
|
148
|
-
```
|
|
149
|
-
|
|
150
132
|
|
|
151
133
|
:param str description: The description of the role.
|
|
152
134
|
:param str label: The label of the role.
|
pulumi_vsphere/get_tag.py
CHANGED
|
@@ -84,17 +84,6 @@ def get_tag(category_id: Optional[str] = None,
|
|
|
84
84
|
> **NOTE:** Tagging is not supported on direct ESXi hosts connections and
|
|
85
85
|
requires vCenter Server.
|
|
86
86
|
|
|
87
|
-
## Example Usage
|
|
88
|
-
|
|
89
|
-
```python
|
|
90
|
-
import pulumi
|
|
91
|
-
import pulumi_vsphere as vsphere
|
|
92
|
-
|
|
93
|
-
category = vsphere.get_tag_category(name="example-category")
|
|
94
|
-
tag = vsphere.get_tag(name="example-tag",
|
|
95
|
-
category_id=category.id)
|
|
96
|
-
```
|
|
97
|
-
|
|
98
87
|
|
|
99
88
|
:param str category_id: The ID of the tag category in which the tag is
|
|
100
89
|
located.
|
|
@@ -127,17 +116,6 @@ def get_tag_output(category_id: Optional[pulumi.Input[str]] = None,
|
|
|
127
116
|
> **NOTE:** Tagging is not supported on direct ESXi hosts connections and
|
|
128
117
|
requires vCenter Server.
|
|
129
118
|
|
|
130
|
-
## Example Usage
|
|
131
|
-
|
|
132
|
-
```python
|
|
133
|
-
import pulumi
|
|
134
|
-
import pulumi_vsphere as vsphere
|
|
135
|
-
|
|
136
|
-
category = vsphere.get_tag_category(name="example-category")
|
|
137
|
-
tag = vsphere.get_tag(name="example-tag",
|
|
138
|
-
category_id=category.id)
|
|
139
|
-
```
|
|
140
|
-
|
|
141
119
|
|
|
142
120
|
:param str category_id: The ID of the tag category in which the tag is
|
|
143
121
|
located.
|
|
@@ -92,15 +92,6 @@ def get_tag_category(name: Optional[str] = None,
|
|
|
92
92
|
> **NOTE:** Tagging is not supported on direct ESXi hosts connections and
|
|
93
93
|
requires vCenter Server.
|
|
94
94
|
|
|
95
|
-
## Example Usage
|
|
96
|
-
|
|
97
|
-
```python
|
|
98
|
-
import pulumi
|
|
99
|
-
import pulumi_vsphere as vsphere
|
|
100
|
-
|
|
101
|
-
category = vsphere.get_tag_category(name="example-category")
|
|
102
|
-
```
|
|
103
|
-
|
|
104
95
|
|
|
105
96
|
:param str name: The name of the tag category.
|
|
106
97
|
"""
|
|
@@ -130,15 +121,6 @@ def get_tag_category_output(name: Optional[pulumi.Input[str]] = None,
|
|
|
130
121
|
> **NOTE:** Tagging is not supported on direct ESXi hosts connections and
|
|
131
122
|
requires vCenter Server.
|
|
132
123
|
|
|
133
|
-
## Example Usage
|
|
134
|
-
|
|
135
|
-
```python
|
|
136
|
-
import pulumi
|
|
137
|
-
import pulumi_vsphere as vsphere
|
|
138
|
-
|
|
139
|
-
category = vsphere.get_tag_category(name="example-category")
|
|
140
|
-
```
|
|
141
|
-
|
|
142
124
|
|
|
143
125
|
:param str name: The name of the tag category.
|
|
144
126
|
"""
|
|
@@ -71,17 +71,6 @@ def get_vapp_container(datacenter_id: Optional[str] = None,
|
|
|
71
71
|
that you want to use to create virtual machines in using the
|
|
72
72
|
`VirtualMachine` resource.
|
|
73
73
|
|
|
74
|
-
## Example Usage
|
|
75
|
-
|
|
76
|
-
```python
|
|
77
|
-
import pulumi
|
|
78
|
-
import pulumi_vsphere as vsphere
|
|
79
|
-
|
|
80
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
81
|
-
pool = vsphere.get_vapp_container(name="vapp-container-01",
|
|
82
|
-
datacenter_id=datacenter.id)
|
|
83
|
-
```
|
|
84
|
-
|
|
85
74
|
|
|
86
75
|
:param str datacenter_id: The managed object reference ID
|
|
87
76
|
of the datacenter in which the vApp container is located.
|
|
@@ -110,17 +99,6 @@ def get_vapp_container_output(datacenter_id: Optional[pulumi.Input[str]] = None,
|
|
|
110
99
|
that you want to use to create virtual machines in using the
|
|
111
100
|
`VirtualMachine` resource.
|
|
112
101
|
|
|
113
|
-
## Example Usage
|
|
114
|
-
|
|
115
|
-
```python
|
|
116
|
-
import pulumi
|
|
117
|
-
import pulumi_vsphere as vsphere
|
|
118
|
-
|
|
119
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
120
|
-
pool = vsphere.get_vapp_container(name="vapp-container-01",
|
|
121
|
-
datacenter_id=datacenter.id)
|
|
122
|
-
```
|
|
123
|
-
|
|
124
102
|
|
|
125
103
|
:param str datacenter_id: The managed object reference ID
|
|
126
104
|
of the datacenter in which the vApp container is located.
|
|
@@ -737,33 +737,6 @@ def get_virtual_machine(alternate_guest_name: Optional[str] = None,
|
|
|
737
737
|
`VirtualMachine` resource. It also
|
|
738
738
|
reads the guest ID so that can be supplied as well.
|
|
739
739
|
|
|
740
|
-
## Example Usage
|
|
741
|
-
|
|
742
|
-
In the following example, a virtual machine template is returned by its
|
|
743
|
-
unique name within the `Datacenter`.
|
|
744
|
-
|
|
745
|
-
```python
|
|
746
|
-
import pulumi
|
|
747
|
-
import pulumi_vsphere as vsphere
|
|
748
|
-
|
|
749
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
750
|
-
template = vsphere.get_virtual_machine(name="ubuntu-server-template",
|
|
751
|
-
datacenter_id=datacenter.id)
|
|
752
|
-
```
|
|
753
|
-
In the following example, each virtual machine template is returned by its
|
|
754
|
-
unique full path within the `Datacenter`.
|
|
755
|
-
|
|
756
|
-
```python
|
|
757
|
-
import pulumi
|
|
758
|
-
import pulumi_vsphere as vsphere
|
|
759
|
-
|
|
760
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
761
|
-
production_template = vsphere.get_virtual_machine(name="production/templates/ubuntu-server-template",
|
|
762
|
-
datacenter_id=datacenter.id)
|
|
763
|
-
development_template = vsphere.get_virtual_machine(name="development/templates/ubuntu-server-template",
|
|
764
|
-
datacenter_id=datacenter.id)
|
|
765
|
-
```
|
|
766
|
-
|
|
767
740
|
|
|
768
741
|
:param str alternate_guest_name: The alternate guest name of the virtual machine when
|
|
769
742
|
`guest_id` is a non-specific operating system, like `otherGuest` or `otherGuest64`.
|
|
@@ -979,33 +952,6 @@ def get_virtual_machine_output(alternate_guest_name: Optional[pulumi.Input[Optio
|
|
|
979
952
|
`VirtualMachine` resource. It also
|
|
980
953
|
reads the guest ID so that can be supplied as well.
|
|
981
954
|
|
|
982
|
-
## Example Usage
|
|
983
|
-
|
|
984
|
-
In the following example, a virtual machine template is returned by its
|
|
985
|
-
unique name within the `Datacenter`.
|
|
986
|
-
|
|
987
|
-
```python
|
|
988
|
-
import pulumi
|
|
989
|
-
import pulumi_vsphere as vsphere
|
|
990
|
-
|
|
991
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
992
|
-
template = vsphere.get_virtual_machine(name="ubuntu-server-template",
|
|
993
|
-
datacenter_id=datacenter.id)
|
|
994
|
-
```
|
|
995
|
-
In the following example, each virtual machine template is returned by its
|
|
996
|
-
unique full path within the `Datacenter`.
|
|
997
|
-
|
|
998
|
-
```python
|
|
999
|
-
import pulumi
|
|
1000
|
-
import pulumi_vsphere as vsphere
|
|
1001
|
-
|
|
1002
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
1003
|
-
production_template = vsphere.get_virtual_machine(name="production/templates/ubuntu-server-template",
|
|
1004
|
-
datacenter_id=datacenter.id)
|
|
1005
|
-
development_template = vsphere.get_virtual_machine(name="development/templates/ubuntu-server-template",
|
|
1006
|
-
datacenter_id=datacenter.id)
|
|
1007
|
-
```
|
|
1008
|
-
|
|
1009
955
|
|
|
1010
956
|
:param str alternate_guest_name: The alternate guest name of the virtual machine when
|
|
1011
957
|
`guest_id` is a non-specific operating system, like `otherGuest` or `otherGuest64`.
|
pulumi_vsphere/get_vmfs_disks.py
CHANGED
|
@@ -94,20 +94,6 @@ def get_vmfs_disks(filter: Optional[str] = None,
|
|
|
94
94
|
`VmfsDatastore` resource to create VMFS
|
|
95
95
|
datastores based off a set of discovered disks.
|
|
96
96
|
|
|
97
|
-
## Example Usage
|
|
98
|
-
|
|
99
|
-
```python
|
|
100
|
-
import pulumi
|
|
101
|
-
import pulumi_vsphere as vsphere
|
|
102
|
-
|
|
103
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
104
|
-
host = vsphere.get_host(name="esxi-01.example.com",
|
|
105
|
-
datacenter_id=datacenter.id)
|
|
106
|
-
vmfs_disks = vsphere.get_vmfs_disks(host_system_id=host.id,
|
|
107
|
-
rescan=True,
|
|
108
|
-
filter="mpx.vmhba1:C0:T[12]:L0")
|
|
109
|
-
```
|
|
110
|
-
|
|
111
97
|
|
|
112
98
|
:param str filter: A regular expression to filter the disks against. Only
|
|
113
99
|
disks with canonical names that match will be included.
|
|
@@ -147,20 +133,6 @@ def get_vmfs_disks_output(filter: Optional[pulumi.Input[Optional[str]]] = None,
|
|
|
147
133
|
`VmfsDatastore` resource to create VMFS
|
|
148
134
|
datastores based off a set of discovered disks.
|
|
149
135
|
|
|
150
|
-
## Example Usage
|
|
151
|
-
|
|
152
|
-
```python
|
|
153
|
-
import pulumi
|
|
154
|
-
import pulumi_vsphere as vsphere
|
|
155
|
-
|
|
156
|
-
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
157
|
-
host = vsphere.get_host(name="esxi-01.example.com",
|
|
158
|
-
datacenter_id=datacenter.id)
|
|
159
|
-
vmfs_disks = vsphere.get_vmfs_disks(host_system_id=host.id,
|
|
160
|
-
rescan=True,
|
|
161
|
-
filter="mpx.vmhba1:C0:T[12]:L0")
|
|
162
|
-
```
|
|
163
|
-
|
|
164
136
|
|
|
165
137
|
:param str filter: A regular expression to filter the disks against. Only
|
|
166
138
|
disks with canonical names that match will be included.
|
pulumi_vsphere/ha_vm_override.py
CHANGED
|
@@ -107,8 +107,8 @@ class HaVmOverrideArgs:
|
|
|
107
107
|
@staticmethod
|
|
108
108
|
def _configure(
|
|
109
109
|
_setter: Callable[[Any, Any], None],
|
|
110
|
-
compute_cluster_id: pulumi.Input[str],
|
|
111
|
-
virtual_machine_id: pulumi.Input[str],
|
|
110
|
+
compute_cluster_id: Optional[pulumi.Input[str]] = None,
|
|
111
|
+
virtual_machine_id: Optional[pulumi.Input[str]] = None,
|
|
112
112
|
ha_datastore_apd_recovery_action: Optional[pulumi.Input[str]] = None,
|
|
113
113
|
ha_datastore_apd_response: Optional[pulumi.Input[str]] = None,
|
|
114
114
|
ha_datastore_apd_response_delay: Optional[pulumi.Input[int]] = None,
|
|
@@ -122,7 +122,43 @@ class HaVmOverrideArgs:
|
|
|
122
122
|
ha_vm_monitoring_use_cluster_defaults: Optional[pulumi.Input[bool]] = None,
|
|
123
123
|
ha_vm_restart_priority: Optional[pulumi.Input[str]] = None,
|
|
124
124
|
ha_vm_restart_timeout: Optional[pulumi.Input[int]] = None,
|
|
125
|
-
opts: Optional[pulumi.ResourceOptions]=None
|
|
125
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
|
126
|
+
**kwargs):
|
|
127
|
+
if compute_cluster_id is None and 'computeClusterId' in kwargs:
|
|
128
|
+
compute_cluster_id = kwargs['computeClusterId']
|
|
129
|
+
if compute_cluster_id is None:
|
|
130
|
+
raise TypeError("Missing 'compute_cluster_id' argument")
|
|
131
|
+
if virtual_machine_id is None and 'virtualMachineId' in kwargs:
|
|
132
|
+
virtual_machine_id = kwargs['virtualMachineId']
|
|
133
|
+
if virtual_machine_id is None:
|
|
134
|
+
raise TypeError("Missing 'virtual_machine_id' argument")
|
|
135
|
+
if ha_datastore_apd_recovery_action is None and 'haDatastoreApdRecoveryAction' in kwargs:
|
|
136
|
+
ha_datastore_apd_recovery_action = kwargs['haDatastoreApdRecoveryAction']
|
|
137
|
+
if ha_datastore_apd_response is None and 'haDatastoreApdResponse' in kwargs:
|
|
138
|
+
ha_datastore_apd_response = kwargs['haDatastoreApdResponse']
|
|
139
|
+
if ha_datastore_apd_response_delay is None and 'haDatastoreApdResponseDelay' in kwargs:
|
|
140
|
+
ha_datastore_apd_response_delay = kwargs['haDatastoreApdResponseDelay']
|
|
141
|
+
if ha_datastore_pdl_response is None and 'haDatastorePdlResponse' in kwargs:
|
|
142
|
+
ha_datastore_pdl_response = kwargs['haDatastorePdlResponse']
|
|
143
|
+
if ha_host_isolation_response is None and 'haHostIsolationResponse' in kwargs:
|
|
144
|
+
ha_host_isolation_response = kwargs['haHostIsolationResponse']
|
|
145
|
+
if ha_vm_failure_interval is None and 'haVmFailureInterval' in kwargs:
|
|
146
|
+
ha_vm_failure_interval = kwargs['haVmFailureInterval']
|
|
147
|
+
if ha_vm_maximum_failure_window is None and 'haVmMaximumFailureWindow' in kwargs:
|
|
148
|
+
ha_vm_maximum_failure_window = kwargs['haVmMaximumFailureWindow']
|
|
149
|
+
if ha_vm_maximum_resets is None and 'haVmMaximumResets' in kwargs:
|
|
150
|
+
ha_vm_maximum_resets = kwargs['haVmMaximumResets']
|
|
151
|
+
if ha_vm_minimum_uptime is None and 'haVmMinimumUptime' in kwargs:
|
|
152
|
+
ha_vm_minimum_uptime = kwargs['haVmMinimumUptime']
|
|
153
|
+
if ha_vm_monitoring is None and 'haVmMonitoring' in kwargs:
|
|
154
|
+
ha_vm_monitoring = kwargs['haVmMonitoring']
|
|
155
|
+
if ha_vm_monitoring_use_cluster_defaults is None and 'haVmMonitoringUseClusterDefaults' in kwargs:
|
|
156
|
+
ha_vm_monitoring_use_cluster_defaults = kwargs['haVmMonitoringUseClusterDefaults']
|
|
157
|
+
if ha_vm_restart_priority is None and 'haVmRestartPriority' in kwargs:
|
|
158
|
+
ha_vm_restart_priority = kwargs['haVmRestartPriority']
|
|
159
|
+
if ha_vm_restart_timeout is None and 'haVmRestartTimeout' in kwargs:
|
|
160
|
+
ha_vm_restart_timeout = kwargs['haVmRestartTimeout']
|
|
161
|
+
|
|
126
162
|
_setter("compute_cluster_id", compute_cluster_id)
|
|
127
163
|
_setter("virtual_machine_id", virtual_machine_id)
|
|
128
164
|
if ha_datastore_apd_recovery_action is not None:
|
|
@@ -483,7 +519,39 @@ class _HaVmOverrideState:
|
|
|
483
519
|
ha_vm_restart_priority: Optional[pulumi.Input[str]] = None,
|
|
484
520
|
ha_vm_restart_timeout: Optional[pulumi.Input[int]] = None,
|
|
485
521
|
virtual_machine_id: Optional[pulumi.Input[str]] = None,
|
|
486
|
-
opts: Optional[pulumi.ResourceOptions]=None
|
|
522
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
|
523
|
+
**kwargs):
|
|
524
|
+
if compute_cluster_id is None and 'computeClusterId' in kwargs:
|
|
525
|
+
compute_cluster_id = kwargs['computeClusterId']
|
|
526
|
+
if ha_datastore_apd_recovery_action is None and 'haDatastoreApdRecoveryAction' in kwargs:
|
|
527
|
+
ha_datastore_apd_recovery_action = kwargs['haDatastoreApdRecoveryAction']
|
|
528
|
+
if ha_datastore_apd_response is None and 'haDatastoreApdResponse' in kwargs:
|
|
529
|
+
ha_datastore_apd_response = kwargs['haDatastoreApdResponse']
|
|
530
|
+
if ha_datastore_apd_response_delay is None and 'haDatastoreApdResponseDelay' in kwargs:
|
|
531
|
+
ha_datastore_apd_response_delay = kwargs['haDatastoreApdResponseDelay']
|
|
532
|
+
if ha_datastore_pdl_response is None and 'haDatastorePdlResponse' in kwargs:
|
|
533
|
+
ha_datastore_pdl_response = kwargs['haDatastorePdlResponse']
|
|
534
|
+
if ha_host_isolation_response is None and 'haHostIsolationResponse' in kwargs:
|
|
535
|
+
ha_host_isolation_response = kwargs['haHostIsolationResponse']
|
|
536
|
+
if ha_vm_failure_interval is None and 'haVmFailureInterval' in kwargs:
|
|
537
|
+
ha_vm_failure_interval = kwargs['haVmFailureInterval']
|
|
538
|
+
if ha_vm_maximum_failure_window is None and 'haVmMaximumFailureWindow' in kwargs:
|
|
539
|
+
ha_vm_maximum_failure_window = kwargs['haVmMaximumFailureWindow']
|
|
540
|
+
if ha_vm_maximum_resets is None and 'haVmMaximumResets' in kwargs:
|
|
541
|
+
ha_vm_maximum_resets = kwargs['haVmMaximumResets']
|
|
542
|
+
if ha_vm_minimum_uptime is None and 'haVmMinimumUptime' in kwargs:
|
|
543
|
+
ha_vm_minimum_uptime = kwargs['haVmMinimumUptime']
|
|
544
|
+
if ha_vm_monitoring is None and 'haVmMonitoring' in kwargs:
|
|
545
|
+
ha_vm_monitoring = kwargs['haVmMonitoring']
|
|
546
|
+
if ha_vm_monitoring_use_cluster_defaults is None and 'haVmMonitoringUseClusterDefaults' in kwargs:
|
|
547
|
+
ha_vm_monitoring_use_cluster_defaults = kwargs['haVmMonitoringUseClusterDefaults']
|
|
548
|
+
if ha_vm_restart_priority is None and 'haVmRestartPriority' in kwargs:
|
|
549
|
+
ha_vm_restart_priority = kwargs['haVmRestartPriority']
|
|
550
|
+
if ha_vm_restart_timeout is None and 'haVmRestartTimeout' in kwargs:
|
|
551
|
+
ha_vm_restart_timeout = kwargs['haVmRestartTimeout']
|
|
552
|
+
if virtual_machine_id is None and 'virtualMachineId' in kwargs:
|
|
553
|
+
virtual_machine_id = kwargs['virtualMachineId']
|
|
554
|
+
|
|
487
555
|
if compute_cluster_id is not None:
|
|
488
556
|
_setter("compute_cluster_id", compute_cluster_id)
|
|
489
557
|
if ha_datastore_apd_recovery_action is not None:
|