pulumi-vsphere 4.11.0a1__py3-none-any.whl → 4.11.0a1711033215__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.

Files changed (58) hide show
  1. pulumi_vsphere/__init__.py +0 -28
  2. pulumi_vsphere/_inputs.py +230 -554
  3. pulumi_vsphere/compute_cluster.py +1477 -747
  4. pulumi_vsphere/compute_cluster_vm_affinity_rule.py +16 -28
  5. pulumi_vsphere/datacenter.py +12 -26
  6. pulumi_vsphere/datastore_cluster.py +350 -154
  7. pulumi_vsphere/distributed_port_group.py +175 -70
  8. pulumi_vsphere/distributed_virtual_switch.py +805 -308
  9. pulumi_vsphere/file.py +24 -16
  10. pulumi_vsphere/folder.py +7 -7
  11. pulumi_vsphere/get_compute_cluster.py +4 -0
  12. pulumi_vsphere/get_compute_cluster_host_group.py +10 -8
  13. pulumi_vsphere/get_content_library.py +4 -0
  14. pulumi_vsphere/get_custom_attribute.py +4 -0
  15. pulumi_vsphere/get_datacenter.py +4 -0
  16. pulumi_vsphere/get_datastore.py +4 -0
  17. pulumi_vsphere/get_datastore_cluster.py +4 -0
  18. pulumi_vsphere/get_datastore_stats.py +12 -4
  19. pulumi_vsphere/get_distributed_virtual_switch.py +4 -2
  20. pulumi_vsphere/get_dynamic.py +8 -4
  21. pulumi_vsphere/get_folder.py +6 -10
  22. pulumi_vsphere/get_guest_os_customization.py +4 -0
  23. pulumi_vsphere/get_host.py +4 -0
  24. pulumi_vsphere/get_host_pci_device.py +12 -4
  25. pulumi_vsphere/get_host_thumbprint.py +4 -0
  26. pulumi_vsphere/get_host_vgpu_profile.py +8 -0
  27. pulumi_vsphere/get_license.py +4 -0
  28. pulumi_vsphere/get_network.py +4 -0
  29. pulumi_vsphere/get_policy.py +4 -0
  30. pulumi_vsphere/get_resource_pool.py +10 -2
  31. pulumi_vsphere/get_role.py +4 -0
  32. pulumi_vsphere/get_tag.py +4 -0
  33. pulumi_vsphere/get_tag_category.py +4 -0
  34. pulumi_vsphere/get_vapp_container.py +4 -0
  35. pulumi_vsphere/get_virtual_machine.py +8 -0
  36. pulumi_vsphere/get_vmfs_disks.py +4 -0
  37. pulumi_vsphere/guest_os_customization.py +0 -50
  38. pulumi_vsphere/ha_vm_override.py +378 -189
  39. pulumi_vsphere/host.py +20 -0
  40. pulumi_vsphere/host_port_group.py +24 -12
  41. pulumi_vsphere/host_virtual_switch.py +287 -140
  42. pulumi_vsphere/license.py +32 -0
  43. pulumi_vsphere/outputs.py +230 -543
  44. pulumi_vsphere/pulumi-plugin.json +1 -2
  45. pulumi_vsphere/resource_pool.py +22 -48
  46. pulumi_vsphere/virtual_machine.py +807 -578
  47. pulumi_vsphere/virtual_machine_snapshot.py +10 -6
  48. pulumi_vsphere/vm_storage_policy.py +84 -72
  49. pulumi_vsphere/vnic.py +20 -8
  50. {pulumi_vsphere-4.11.0a1.dist-info → pulumi_vsphere-4.11.0a1711033215.dist-info}/METADATA +1 -1
  51. pulumi_vsphere-4.11.0a1711033215.dist-info/RECORD +82 -0
  52. pulumi_vsphere/get_host_base_images.py +0 -97
  53. pulumi_vsphere/offline_software_depot.py +0 -180
  54. pulumi_vsphere/supervisor.py +0 -858
  55. pulumi_vsphere/virtual_machine_class.py +0 -440
  56. pulumi_vsphere-4.11.0a1.dist-info/RECORD +0 -86
  57. {pulumi_vsphere-4.11.0a1.dist-info → pulumi_vsphere-4.11.0a1711033215.dist-info}/WHEEL +0 -0
  58. {pulumi_vsphere-4.11.0a1.dist-info → pulumi_vsphere-4.11.0a1711033215.dist-info}/top_level.txt +0 -0
pulumi_vsphere/file.py CHANGED
@@ -298,33 +298,37 @@ class File(pulumi.CustomResource):
298
298
 
299
299
  ### Uploading a File
300
300
 
301
+ <!--Start PulumiCodeChooser -->
301
302
  ```python
302
303
  import pulumi
303
304
  import pulumi_vsphere as vsphere
304
305
 
305
- ubuntu_vmdk_upload = vsphere.File("ubuntu_vmdk_upload",
306
+ ubuntu_vmdk_upload = vsphere.File("ubuntuVmdkUpload",
307
+ create_directories=True,
306
308
  datacenter="dc-01",
307
309
  datastore="datastore-01",
308
- source_file="/my/src/path/custom_ubuntu.vmdk",
309
310
  destination_file="/my/dst/path/custom_ubuntu.vmdk",
310
- create_directories=True)
311
+ source_file="/my/src/path/custom_ubuntu.vmdk")
311
312
  ```
313
+ <!--End PulumiCodeChooser -->
312
314
 
313
315
  ### Copying a File
314
316
 
317
+ <!--Start PulumiCodeChooser -->
315
318
  ```python
316
319
  import pulumi
317
320
  import pulumi_vsphere as vsphere
318
321
 
319
- ubuntu_copy = vsphere.File("ubuntu_copy",
320
- source_datacenter="dc-01",
322
+ ubuntu_copy = vsphere.File("ubuntuCopy",
323
+ create_directories=True,
321
324
  datacenter="dc-01",
322
- source_datastore="datastore-01",
323
325
  datastore="datastore-01",
324
- source_file="/my/src/path/custom_ubuntu.vmdk",
325
326
  destination_file="/my/dst/path/custom_ubuntu.vmdk",
326
- create_directories=True)
327
+ source_datacenter="dc-01",
328
+ source_datastore="datastore-01",
329
+ source_file="/my/src/path/custom_ubuntu.vmdk")
327
330
  ```
331
+ <!--End PulumiCodeChooser -->
328
332
 
329
333
  :param str resource_name: The name of the resource.
330
334
  :param pulumi.ResourceOptions opts: Options for the resource.
@@ -356,33 +360,37 @@ class File(pulumi.CustomResource):
356
360
 
357
361
  ### Uploading a File
358
362
 
363
+ <!--Start PulumiCodeChooser -->
359
364
  ```python
360
365
  import pulumi
361
366
  import pulumi_vsphere as vsphere
362
367
 
363
- ubuntu_vmdk_upload = vsphere.File("ubuntu_vmdk_upload",
368
+ ubuntu_vmdk_upload = vsphere.File("ubuntuVmdkUpload",
369
+ create_directories=True,
364
370
  datacenter="dc-01",
365
371
  datastore="datastore-01",
366
- source_file="/my/src/path/custom_ubuntu.vmdk",
367
372
  destination_file="/my/dst/path/custom_ubuntu.vmdk",
368
- create_directories=True)
373
+ source_file="/my/src/path/custom_ubuntu.vmdk")
369
374
  ```
375
+ <!--End PulumiCodeChooser -->
370
376
 
371
377
  ### Copying a File
372
378
 
379
+ <!--Start PulumiCodeChooser -->
373
380
  ```python
374
381
  import pulumi
375
382
  import pulumi_vsphere as vsphere
376
383
 
377
- ubuntu_copy = vsphere.File("ubuntu_copy",
378
- source_datacenter="dc-01",
384
+ ubuntu_copy = vsphere.File("ubuntuCopy",
385
+ create_directories=True,
379
386
  datacenter="dc-01",
380
- source_datastore="datastore-01",
381
387
  datastore="datastore-01",
382
- source_file="/my/src/path/custom_ubuntu.vmdk",
383
388
  destination_file="/my/dst/path/custom_ubuntu.vmdk",
384
- create_directories=True)
389
+ source_datacenter="dc-01",
390
+ source_datastore="datastore-01",
391
+ source_file="/my/src/path/custom_ubuntu.vmdk")
385
392
  ```
393
+ <!--End PulumiCodeChooser -->
386
394
 
387
395
  :param str resource_name: The name of the resource.
388
396
  :param FileArgs args: The arguments to use to populate this resource's properties.
pulumi_vsphere/folder.py CHANGED
@@ -36,7 +36,7 @@ class FolderArgs:
36
36
  `datacenter` for datacenter folders, `host` for host and cluster folders,
37
37
  `vm` for virtual machine folders, `datastore` for datastore folders, and
38
38
  `network` for network folders. Forces a new resource if changed.
39
- :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
39
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
40
40
  value strings to set for folder. See [here][docs-setting-custom-attributes]
41
41
  for a reference on how to set values for custom attributes.
42
42
 
@@ -102,7 +102,7 @@ class FolderArgs:
102
102
  @pulumi.getter(name="customAttributes")
103
103
  def custom_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
104
104
  """
105
- Map of custom attribute ids to attribute
105
+ Map of custom attribute ids to attribute
106
106
  value strings to set for folder. See [here][docs-setting-custom-attributes]
107
107
  for a reference on how to set values for custom attributes.
108
108
 
@@ -157,7 +157,7 @@ class _FolderState:
157
157
  type: Optional[pulumi.Input[str]] = None):
158
158
  """
159
159
  Input properties used for looking up and filtering Folder resources.
160
- :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
160
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
161
161
  value strings to set for folder. See [here][docs-setting-custom-attributes]
162
162
  for a reference on how to set values for custom attributes.
163
163
 
@@ -203,7 +203,7 @@ class _FolderState:
203
203
  @pulumi.getter(name="customAttributes")
204
204
  def custom_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
205
205
  """
206
- Map of custom attribute ids to attribute
206
+ Map of custom attribute ids to attribute
207
207
  value strings to set for folder. See [here][docs-setting-custom-attributes]
208
208
  for a reference on how to set values for custom attributes.
209
209
 
@@ -300,7 +300,7 @@ class Folder(pulumi.CustomResource):
300
300
  Create a Folder resource with the given unique name, props, and options.
301
301
  :param str resource_name: The name of the resource.
302
302
  :param pulumi.ResourceOptions opts: Options for the resource.
303
- :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
303
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
304
304
  value strings to set for folder. See [here][docs-setting-custom-attributes]
305
305
  for a reference on how to set values for custom attributes.
306
306
 
@@ -399,7 +399,7 @@ class Folder(pulumi.CustomResource):
399
399
  :param str resource_name: The unique name of the resulting resource.
400
400
  :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
401
401
  :param pulumi.ResourceOptions opts: Options for the resource.
402
- :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
402
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] custom_attributes: Map of custom attribute ids to attribute
403
403
  value strings to set for folder. See [here][docs-setting-custom-attributes]
404
404
  for a reference on how to set values for custom attributes.
405
405
 
@@ -445,7 +445,7 @@ class Folder(pulumi.CustomResource):
445
445
  @pulumi.getter(name="customAttributes")
446
446
  def custom_attributes(self) -> pulumi.Output[Optional[Mapping[str, str]]]:
447
447
  """
448
- Map of custom attribute ids to attribute
448
+ Map of custom attribute ids to attribute
449
449
  value strings to set for folder. See [here][docs-setting-custom-attributes]
450
450
  for a reference on how to set values for custom attributes.
451
451
 
@@ -91,6 +91,7 @@ def get_compute_cluster(datacenter_id: Optional[str] = None,
91
91
 
92
92
  ## Example Usage
93
93
 
94
+ <!--Start PulumiCodeChooser -->
94
95
  ```python
95
96
  import pulumi
96
97
  import pulumi_vsphere as vsphere
@@ -99,6 +100,7 @@ def get_compute_cluster(datacenter_id: Optional[str] = None,
99
100
  compute_cluster = vsphere.get_compute_cluster(name="cluster-01",
100
101
  datacenter_id=datacenter.id)
101
102
  ```
103
+ <!--End PulumiCodeChooser -->
102
104
 
103
105
 
104
106
  :param str datacenter_id: The managed object reference ID
@@ -137,6 +139,7 @@ def get_compute_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[str
137
139
 
138
140
  ## Example Usage
139
141
 
142
+ <!--Start PulumiCodeChooser -->
140
143
  ```python
141
144
  import pulumi
142
145
  import pulumi_vsphere as vsphere
@@ -145,6 +148,7 @@ def get_compute_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[str
145
148
  compute_cluster = vsphere.get_compute_cluster(name="cluster-01",
146
149
  datacenter_id=datacenter.id)
147
150
  ```
151
+ <!--End PulumiCodeChooser -->
148
152
 
149
153
 
150
154
  :param str datacenter_id: The managed object reference ID
@@ -85,21 +85,22 @@ def get_compute_cluster_host_group(compute_cluster_id: Optional[str] = None,
85
85
 
86
86
  ## Example Usage
87
87
 
88
+ <!--Start PulumiCodeChooser -->
88
89
  ```python
89
90
  import pulumi
90
91
  import pulumi_vsphere as vsphere
91
92
 
92
- datacenter = vsphere.get_datacenter(name=vsphere_datacenter)
93
- cluster = vsphere.get_compute_cluster(name=vsphere_cluster,
93
+ datacenter = vsphere.get_datacenter(name=var["vsphere_datacenter"])
94
+ cluster = vsphere.get_compute_cluster(name=var["vsphere_cluster"],
94
95
  datacenter_id=datacenter.id)
95
96
  host_group1 = vsphere.get_compute_cluster_host_group(name="host_group1",
96
97
  compute_cluster_id=cluster.id)
97
- host_rule1 = vsphere.ComputeClusterVmHostRule("host_rule1",
98
+ host_rule1 = vsphere.ComputeClusterVmHostRule("hostRule1",
98
99
  compute_cluster_id=cluster.id,
99
- name="terraform-host-rule1",
100
100
  vm_group_name="vm_group1",
101
101
  affinity_host_group_name=host_group1.name)
102
102
  ```
103
+ <!--End PulumiCodeChooser -->
103
104
 
104
105
 
105
106
  :param str compute_cluster_id: The [managed object reference ID][docs-about-morefs]
@@ -132,21 +133,22 @@ def get_compute_cluster_host_group_output(compute_cluster_id: Optional[pulumi.In
132
133
 
133
134
  ## Example Usage
134
135
 
136
+ <!--Start PulumiCodeChooser -->
135
137
  ```python
136
138
  import pulumi
137
139
  import pulumi_vsphere as vsphere
138
140
 
139
- datacenter = vsphere.get_datacenter(name=vsphere_datacenter)
140
- cluster = vsphere.get_compute_cluster(name=vsphere_cluster,
141
+ datacenter = vsphere.get_datacenter(name=var["vsphere_datacenter"])
142
+ cluster = vsphere.get_compute_cluster(name=var["vsphere_cluster"],
141
143
  datacenter_id=datacenter.id)
142
144
  host_group1 = vsphere.get_compute_cluster_host_group(name="host_group1",
143
145
  compute_cluster_id=cluster.id)
144
- host_rule1 = vsphere.ComputeClusterVmHostRule("host_rule1",
146
+ host_rule1 = vsphere.ComputeClusterVmHostRule("hostRule1",
145
147
  compute_cluster_id=cluster.id,
146
- name="terraform-host-rule1",
147
148
  vm_group_name="vm_group1",
148
149
  affinity_host_group_name=host_group1.name)
149
150
  ```
151
+ <!--End PulumiCodeChooser -->
150
152
 
151
153
 
152
154
  :param str compute_cluster_id: The [managed object reference ID][docs-about-morefs]
@@ -62,12 +62,14 @@ def get_content_library(name: Optional[str] = None,
62
62
 
63
63
  ## Example Usage
64
64
 
65
+ <!--Start PulumiCodeChooser -->
65
66
  ```python
66
67
  import pulumi
67
68
  import pulumi_vsphere as vsphere
68
69
 
69
70
  library = vsphere.get_content_library(name="Content Library")
70
71
  ```
72
+ <!--End PulumiCodeChooser -->
71
73
 
72
74
 
73
75
  :param str name: The name of the content library.
@@ -92,12 +94,14 @@ def get_content_library_output(name: Optional[pulumi.Input[str]] = None,
92
94
 
93
95
  ## Example Usage
94
96
 
97
+ <!--Start PulumiCodeChooser -->
95
98
  ```python
96
99
  import pulumi
97
100
  import pulumi_vsphere as vsphere
98
101
 
99
102
  library = vsphere.get_content_library(name="Content Library")
100
103
  ```
104
+ <!--End PulumiCodeChooser -->
101
105
 
102
106
 
103
107
  :param str name: The name of the content library.
@@ -76,12 +76,14 @@ def get_custom_attribute(name: Optional[str] = None,
76
76
 
77
77
  ## Example Usage
78
78
 
79
+ <!--Start PulumiCodeChooser -->
79
80
  ```python
80
81
  import pulumi
81
82
  import pulumi_vsphere as vsphere
82
83
 
83
84
  attribute = vsphere.get_custom_attribute(name="test-attribute")
84
85
  ```
86
+ <!--End PulumiCodeChooser -->
85
87
 
86
88
 
87
89
  :param str name: The name of the custom attribute.
@@ -112,12 +114,14 @@ def get_custom_attribute_output(name: Optional[pulumi.Input[str]] = None,
112
114
 
113
115
  ## Example Usage
114
116
 
117
+ <!--Start PulumiCodeChooser -->
115
118
  ```python
116
119
  import pulumi
117
120
  import pulumi_vsphere as vsphere
118
121
 
119
122
  attribute = vsphere.get_custom_attribute(name="test-attribute")
120
123
  ```
124
+ <!--End PulumiCodeChooser -->
121
125
 
122
126
 
123
127
  :param str name: The name of the custom attribute.
@@ -63,12 +63,14 @@ def get_datacenter(name: Optional[str] = None,
63
63
 
64
64
  ## Example Usage
65
65
 
66
+ <!--Start PulumiCodeChooser -->
66
67
  ```python
67
68
  import pulumi
68
69
  import pulumi_vsphere as vsphere
69
70
 
70
71
  datacenter = vsphere.get_datacenter(name="dc-01")
71
72
  ```
73
+ <!--End PulumiCodeChooser -->
72
74
 
73
75
 
74
76
  :param str name: The name of the datacenter. This can be a name or path.
@@ -100,12 +102,14 @@ def get_datacenter_output(name: Optional[pulumi.Input[Optional[str]]] = None,
100
102
 
101
103
  ## Example Usage
102
104
 
105
+ <!--Start PulumiCodeChooser -->
103
106
  ```python
104
107
  import pulumi
105
108
  import pulumi_vsphere as vsphere
106
109
 
107
110
  datacenter = vsphere.get_datacenter(name="dc-01")
108
111
  ```
112
+ <!--End PulumiCodeChooser -->
109
113
 
110
114
 
111
115
  :param str name: The name of the datacenter. This can be a name or path.
@@ -88,6 +88,7 @@ def get_datastore(datacenter_id: Optional[str] = None,
88
88
 
89
89
  ## Example Usage
90
90
 
91
+ <!--Start PulumiCodeChooser -->
91
92
  ```python
92
93
  import pulumi
93
94
  import pulumi_vsphere as vsphere
@@ -96,6 +97,7 @@ def get_datastore(datacenter_id: Optional[str] = None,
96
97
  datastore = vsphere.get_datastore(name="datastore-01",
97
98
  datacenter_id=datacenter.id)
98
99
  ```
100
+ <!--End PulumiCodeChooser -->
99
101
 
100
102
 
101
103
  :param str datacenter_id: The managed object reference ID
@@ -134,6 +136,7 @@ def get_datastore_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] =
134
136
 
135
137
  ## Example Usage
136
138
 
139
+ <!--Start PulumiCodeChooser -->
137
140
  ```python
138
141
  import pulumi
139
142
  import pulumi_vsphere as vsphere
@@ -142,6 +145,7 @@ def get_datastore_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] =
142
145
  datastore = vsphere.get_datastore(name="datastore-01",
143
146
  datacenter_id=datacenter.id)
144
147
  ```
148
+ <!--End PulumiCodeChooser -->
145
149
 
146
150
 
147
151
  :param str datacenter_id: The managed object reference ID
@@ -73,6 +73,7 @@ def get_datastore_cluster(datacenter_id: Optional[str] = None,
73
73
 
74
74
  ## Example Usage
75
75
 
76
+ <!--Start PulumiCodeChooser -->
76
77
  ```python
77
78
  import pulumi
78
79
  import pulumi_vsphere as vsphere
@@ -81,6 +82,7 @@ def get_datastore_cluster(datacenter_id: Optional[str] = None,
81
82
  datastore_cluster = vsphere.get_datastore_cluster(name="datastore-cluster-01",
82
83
  datacenter_id=datacenter.id)
83
84
  ```
85
+ <!--End PulumiCodeChooser -->
84
86
 
85
87
 
86
88
  :param str datacenter_id: The managed object reference
@@ -114,6 +116,7 @@ def get_datastore_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[s
114
116
 
115
117
  ## Example Usage
116
118
 
119
+ <!--Start PulumiCodeChooser -->
117
120
  ```python
118
121
  import pulumi
119
122
  import pulumi_vsphere as vsphere
@@ -122,6 +125,7 @@ def get_datastore_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[s
122
125
  datastore_cluster = vsphere.get_datastore_cluster(name="datastore-cluster-01",
123
126
  datacenter_id=datacenter.id)
124
127
  ```
128
+ <!--End PulumiCodeChooser -->
125
129
 
126
130
 
127
131
  :param str datacenter_id: The managed object reference
@@ -95,6 +95,7 @@ def get_datastore_stats(capacity: Optional[Mapping[str, Any]] = None,
95
95
 
96
96
  ## Example Usage
97
97
 
98
+ <!--Start PulumiCodeChooser -->
98
99
  ```python
99
100
  import pulumi
100
101
  import pulumi_vsphere as vsphere
@@ -102,6 +103,7 @@ def get_datastore_stats(capacity: Optional[Mapping[str, Any]] = None,
102
103
  datacenter = vsphere.get_datacenter(name="dc-01")
103
104
  datastore_stats = vsphere.get_datastore_stats(datacenter_id=datacenter.id)
104
105
  ```
106
+ <!--End PulumiCodeChooser -->
105
107
 
106
108
  A usefull example of this datasource would be to determine the
107
109
  datastore with the most free space. For example, in addition to
@@ -109,12 +111,14 @@ def get_datastore_stats(capacity: Optional[Mapping[str, Any]] = None,
109
111
 
110
112
  Create an `outputs.tf` like that:
111
113
 
114
+ <!--Start PulumiCodeChooser -->
112
115
  ```python
113
116
  import pulumi
114
117
 
115
- pulumi.export("maxFreeSpaceName", their_max_free_space_name)
116
- pulumi.export("maxFreeSpace", their_max_free_space)
118
+ pulumi.export("maxFreeSpaceName", local["max_free_space_name"])
119
+ pulumi.export("maxFreeSpace", local["max_free_space"])
117
120
  ```
121
+ <!--End PulumiCodeChooser -->
118
122
 
119
123
  and a `locals.tf` like that:
120
124
 
@@ -156,6 +160,7 @@ def get_datastore_stats_output(capacity: Optional[pulumi.Input[Optional[Mapping[
156
160
 
157
161
  ## Example Usage
158
162
 
163
+ <!--Start PulumiCodeChooser -->
159
164
  ```python
160
165
  import pulumi
161
166
  import pulumi_vsphere as vsphere
@@ -163,6 +168,7 @@ def get_datastore_stats_output(capacity: Optional[pulumi.Input[Optional[Mapping[
163
168
  datacenter = vsphere.get_datacenter(name="dc-01")
164
169
  datastore_stats = vsphere.get_datastore_stats(datacenter_id=datacenter.id)
165
170
  ```
171
+ <!--End PulumiCodeChooser -->
166
172
 
167
173
  A usefull example of this datasource would be to determine the
168
174
  datastore with the most free space. For example, in addition to
@@ -170,12 +176,14 @@ def get_datastore_stats_output(capacity: Optional[pulumi.Input[Optional[Mapping[
170
176
 
171
177
  Create an `outputs.tf` like that:
172
178
 
179
+ <!--Start PulumiCodeChooser -->
173
180
  ```python
174
181
  import pulumi
175
182
 
176
- pulumi.export("maxFreeSpaceName", their_max_free_space_name)
177
- pulumi.export("maxFreeSpace", their_max_free_space)
183
+ pulumi.export("maxFreeSpaceName", local["max_free_space_name"])
184
+ pulumi.export("maxFreeSpace", local["max_free_space"])
178
185
  ```
186
+ <!--End PulumiCodeChooser -->
179
187
 
180
188
  and a `locals.tf` like that:
181
189
 
@@ -97,6 +97,7 @@ def get_distributed_virtual_switch(datacenter_id: Optional[str] = None,
97
97
  `DistributedPortGroup` resource that uses the first uplink as a
98
98
  primary uplink and the second uplink as a secondary.
99
99
 
100
+ <!--Start PulumiCodeChooser -->
100
101
  ```python
101
102
  import pulumi
102
103
  import pulumi_vsphere as vsphere
@@ -105,11 +106,11 @@ def get_distributed_virtual_switch(datacenter_id: Optional[str] = None,
105
106
  vds = vsphere.get_distributed_virtual_switch(name="vds-01",
106
107
  datacenter_id=datacenter.id)
107
108
  dvpg = vsphere.DistributedPortGroup("dvpg",
108
- name="dvpg-01",
109
109
  distributed_virtual_switch_uuid=vds.id,
110
110
  active_uplinks=[vds.uplinks[0]],
111
111
  standby_uplinks=[vds.uplinks[1]])
112
112
  ```
113
+ <!--End PulumiCodeChooser -->
113
114
 
114
115
 
115
116
  :param str datacenter_id: The managed object reference ID
@@ -152,6 +153,7 @@ def get_distributed_virtual_switch_output(datacenter_id: Optional[pulumi.Input[O
152
153
  `DistributedPortGroup` resource that uses the first uplink as a
153
154
  primary uplink and the second uplink as a secondary.
154
155
 
156
+ <!--Start PulumiCodeChooser -->
155
157
  ```python
156
158
  import pulumi
157
159
  import pulumi_vsphere as vsphere
@@ -160,11 +162,11 @@ def get_distributed_virtual_switch_output(datacenter_id: Optional[pulumi.Input[O
160
162
  vds = vsphere.get_distributed_virtual_switch(name="vds-01",
161
163
  datacenter_id=datacenter.id)
162
164
  dvpg = vsphere.DistributedPortGroup("dvpg",
163
- name="dvpg-01",
164
165
  distributed_virtual_switch_uuid=vds.id,
165
166
  active_uplinks=[vds.uplinks[0]],
166
167
  standby_uplinks=[vds.uplinks[1]])
167
168
  ```
169
+ <!--End PulumiCodeChooser -->
168
170
 
169
171
 
170
172
  :param str datacenter_id: The managed object reference ID
@@ -84,15 +84,16 @@ def get_dynamic(filters: Optional[Sequence[str]] = None,
84
84
 
85
85
  ## Example Usage
86
86
 
87
+ <!--Start PulumiCodeChooser -->
87
88
  ```python
88
89
  import pulumi
89
90
  import pulumi_vsphere as vsphere
90
91
 
91
92
  category = vsphere.get_tag_category(name="SomeCategory")
92
93
  tag1 = vsphere.get_tag(name="FirstTag",
93
- category_id=cat["id"])
94
+ category_id=data["vsphere_tag_category"]["cat"]["id"])
94
95
  tag2 = vsphere.get_tag(name="SecondTag",
95
- category_id=cat["id"])
96
+ category_id=data["vsphere_tag_category"]["cat"]["id"])
96
97
  dyn = vsphere.get_dynamic(filters=[
97
98
  tag1.id,
98
99
  tag1.id,
@@ -100,6 +101,7 @@ def get_dynamic(filters: Optional[Sequence[str]] = None,
100
101
  name_regex="ubuntu",
101
102
  type="Datacenter")
102
103
  ```
104
+ <!--End PulumiCodeChooser -->
103
105
 
104
106
 
105
107
  :param Sequence[str] filters: A list of tag IDs that must be present on an object to
@@ -138,15 +140,16 @@ def get_dynamic_output(filters: Optional[pulumi.Input[Sequence[str]]] = None,
138
140
 
139
141
  ## Example Usage
140
142
 
143
+ <!--Start PulumiCodeChooser -->
141
144
  ```python
142
145
  import pulumi
143
146
  import pulumi_vsphere as vsphere
144
147
 
145
148
  category = vsphere.get_tag_category(name="SomeCategory")
146
149
  tag1 = vsphere.get_tag(name="FirstTag",
147
- category_id=cat["id"])
150
+ category_id=data["vsphere_tag_category"]["cat"]["id"])
148
151
  tag2 = vsphere.get_tag(name="SecondTag",
149
- category_id=cat["id"])
152
+ category_id=data["vsphere_tag_category"]["cat"]["id"])
150
153
  dyn = vsphere.get_dynamic(filters=[
151
154
  tag1.id,
152
155
  tag1.id,
@@ -154,6 +157,7 @@ def get_dynamic_output(filters: Optional[pulumi.Input[Sequence[str]]] = None,
154
157
  name_regex="ubuntu",
155
158
  type="Datacenter")
156
159
  ```
160
+ <!--End PulumiCodeChooser -->
157
161
 
158
162
 
159
163
  :param Sequence[str] filters: A list of tag IDs that must be present on an object to
@@ -57,20 +57,18 @@ def get_folder(path: Optional[str] = None,
57
57
  opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetFolderResult:
58
58
  """
59
59
  The `Folder` data source can be used to get the general attributes of a
60
- vSphere inventory folder. The data source supports creating folders of the 5
61
- major types - datacenter folders, host and cluster folders, virtual machine
62
- folders, storage folders, and network folders.
63
-
64
- Paths are absolute and must include the datacenter.
60
+ vSphere inventory folder. Paths are absolute and must include the datacenter.
65
61
 
66
62
  ## Example Usage
67
63
 
64
+ <!--Start PulumiCodeChooser -->
68
65
  ```python
69
66
  import pulumi
70
67
  import pulumi_vsphere as vsphere
71
68
 
72
69
  folder = vsphere.get_folder(path="/dc-01/datastore-01/folder-01")
73
70
  ```
71
+ <!--End PulumiCodeChooser -->
74
72
 
75
73
 
76
74
  :param str path: The absolute path of the folder. For example, given a
@@ -94,20 +92,18 @@ def get_folder_output(path: Optional[pulumi.Input[str]] = None,
94
92
  opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetFolderResult]:
95
93
  """
96
94
  The `Folder` data source can be used to get the general attributes of a
97
- vSphere inventory folder. The data source supports creating folders of the 5
98
- major types - datacenter folders, host and cluster folders, virtual machine
99
- folders, storage folders, and network folders.
100
-
101
- Paths are absolute and must include the datacenter.
95
+ vSphere inventory folder. Paths are absolute and must include the datacenter.
102
96
 
103
97
  ## Example Usage
104
98
 
99
+ <!--Start PulumiCodeChooser -->
105
100
  ```python
106
101
  import pulumi
107
102
  import pulumi_vsphere as vsphere
108
103
 
109
104
  folder = vsphere.get_folder(path="/dc-01/datastore-01/folder-01")
110
105
  ```
106
+ <!--End PulumiCodeChooser -->
111
107
 
112
108
 
113
109
  :param str path: The absolute path of the folder. For example, given a
@@ -124,12 +124,14 @@ def get_guest_os_customization(name: Optional[str] = None,
124
124
 
125
125
  ## Example Usage
126
126
 
127
+ <!--Start PulumiCodeChooser -->
127
128
  ```python
128
129
  import pulumi
129
130
  import pulumi_vsphere as vsphere
130
131
 
131
132
  gosc1 = vsphere.get_guest_os_customization(name="linux-spec")
132
133
  ```
134
+ <!--End PulumiCodeChooser -->
133
135
 
134
136
 
135
137
  :param str name: The name of the customization specification is the unique identifier per vCenter Server instance.
@@ -160,12 +162,14 @@ def get_guest_os_customization_output(name: Optional[pulumi.Input[str]] = None,
160
162
 
161
163
  ## Example Usage
162
164
 
165
+ <!--Start PulumiCodeChooser -->
163
166
  ```python
164
167
  import pulumi
165
168
  import pulumi_vsphere as vsphere
166
169
 
167
170
  gosc1 = vsphere.get_guest_os_customization(name="linux-spec")
168
171
  ```
172
+ <!--End PulumiCodeChooser -->
169
173
 
170
174
 
171
175
  :param str name: The name of the customization specification is the unique identifier per vCenter Server instance.
@@ -85,6 +85,7 @@ def get_host(datacenter_id: Optional[str] = None,
85
85
 
86
86
  ## Example Usage
87
87
 
88
+ <!--Start PulumiCodeChooser -->
88
89
  ```python
89
90
  import pulumi
90
91
  import pulumi_vsphere as vsphere
@@ -93,6 +94,7 @@ def get_host(datacenter_id: Optional[str] = None,
93
94
  host = vsphere.get_host(name="esxi-01.example.com",
94
95
  datacenter_id=datacenter.id)
95
96
  ```
97
+ <!--End PulumiCodeChooser -->
96
98
 
97
99
 
98
100
  :param str datacenter_id: The managed object reference ID
@@ -127,6 +129,7 @@ def get_host_output(datacenter_id: Optional[pulumi.Input[str]] = None,
127
129
 
128
130
  ## Example Usage
129
131
 
132
+ <!--Start PulumiCodeChooser -->
130
133
  ```python
131
134
  import pulumi
132
135
  import pulumi_vsphere as vsphere
@@ -135,6 +138,7 @@ def get_host_output(datacenter_id: Optional[pulumi.Input[str]] = None,
135
138
  host = vsphere.get_host(name="esxi-01.example.com",
136
139
  datacenter_id=datacenter.id)
137
140
  ```
141
+ <!--End PulumiCodeChooser -->
138
142
 
139
143
 
140
144
  :param str datacenter_id: The managed object reference ID