pulumi-vsphere 4.10.0a1710245029__py3-none-any.whl → 4.13.0a1736836157__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 +28 -0
- pulumi_vsphere/_inputs.py +1816 -277
- pulumi_vsphere/_utilities.py +41 -5
- pulumi_vsphere/compute_cluster.py +937 -1488
- pulumi_vsphere/compute_cluster_host_group.py +67 -2
- pulumi_vsphere/compute_cluster_vm_affinity_rule.py +69 -34
- pulumi_vsphere/compute_cluster_vm_anti_affinity_rule.py +41 -2
- pulumi_vsphere/compute_cluster_vm_dependency_rule.py +205 -2
- pulumi_vsphere/compute_cluster_vm_group.py +198 -2
- pulumi_vsphere/compute_cluster_vm_host_rule.py +73 -2
- pulumi_vsphere/config/__init__.pyi +5 -0
- pulumi_vsphere/config/vars.py +5 -0
- pulumi_vsphere/content_library.py +113 -12
- pulumi_vsphere/content_library_item.py +143 -2
- pulumi_vsphere/custom_attribute.py +77 -2
- pulumi_vsphere/datacenter.py +48 -40
- pulumi_vsphere/datastore_cluster.py +217 -366
- pulumi_vsphere/datastore_cluster_vm_anti_affinity_rule.py +159 -2
- pulumi_vsphere/distributed_port_group.py +416 -189
- pulumi_vsphere/distributed_virtual_switch.py +571 -830
- pulumi_vsphere/dpm_host_override.py +63 -2
- pulumi_vsphere/drs_vm_override.py +67 -2
- pulumi_vsphere/entity_permissions.py +64 -38
- pulumi_vsphere/file.py +21 -24
- pulumi_vsphere/folder.py +148 -30
- pulumi_vsphere/get_compute_cluster.py +16 -9
- pulumi_vsphere/get_compute_cluster_host_group.py +36 -25
- pulumi_vsphere/get_content_library.py +23 -15
- pulumi_vsphere/get_content_library_item.py +29 -13
- pulumi_vsphere/get_custom_attribute.py +14 -9
- pulumi_vsphere/get_datacenter.py +30 -12
- pulumi_vsphere/get_datastore.py +29 -21
- pulumi_vsphere/get_datastore_cluster.py +31 -10
- pulumi_vsphere/get_datastore_stats.py +63 -57
- pulumi_vsphere/get_distributed_virtual_switch.py +18 -9
- pulumi_vsphere/get_dynamic.py +35 -25
- pulumi_vsphere/get_folder.py +23 -11
- pulumi_vsphere/get_guest_os_customization.py +26 -52
- pulumi_vsphere/get_host.py +16 -9
- pulumi_vsphere/get_host_base_images.py +104 -0
- pulumi_vsphere/get_host_pci_device.py +28 -19
- pulumi_vsphere/get_host_thumbprint.py +41 -25
- pulumi_vsphere/get_host_vgpu_profile.py +20 -15
- pulumi_vsphere/get_license.py +20 -10
- pulumi_vsphere/get_network.py +80 -24
- pulumi_vsphere/get_ovf_vm_template.py +56 -5
- pulumi_vsphere/get_policy.py +13 -9
- pulumi_vsphere/get_resource_pool.py +29 -23
- pulumi_vsphere/get_role.py +23 -13
- pulumi_vsphere/get_tag.py +16 -9
- pulumi_vsphere/get_tag_category.py +16 -9
- pulumi_vsphere/get_vapp_container.py +15 -9
- pulumi_vsphere/get_virtual_machine.py +205 -48
- pulumi_vsphere/get_vmfs_disks.py +18 -9
- pulumi_vsphere/guest_os_customization.py +60 -5
- pulumi_vsphere/ha_vm_override.py +352 -380
- pulumi_vsphere/host.py +244 -64
- pulumi_vsphere/host_port_group.py +27 -24
- pulumi_vsphere/host_virtual_switch.py +209 -289
- pulumi_vsphere/license.py +5 -32
- pulumi_vsphere/nas_datastore.py +74 -9
- pulumi_vsphere/offline_software_depot.py +185 -0
- pulumi_vsphere/outputs.py +717 -270
- pulumi_vsphere/provider.py +7 -6
- pulumi_vsphere/pulumi-plugin.json +2 -1
- pulumi_vsphere/resource_pool.py +168 -411
- pulumi_vsphere/role.py +33 -2
- pulumi_vsphere/storage_drs_vm_override.py +133 -2
- pulumi_vsphere/supervisor.py +967 -0
- pulumi_vsphere/tag.py +159 -2
- pulumi_vsphere/tag_category.py +83 -2
- pulumi_vsphere/vapp_container.py +163 -2
- pulumi_vsphere/vapp_entity.py +147 -2
- pulumi_vsphere/virtual_disk.py +123 -36
- pulumi_vsphere/virtual_machine.py +698 -829
- pulumi_vsphere/virtual_machine_class.py +447 -0
- pulumi_vsphere/virtual_machine_snapshot.py +13 -12
- pulumi_vsphere/vm_storage_policy.py +120 -127
- pulumi_vsphere/vmfs_datastore.py +271 -2
- pulumi_vsphere/vnic.py +104 -105
- {pulumi_vsphere-4.10.0a1710245029.dist-info → pulumi_vsphere-4.13.0a1736836157.dist-info}/METADATA +7 -6
- pulumi_vsphere-4.13.0a1736836157.dist-info/RECORD +86 -0
- {pulumi_vsphere-4.10.0a1710245029.dist-info → pulumi_vsphere-4.13.0a1736836157.dist-info}/WHEEL +1 -1
- pulumi_vsphere-4.10.0a1710245029.dist-info/RECORD +0 -82
- {pulumi_vsphere-4.10.0a1710245029.dist-info → pulumi_vsphere-4.13.0a1736836157.dist-info}/top_level.txt +0 -0
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
|
|
12
17
|
__all__ = [
|
|
@@ -106,7 +111,6 @@ def get_host_pci_device(class_id: Optional[str] = None,
|
|
|
106
111
|
|
|
107
112
|
### With Vendor ID And Class ID
|
|
108
113
|
|
|
109
|
-
<!--Start PulumiCodeChooser -->
|
|
110
114
|
```python
|
|
111
115
|
import pulumi
|
|
112
116
|
import pulumi_vsphere as vsphere
|
|
@@ -118,22 +122,19 @@ def get_host_pci_device(class_id: Optional[str] = None,
|
|
|
118
122
|
class_id="123",
|
|
119
123
|
vendor_id="456")
|
|
120
124
|
```
|
|
121
|
-
<!--End PulumiCodeChooser -->
|
|
122
125
|
|
|
123
126
|
### With Name Regular Expression
|
|
124
127
|
|
|
125
|
-
<!--Start PulumiCodeChooser -->
|
|
126
128
|
```python
|
|
127
129
|
import pulumi
|
|
128
130
|
import pulumi_vsphere as vsphere
|
|
129
131
|
|
|
130
132
|
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
131
133
|
host = vsphere.get_host(name="esxi-01.example.com",
|
|
132
|
-
|
|
134
|
+
datacenter_id=datacenter.id)
|
|
133
135
|
dev = vsphere.get_host_pci_device(host_id=host.id,
|
|
134
|
-
|
|
136
|
+
name_regex="MMC")
|
|
135
137
|
```
|
|
136
|
-
<!--End PulumiCodeChooser -->
|
|
137
138
|
|
|
138
139
|
|
|
139
140
|
:param str class_id: The hexadecimal PCI device class ID
|
|
@@ -141,7 +142,8 @@ def get_host_pci_device(class_id: Optional[str] = None,
|
|
|
141
142
|
[docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
142
143
|
|
|
143
144
|
> **NOTE:** `name_regex`, `vendor_id`, and `class_id` can all be used together.
|
|
144
|
-
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
145
|
+
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
146
|
+
a host.
|
|
145
147
|
:param str name_regex: A regular expression that will be used to match the
|
|
146
148
|
host PCI device name.
|
|
147
149
|
:param str vendor_id: The hexadecimal PCI device vendor ID.
|
|
@@ -161,14 +163,11 @@ def get_host_pci_device(class_id: Optional[str] = None,
|
|
|
161
163
|
name=pulumi.get(__ret__, 'name'),
|
|
162
164
|
name_regex=pulumi.get(__ret__, 'name_regex'),
|
|
163
165
|
vendor_id=pulumi.get(__ret__, 'vendor_id'))
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
@_utilities.lift_output_func(get_host_pci_device)
|
|
167
166
|
def get_host_pci_device_output(class_id: Optional[pulumi.Input[Optional[str]]] = None,
|
|
168
167
|
host_id: Optional[pulumi.Input[str]] = None,
|
|
169
168
|
name_regex: Optional[pulumi.Input[Optional[str]]] = None,
|
|
170
169
|
vendor_id: Optional[pulumi.Input[Optional[str]]] = None,
|
|
171
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostPciDeviceResult]:
|
|
170
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostPciDeviceResult]:
|
|
172
171
|
"""
|
|
173
172
|
The `get_host_pci_device` data source can be used to discover the device ID
|
|
174
173
|
of a vSphere host's PCI device. This can then be used with
|
|
@@ -178,7 +177,6 @@ def get_host_pci_device_output(class_id: Optional[pulumi.Input[Optional[str]]] =
|
|
|
178
177
|
|
|
179
178
|
### With Vendor ID And Class ID
|
|
180
179
|
|
|
181
|
-
<!--Start PulumiCodeChooser -->
|
|
182
180
|
```python
|
|
183
181
|
import pulumi
|
|
184
182
|
import pulumi_vsphere as vsphere
|
|
@@ -190,22 +188,19 @@ def get_host_pci_device_output(class_id: Optional[pulumi.Input[Optional[str]]] =
|
|
|
190
188
|
class_id="123",
|
|
191
189
|
vendor_id="456")
|
|
192
190
|
```
|
|
193
|
-
<!--End PulumiCodeChooser -->
|
|
194
191
|
|
|
195
192
|
### With Name Regular Expression
|
|
196
193
|
|
|
197
|
-
<!--Start PulumiCodeChooser -->
|
|
198
194
|
```python
|
|
199
195
|
import pulumi
|
|
200
196
|
import pulumi_vsphere as vsphere
|
|
201
197
|
|
|
202
198
|
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
203
199
|
host = vsphere.get_host(name="esxi-01.example.com",
|
|
204
|
-
|
|
200
|
+
datacenter_id=datacenter.id)
|
|
205
201
|
dev = vsphere.get_host_pci_device(host_id=host.id,
|
|
206
|
-
|
|
202
|
+
name_regex="MMC")
|
|
207
203
|
```
|
|
208
|
-
<!--End PulumiCodeChooser -->
|
|
209
204
|
|
|
210
205
|
|
|
211
206
|
:param str class_id: The hexadecimal PCI device class ID
|
|
@@ -213,9 +208,23 @@ def get_host_pci_device_output(class_id: Optional[pulumi.Input[Optional[str]]] =
|
|
|
213
208
|
[docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
214
209
|
|
|
215
210
|
> **NOTE:** `name_regex`, `vendor_id`, and `class_id` can all be used together.
|
|
216
|
-
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
211
|
+
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
212
|
+
a host.
|
|
217
213
|
:param str name_regex: A regular expression that will be used to match the
|
|
218
214
|
host PCI device name.
|
|
219
215
|
:param str vendor_id: The hexadecimal PCI device vendor ID.
|
|
220
216
|
"""
|
|
221
|
-
|
|
217
|
+
__args__ = dict()
|
|
218
|
+
__args__['classId'] = class_id
|
|
219
|
+
__args__['hostId'] = host_id
|
|
220
|
+
__args__['nameRegex'] = name_regex
|
|
221
|
+
__args__['vendorId'] = vendor_id
|
|
222
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
223
|
+
__ret__ = pulumi.runtime.invoke_output('vsphere:index/getHostPciDevice:getHostPciDevice', __args__, opts=opts, typ=GetHostPciDeviceResult)
|
|
224
|
+
return __ret__.apply(lambda __response__: GetHostPciDeviceResult(
|
|
225
|
+
class_id=pulumi.get(__response__, 'class_id'),
|
|
226
|
+
host_id=pulumi.get(__response__, 'host_id'),
|
|
227
|
+
id=pulumi.get(__response__, 'id'),
|
|
228
|
+
name=pulumi.get(__response__, 'name'),
|
|
229
|
+
name_regex=pulumi.get(__response__, 'name_regex'),
|
|
230
|
+
vendor_id=pulumi.get(__response__, 'vendor_id')))
|
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
|
|
12
17
|
__all__ = [
|
|
@@ -76,27 +81,29 @@ def get_host_thumbprint(address: Optional[str] = None,
|
|
|
76
81
|
port: Optional[str] = None,
|
|
77
82
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetHostThumbprintResult:
|
|
78
83
|
"""
|
|
79
|
-
The `vsphere_thumbprint` data source can be used to discover the host
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
84
|
+
The `vsphere_thumbprint` data source can be used to discover the host thumbprint
|
|
85
|
+
of an ESXi host. This can be used when adding the `Host` resource to a
|
|
86
|
+
cluster or a vCenter Server instance.
|
|
87
|
+
|
|
88
|
+
* If the ESXi host is using a certificate chain, the first one returned will be
|
|
89
|
+
used to generate the thumbprint.
|
|
90
|
+
|
|
91
|
+
* If the ESXi host has a certificate issued by a certificate authority, ensure
|
|
92
|
+
that the the certificate authority is trusted on the system running the plan.
|
|
83
93
|
|
|
84
94
|
## Example Usage
|
|
85
95
|
|
|
86
|
-
<!--Start PulumiCodeChooser -->
|
|
87
96
|
```python
|
|
88
97
|
import pulumi
|
|
89
98
|
import pulumi_vsphere as vsphere
|
|
90
99
|
|
|
91
100
|
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com")
|
|
92
101
|
```
|
|
93
|
-
<!--End PulumiCodeChooser -->
|
|
94
102
|
|
|
95
103
|
|
|
96
|
-
:param str address: The address of the ESXi host to retrieve the
|
|
97
|
-
|
|
98
|
-
:param bool insecure: Disables SSL certificate verification.
|
|
99
|
-
Default: `false`
|
|
104
|
+
:param str address: The address of the ESXi host to retrieve the thumbprint
|
|
105
|
+
from.
|
|
106
|
+
:param bool insecure: Disables SSL certificate verification. Default: `false`
|
|
100
107
|
:param str port: The port to use connecting to the ESXi host. Default: 443
|
|
101
108
|
"""
|
|
102
109
|
__args__ = dict()
|
|
@@ -111,35 +118,44 @@ def get_host_thumbprint(address: Optional[str] = None,
|
|
|
111
118
|
id=pulumi.get(__ret__, 'id'),
|
|
112
119
|
insecure=pulumi.get(__ret__, 'insecure'),
|
|
113
120
|
port=pulumi.get(__ret__, 'port'))
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
@_utilities.lift_output_func(get_host_thumbprint)
|
|
117
121
|
def get_host_thumbprint_output(address: Optional[pulumi.Input[str]] = None,
|
|
118
122
|
insecure: Optional[pulumi.Input[Optional[bool]]] = None,
|
|
119
123
|
port: Optional[pulumi.Input[Optional[str]]] = None,
|
|
120
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostThumbprintResult]:
|
|
124
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostThumbprintResult]:
|
|
121
125
|
"""
|
|
122
|
-
The `vsphere_thumbprint` data source can be used to discover the host
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
+
The `vsphere_thumbprint` data source can be used to discover the host thumbprint
|
|
127
|
+
of an ESXi host. This can be used when adding the `Host` resource to a
|
|
128
|
+
cluster or a vCenter Server instance.
|
|
129
|
+
|
|
130
|
+
* If the ESXi host is using a certificate chain, the first one returned will be
|
|
131
|
+
used to generate the thumbprint.
|
|
132
|
+
|
|
133
|
+
* If the ESXi host has a certificate issued by a certificate authority, ensure
|
|
134
|
+
that the the certificate authority is trusted on the system running the plan.
|
|
126
135
|
|
|
127
136
|
## Example Usage
|
|
128
137
|
|
|
129
|
-
<!--Start PulumiCodeChooser -->
|
|
130
138
|
```python
|
|
131
139
|
import pulumi
|
|
132
140
|
import pulumi_vsphere as vsphere
|
|
133
141
|
|
|
134
142
|
thumbprint = vsphere.get_host_thumbprint(address="esxi-01.example.com")
|
|
135
143
|
```
|
|
136
|
-
<!--End PulumiCodeChooser -->
|
|
137
144
|
|
|
138
145
|
|
|
139
|
-
:param str address: The address of the ESXi host to retrieve the
|
|
140
|
-
|
|
141
|
-
:param bool insecure: Disables SSL certificate verification.
|
|
142
|
-
Default: `false`
|
|
146
|
+
:param str address: The address of the ESXi host to retrieve the thumbprint
|
|
147
|
+
from.
|
|
148
|
+
:param bool insecure: Disables SSL certificate verification. Default: `false`
|
|
143
149
|
:param str port: The port to use connecting to the ESXi host. Default: 443
|
|
144
150
|
"""
|
|
145
|
-
|
|
151
|
+
__args__ = dict()
|
|
152
|
+
__args__['address'] = address
|
|
153
|
+
__args__['insecure'] = insecure
|
|
154
|
+
__args__['port'] = port
|
|
155
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
156
|
+
__ret__ = pulumi.runtime.invoke_output('vsphere:index/getHostThumbprint:getHostThumbprint', __args__, opts=opts, typ=GetHostThumbprintResult)
|
|
157
|
+
return __ret__.apply(lambda __response__: GetHostThumbprintResult(
|
|
158
|
+
address=pulumi.get(__response__, 'address'),
|
|
159
|
+
id=pulumi.get(__response__, 'id'),
|
|
160
|
+
insecure=pulumi.get(__response__, 'insecure'),
|
|
161
|
+
port=pulumi.get(__response__, 'port')))
|
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
from . import outputs
|
|
12
17
|
|
|
@@ -94,7 +99,6 @@ def get_host_vgpu_profile(host_id: Optional[str] = None,
|
|
|
94
99
|
|
|
95
100
|
### To Return All VGPU Profiles
|
|
96
101
|
|
|
97
|
-
<!--Start PulumiCodeChooser -->
|
|
98
102
|
```python
|
|
99
103
|
import pulumi
|
|
100
104
|
import pulumi_vsphere as vsphere
|
|
@@ -104,11 +108,9 @@ def get_host_vgpu_profile(host_id: Optional[str] = None,
|
|
|
104
108
|
datacenter_id=datacenter.id)
|
|
105
109
|
vgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id)
|
|
106
110
|
```
|
|
107
|
-
<!--End PulumiCodeChooser -->
|
|
108
111
|
|
|
109
112
|
### With VGPU Profile Name_regex
|
|
110
113
|
|
|
111
|
-
<!--Start PulumiCodeChooser -->
|
|
112
114
|
```python
|
|
113
115
|
import pulumi
|
|
114
116
|
import pulumi_vsphere as vsphere
|
|
@@ -119,10 +121,10 @@ def get_host_vgpu_profile(host_id: Optional[str] = None,
|
|
|
119
121
|
vgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id,
|
|
120
122
|
name_regex="a100")
|
|
121
123
|
```
|
|
122
|
-
<!--End PulumiCodeChooser -->
|
|
123
124
|
|
|
124
125
|
|
|
125
|
-
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
126
|
+
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
127
|
+
a host.
|
|
126
128
|
:param str name_regex: A regular expression that will be used to match the
|
|
127
129
|
host vGPU profile name.
|
|
128
130
|
|
|
@@ -139,12 +141,9 @@ def get_host_vgpu_profile(host_id: Optional[str] = None,
|
|
|
139
141
|
id=pulumi.get(__ret__, 'id'),
|
|
140
142
|
name_regex=pulumi.get(__ret__, 'name_regex'),
|
|
141
143
|
vgpu_profiles=pulumi.get(__ret__, 'vgpu_profiles'))
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
@_utilities.lift_output_func(get_host_vgpu_profile)
|
|
145
144
|
def get_host_vgpu_profile_output(host_id: Optional[pulumi.Input[str]] = None,
|
|
146
145
|
name_regex: Optional[pulumi.Input[Optional[str]]] = None,
|
|
147
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostVgpuProfileResult]:
|
|
146
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostVgpuProfileResult]:
|
|
148
147
|
"""
|
|
149
148
|
The `get_host_vgpu_profile` data source can be used to discover the
|
|
150
149
|
available vGPU profiles of a vSphere host.
|
|
@@ -153,7 +152,6 @@ def get_host_vgpu_profile_output(host_id: Optional[pulumi.Input[str]] = None,
|
|
|
153
152
|
|
|
154
153
|
### To Return All VGPU Profiles
|
|
155
154
|
|
|
156
|
-
<!--Start PulumiCodeChooser -->
|
|
157
155
|
```python
|
|
158
156
|
import pulumi
|
|
159
157
|
import pulumi_vsphere as vsphere
|
|
@@ -163,11 +161,9 @@ def get_host_vgpu_profile_output(host_id: Optional[pulumi.Input[str]] = None,
|
|
|
163
161
|
datacenter_id=datacenter.id)
|
|
164
162
|
vgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id)
|
|
165
163
|
```
|
|
166
|
-
<!--End PulumiCodeChooser -->
|
|
167
164
|
|
|
168
165
|
### With VGPU Profile Name_regex
|
|
169
166
|
|
|
170
|
-
<!--Start PulumiCodeChooser -->
|
|
171
167
|
```python
|
|
172
168
|
import pulumi
|
|
173
169
|
import pulumi_vsphere as vsphere
|
|
@@ -178,13 +174,22 @@ def get_host_vgpu_profile_output(host_id: Optional[pulumi.Input[str]] = None,
|
|
|
178
174
|
vgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id,
|
|
179
175
|
name_regex="a100")
|
|
180
176
|
```
|
|
181
|
-
<!--End PulumiCodeChooser -->
|
|
182
177
|
|
|
183
178
|
|
|
184
|
-
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
179
|
+
:param str host_id: The [managed object reference ID][docs-about-morefs] of
|
|
180
|
+
a host.
|
|
185
181
|
:param str name_regex: A regular expression that will be used to match the
|
|
186
182
|
host vGPU profile name.
|
|
187
183
|
|
|
188
184
|
[docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
189
185
|
"""
|
|
190
|
-
|
|
186
|
+
__args__ = dict()
|
|
187
|
+
__args__['hostId'] = host_id
|
|
188
|
+
__args__['nameRegex'] = name_regex
|
|
189
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
190
|
+
__ret__ = pulumi.runtime.invoke_output('vsphere:index/getHostVgpuProfile:getHostVgpuProfile', __args__, opts=opts, typ=GetHostVgpuProfileResult)
|
|
191
|
+
return __ret__.apply(lambda __response__: GetHostVgpuProfileResult(
|
|
192
|
+
host_id=pulumi.get(__response__, 'host_id'),
|
|
193
|
+
id=pulumi.get(__response__, 'id'),
|
|
194
|
+
name_regex=pulumi.get(__response__, 'name_regex'),
|
|
195
|
+
vgpu_profiles=pulumi.get(__response__, 'vgpu_profiles')))
|
pulumi_vsphere/get_license.py
CHANGED
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
|
|
12
17
|
__all__ = [
|
|
@@ -61,7 +66,8 @@ class GetLicenseResult:
|
|
|
61
66
|
@pulumi.getter
|
|
62
67
|
def labels(self) -> Mapping[str, str]:
|
|
63
68
|
"""
|
|
64
|
-
A map of key/value pairs attached as labels (tags) to the license
|
|
69
|
+
A map of key/value pairs attached as labels (tags) to the license
|
|
70
|
+
key.
|
|
65
71
|
"""
|
|
66
72
|
return pulumi.get(self, "labels")
|
|
67
73
|
|
|
@@ -118,14 +124,12 @@ def get_license(license_key: Optional[str] = None,
|
|
|
118
124
|
|
|
119
125
|
## Example Usage
|
|
120
126
|
|
|
121
|
-
<!--Start PulumiCodeChooser -->
|
|
122
127
|
```python
|
|
123
128
|
import pulumi
|
|
124
129
|
import pulumi_vsphere as vsphere
|
|
125
130
|
|
|
126
131
|
license = vsphere.get_license(license_key="00000-00000-00000-00000-00000")
|
|
127
132
|
```
|
|
128
|
-
<!--End PulumiCodeChooser -->
|
|
129
133
|
|
|
130
134
|
|
|
131
135
|
:param str license_key: The license key.
|
|
@@ -143,27 +147,33 @@ def get_license(license_key: Optional[str] = None,
|
|
|
143
147
|
name=pulumi.get(__ret__, 'name'),
|
|
144
148
|
total=pulumi.get(__ret__, 'total'),
|
|
145
149
|
used=pulumi.get(__ret__, 'used'))
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
@_utilities.lift_output_func(get_license)
|
|
149
150
|
def get_license_output(license_key: Optional[pulumi.Input[str]] = None,
|
|
150
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetLicenseResult]:
|
|
151
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetLicenseResult]:
|
|
151
152
|
"""
|
|
152
153
|
The `License` data source can be used to get the general attributes of
|
|
153
154
|
a license keys from a vCenter Server instance.
|
|
154
155
|
|
|
155
156
|
## Example Usage
|
|
156
157
|
|
|
157
|
-
<!--Start PulumiCodeChooser -->
|
|
158
158
|
```python
|
|
159
159
|
import pulumi
|
|
160
160
|
import pulumi_vsphere as vsphere
|
|
161
161
|
|
|
162
162
|
license = vsphere.get_license(license_key="00000-00000-00000-00000-00000")
|
|
163
163
|
```
|
|
164
|
-
<!--End PulumiCodeChooser -->
|
|
165
164
|
|
|
166
165
|
|
|
167
166
|
:param str license_key: The license key.
|
|
168
167
|
"""
|
|
169
|
-
|
|
168
|
+
__args__ = dict()
|
|
169
|
+
__args__['licenseKey'] = license_key
|
|
170
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
171
|
+
__ret__ = pulumi.runtime.invoke_output('vsphere:index/getLicense:getLicense', __args__, opts=opts, typ=GetLicenseResult)
|
|
172
|
+
return __ret__.apply(lambda __response__: GetLicenseResult(
|
|
173
|
+
edition_key=pulumi.get(__response__, 'edition_key'),
|
|
174
|
+
id=pulumi.get(__response__, 'id'),
|
|
175
|
+
labels=pulumi.get(__response__, 'labels'),
|
|
176
|
+
license_key=pulumi.get(__response__, 'license_key'),
|
|
177
|
+
name=pulumi.get(__response__, 'name'),
|
|
178
|
+
total=pulumi.get(__response__, 'total'),
|
|
179
|
+
used=pulumi.get(__response__, 'used')))
|
pulumi_vsphere/get_network.py
CHANGED
|
@@ -4,10 +4,17 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
16
|
+
from . import outputs
|
|
17
|
+
from ._inputs import *
|
|
11
18
|
|
|
12
19
|
__all__ = [
|
|
13
20
|
'GetNetworkResult',
|
|
@@ -21,13 +28,16 @@ class GetNetworkResult:
|
|
|
21
28
|
"""
|
|
22
29
|
A collection of values returned by getNetwork.
|
|
23
30
|
"""
|
|
24
|
-
def __init__(__self__, datacenter_id=None, distributed_virtual_switch_uuid=None, id=None, name=None, type=None):
|
|
31
|
+
def __init__(__self__, datacenter_id=None, distributed_virtual_switch_uuid=None, filters=None, id=None, name=None, type=None):
|
|
25
32
|
if datacenter_id and not isinstance(datacenter_id, str):
|
|
26
33
|
raise TypeError("Expected argument 'datacenter_id' to be a str")
|
|
27
34
|
pulumi.set(__self__, "datacenter_id", datacenter_id)
|
|
28
35
|
if distributed_virtual_switch_uuid and not isinstance(distributed_virtual_switch_uuid, str):
|
|
29
36
|
raise TypeError("Expected argument 'distributed_virtual_switch_uuid' to be a str")
|
|
30
37
|
pulumi.set(__self__, "distributed_virtual_switch_uuid", distributed_virtual_switch_uuid)
|
|
38
|
+
if filters and not isinstance(filters, list):
|
|
39
|
+
raise TypeError("Expected argument 'filters' to be a list")
|
|
40
|
+
pulumi.set(__self__, "filters", filters)
|
|
31
41
|
if id and not isinstance(id, str):
|
|
32
42
|
raise TypeError("Expected argument 'id' to be a str")
|
|
33
43
|
pulumi.set(__self__, "id", id)
|
|
@@ -48,6 +58,11 @@ class GetNetworkResult:
|
|
|
48
58
|
def distributed_virtual_switch_uuid(self) -> Optional[str]:
|
|
49
59
|
return pulumi.get(self, "distributed_virtual_switch_uuid")
|
|
50
60
|
|
|
61
|
+
@property
|
|
62
|
+
@pulumi.getter
|
|
63
|
+
def filters(self) -> Optional[Sequence['outputs.GetNetworkFilterResult']]:
|
|
64
|
+
return pulumi.get(self, "filters")
|
|
65
|
+
|
|
51
66
|
@property
|
|
52
67
|
@pulumi.getter
|
|
53
68
|
def id(self) -> str:
|
|
@@ -81,6 +96,7 @@ class AwaitableGetNetworkResult(GetNetworkResult):
|
|
|
81
96
|
return GetNetworkResult(
|
|
82
97
|
datacenter_id=self.datacenter_id,
|
|
83
98
|
distributed_virtual_switch_uuid=self.distributed_virtual_switch_uuid,
|
|
99
|
+
filters=self.filters,
|
|
84
100
|
id=self.id,
|
|
85
101
|
name=self.name,
|
|
86
102
|
type=self.type)
|
|
@@ -88,18 +104,18 @@ class AwaitableGetNetworkResult(GetNetworkResult):
|
|
|
88
104
|
|
|
89
105
|
def get_network(datacenter_id: Optional[str] = None,
|
|
90
106
|
distributed_virtual_switch_uuid: Optional[str] = None,
|
|
107
|
+
filters: Optional[Sequence[Union['GetNetworkFilterArgs', 'GetNetworkFilterArgsDict']]] = None,
|
|
91
108
|
name: Optional[str] = None,
|
|
92
109
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetNetworkResult:
|
|
93
110
|
"""
|
|
94
|
-
The `get_network` data source can be used to discover the ID of a network
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
111
|
+
The `get_network` data source can be used to discover the ID of a network in
|
|
112
|
+
vSphere. This can be any network that can be used as the backing for a network
|
|
113
|
+
interface for `VirtualMachine` or any other vSphere resource that
|
|
114
|
+
requires a network. This includes standard (host-based) port groups, distributed
|
|
115
|
+
port groups, or opaque networks such as those managed by NSX.
|
|
99
116
|
|
|
100
117
|
## Example Usage
|
|
101
118
|
|
|
102
|
-
<!--Start PulumiCodeChooser -->
|
|
103
119
|
```python
|
|
104
120
|
import pulumi
|
|
105
121
|
import pulumi_vsphere as vsphere
|
|
@@ -108,7 +124,20 @@ def get_network(datacenter_id: Optional[str] = None,
|
|
|
108
124
|
network = vsphere.get_network(name="VM Network",
|
|
109
125
|
datacenter_id=datacenter.id)
|
|
110
126
|
```
|
|
111
|
-
|
|
127
|
+
|
|
128
|
+
### Additional Examples
|
|
129
|
+
|
|
130
|
+
```python
|
|
131
|
+
import pulumi
|
|
132
|
+
import pulumi_vsphere as vsphere
|
|
133
|
+
|
|
134
|
+
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
135
|
+
my_port_group = vsphere.get_network(datacenter_id=datacenter.id,
|
|
136
|
+
name="VM Network",
|
|
137
|
+
filters=[{
|
|
138
|
+
"network_type": "Network",
|
|
139
|
+
}])
|
|
140
|
+
```
|
|
112
141
|
|
|
113
142
|
|
|
114
143
|
:param str datacenter_id: The managed object reference ID
|
|
@@ -117,13 +146,15 @@ def get_network(datacenter_id: Optional[str] = None,
|
|
|
117
146
|
use the `id` attribute from an empty `Datacenter` data source.
|
|
118
147
|
:param str distributed_virtual_switch_uuid: For distributed port group type
|
|
119
148
|
network objects, the ID of the distributed virtual switch for which the port
|
|
120
|
-
group belongs. It is useful to differentiate port groups with same name
|
|
121
|
-
|
|
149
|
+
group belongs. It is useful to differentiate port groups with same name using
|
|
150
|
+
the distributed virtual switch ID.
|
|
151
|
+
:param Sequence[Union['GetNetworkFilterArgs', 'GetNetworkFilterArgsDict']] filters: Apply a filter for the discovered network.
|
|
122
152
|
:param str name: The name of the network. This can be a name or path.
|
|
123
153
|
"""
|
|
124
154
|
__args__ = dict()
|
|
125
155
|
__args__['datacenterId'] = datacenter_id
|
|
126
156
|
__args__['distributedVirtualSwitchUuid'] = distributed_virtual_switch_uuid
|
|
157
|
+
__args__['filters'] = filters
|
|
127
158
|
__args__['name'] = name
|
|
128
159
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
129
160
|
__ret__ = pulumi.runtime.invoke('vsphere:index/getNetwork:getNetwork', __args__, opts=opts, typ=GetNetworkResult).value
|
|
@@ -131,26 +162,24 @@ def get_network(datacenter_id: Optional[str] = None,
|
|
|
131
162
|
return AwaitableGetNetworkResult(
|
|
132
163
|
datacenter_id=pulumi.get(__ret__, 'datacenter_id'),
|
|
133
164
|
distributed_virtual_switch_uuid=pulumi.get(__ret__, 'distributed_virtual_switch_uuid'),
|
|
165
|
+
filters=pulumi.get(__ret__, 'filters'),
|
|
134
166
|
id=pulumi.get(__ret__, 'id'),
|
|
135
167
|
name=pulumi.get(__ret__, 'name'),
|
|
136
168
|
type=pulumi.get(__ret__, 'type'))
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
@_utilities.lift_output_func(get_network)
|
|
140
169
|
def get_network_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = None,
|
|
141
170
|
distributed_virtual_switch_uuid: Optional[pulumi.Input[Optional[str]]] = None,
|
|
171
|
+
filters: Optional[pulumi.Input[Optional[Sequence[Union['GetNetworkFilterArgs', 'GetNetworkFilterArgsDict']]]]] = None,
|
|
142
172
|
name: Optional[pulumi.Input[str]] = None,
|
|
143
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetNetworkResult]:
|
|
173
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetNetworkResult]:
|
|
144
174
|
"""
|
|
145
|
-
The `get_network` data source can be used to discover the ID of a network
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
175
|
+
The `get_network` data source can be used to discover the ID of a network in
|
|
176
|
+
vSphere. This can be any network that can be used as the backing for a network
|
|
177
|
+
interface for `VirtualMachine` or any other vSphere resource that
|
|
178
|
+
requires a network. This includes standard (host-based) port groups, distributed
|
|
179
|
+
port groups, or opaque networks such as those managed by NSX.
|
|
150
180
|
|
|
151
181
|
## Example Usage
|
|
152
182
|
|
|
153
|
-
<!--Start PulumiCodeChooser -->
|
|
154
183
|
```python
|
|
155
184
|
import pulumi
|
|
156
185
|
import pulumi_vsphere as vsphere
|
|
@@ -159,7 +188,20 @@ def get_network_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = No
|
|
|
159
188
|
network = vsphere.get_network(name="VM Network",
|
|
160
189
|
datacenter_id=datacenter.id)
|
|
161
190
|
```
|
|
162
|
-
|
|
191
|
+
|
|
192
|
+
### Additional Examples
|
|
193
|
+
|
|
194
|
+
```python
|
|
195
|
+
import pulumi
|
|
196
|
+
import pulumi_vsphere as vsphere
|
|
197
|
+
|
|
198
|
+
datacenter = vsphere.get_datacenter(name="dc-01")
|
|
199
|
+
my_port_group = vsphere.get_network(datacenter_id=datacenter.id,
|
|
200
|
+
name="VM Network",
|
|
201
|
+
filters=[{
|
|
202
|
+
"network_type": "Network",
|
|
203
|
+
}])
|
|
204
|
+
```
|
|
163
205
|
|
|
164
206
|
|
|
165
207
|
:param str datacenter_id: The managed object reference ID
|
|
@@ -168,8 +210,22 @@ def get_network_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = No
|
|
|
168
210
|
use the `id` attribute from an empty `Datacenter` data source.
|
|
169
211
|
:param str distributed_virtual_switch_uuid: For distributed port group type
|
|
170
212
|
network objects, the ID of the distributed virtual switch for which the port
|
|
171
|
-
group belongs. It is useful to differentiate port groups with same name
|
|
172
|
-
|
|
213
|
+
group belongs. It is useful to differentiate port groups with same name using
|
|
214
|
+
the distributed virtual switch ID.
|
|
215
|
+
:param Sequence[Union['GetNetworkFilterArgs', 'GetNetworkFilterArgsDict']] filters: Apply a filter for the discovered network.
|
|
173
216
|
:param str name: The name of the network. This can be a name or path.
|
|
174
217
|
"""
|
|
175
|
-
|
|
218
|
+
__args__ = dict()
|
|
219
|
+
__args__['datacenterId'] = datacenter_id
|
|
220
|
+
__args__['distributedVirtualSwitchUuid'] = distributed_virtual_switch_uuid
|
|
221
|
+
__args__['filters'] = filters
|
|
222
|
+
__args__['name'] = name
|
|
223
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
224
|
+
__ret__ = pulumi.runtime.invoke_output('vsphere:index/getNetwork:getNetwork', __args__, opts=opts, typ=GetNetworkResult)
|
|
225
|
+
return __ret__.apply(lambda __response__: GetNetworkResult(
|
|
226
|
+
datacenter_id=pulumi.get(__response__, 'datacenter_id'),
|
|
227
|
+
distributed_virtual_switch_uuid=pulumi.get(__response__, 'distributed_virtual_switch_uuid'),
|
|
228
|
+
filters=pulumi.get(__response__, 'filters'),
|
|
229
|
+
id=pulumi.get(__response__, 'id'),
|
|
230
|
+
name=pulumi.get(__response__, 'name'),
|
|
231
|
+
type=pulumi.get(__response__, 'type')))
|