From 23766f3410ce7209f68785054e088756c231de1b Mon Sep 17 00:00:00 2001 From: pulumi-bot Date: Mon, 9 Dec 2024 17:10:37 +0000 Subject: [PATCH 1/2] make tfgen --- .pulumi-java-gen.version | 2 +- examples/go.mod | 4 +- examples/go.sum | 8 +- .../cmd/pulumi-resource-vsphere/schema.json | 82 +++++++++---------- provider/go.mod | 10 +-- provider/go.sum | 20 ++--- sdk/go.mod | 2 +- sdk/go.sum | 4 +- 8 files changed, 66 insertions(+), 66 deletions(-) diff --git a/.pulumi-java-gen.version b/.pulumi-java-gen.version index 07feb823..47d04a52 100644 --- a/.pulumi-java-gen.version +++ b/.pulumi-java-gen.version @@ -1 +1 @@ -0.17.0 \ No newline at end of file +0.18.0 \ No newline at end of file diff --git a/examples/go.mod b/examples/go.mod index 7fd30c8b..7e3d7e5e 100644 --- a/examples/go.mod +++ b/examples/go.mod @@ -2,7 +2,7 @@ module github.com/pulumi/pulumi-vsphere/examples/v4 go 1.21 -require github.com/pulumi/pulumi/pkg/v3 v3.140.0 +require github.com/pulumi/pulumi/pkg/v3 v3.142.0 require ( cloud.google.com/go v0.112.1 // indirect @@ -123,7 +123,7 @@ require ( github.com/pmezard/go-difflib v1.0.0 // indirect github.com/pulumi/appdash v0.0.0-20231130102222-75f619a67231 // indirect github.com/pulumi/esc v0.10.0 // indirect - github.com/pulumi/pulumi/sdk/v3 v3.140.0 // indirect + github.com/pulumi/pulumi/sdk/v3 v3.142.0 // indirect github.com/rivo/uniseg v0.4.4 // indirect github.com/rogpeppe/go-internal v1.12.0 // indirect github.com/ryanuber/go-glob v1.0.0 // indirect diff --git a/examples/go.sum b/examples/go.sum index e2374cde..304740d7 100644 --- a/examples/go.sum +++ b/examples/go.sum @@ -339,10 +339,10 @@ github.com/pulumi/appdash v0.0.0-20231130102222-75f619a67231 h1:vkHw5I/plNdTr435 github.com/pulumi/appdash v0.0.0-20231130102222-75f619a67231/go.mod h1:murToZ2N9hNJzewjHBgfFdXhZKjY3z5cYC1VXk+lbFE= github.com/pulumi/esc v0.10.0 h1:jzBKzkLVW0mePeanDRfqSQoCJ5yrkux0jIwAkUxpRKE= github.com/pulumi/esc v0.10.0/go.mod h1:2Bfa+FWj/xl8CKqRTWbWgDX0SOD4opdQgvYSURTGK2c= -github.com/pulumi/pulumi/pkg/v3 v3.140.0 h1:/bvHa19HY/6qHWvuAOVII8qr72MDGGczBWlPYlPo3j0= -github.com/pulumi/pulumi/pkg/v3 v3.140.0/go.mod h1:rcTtSyisd7BzZTugNk/s9zlYgX9S0S10+pha3Tko6yM= -github.com/pulumi/pulumi/sdk/v3 v3.140.0 h1:+Z/RBvdYg7tBNkBwk4p/FzlV7niBT3TbLAICq/Y0LDU= -github.com/pulumi/pulumi/sdk/v3 v3.140.0/go.mod h1:PvKsX88co8XuwuPdzolMvew5lZV+4JmZfkeSjj7A6dI= +github.com/pulumi/pulumi/pkg/v3 v3.142.0 h1:UE8TFyXrlxvPrATpd3Kl3En34KrFIFWOxxNAodywPNU= +github.com/pulumi/pulumi/pkg/v3 v3.142.0/go.mod h1:3k6WwRIT7veiDnk3Yo2NtqEYX+4dgLCrMIFvEOnjQqI= +github.com/pulumi/pulumi/sdk/v3 v3.142.0 h1:SmcVddGuvwAh3g3XUVQQ5gVRQUKH1yZ6iETpDNHIHlw= +github.com/pulumi/pulumi/sdk/v3 v3.142.0/go.mod h1:PvKsX88co8XuwuPdzolMvew5lZV+4JmZfkeSjj7A6dI= github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.4.4 h1:8TfxU8dW6PdqD27gjM8MVNuicgxIjxpm4K7x4jp8sis= diff --git a/provider/cmd/pulumi-resource-vsphere/schema.json b/provider/cmd/pulumi-resource-vsphere/schema.json index 363759a0..acaea145 100644 --- a/provider/cmd/pulumi-resource-vsphere/schema.json +++ b/provider/cmd/pulumi-resource-vsphere/schema.json @@ -3171,7 +3171,7 @@ } }, "vsphere:index/computeClusterVmDependencyRule:ComputeClusterVmDependencyRule": { - "description": "The `vsphere.ComputeClusterVmDependencyRule` resource can be used to manage\nVM dependency rules in a cluster, either created by the\n`vsphere.ComputeCluster` resource or looked up\nby the `vsphere.ComputeCluster` data source.\n\nA virtual machine dependency rule applies to vSphere HA, and allows\nuser-defined startup orders for virtual machines in the case of host failure.\nVirtual machines are supplied via groups, which can be managed via the\n`vsphere.ComputeClusterVmGroup`\nresource.\n\n\u003e **NOTE:** This resource requires vCenter and is not available on direct ESXi\nconnections.\n\n## Example Usage\n\nThe example below creates two virtual machine in a cluster using the\n`vsphere.VirtualMachine` resource in a cluster\nlooked up by the `vsphere.ComputeCluster`\ndata source. It then creates a group with this virtual machine. Two groups are created, each with one of the created VMs. Finally, a rule is created to ensure that `vm1` starts before `vm2`.\n\n\u003e Note how `dependency_vm_group_name` and\n`vm_group_name` are sourced off of the `name` attributes from\nthe `vsphere.ComputeClusterVmGroup`\nresource. This is to ensure that the rule is not created before the groups\nexist, which may not possibly happen in the event that the names came from a\n\"static\" source such as a variable.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore1\",\n datacenterId: datacenter.id,\n}));\nconst cluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"network1\",\n datacenterId: datacenter.id,\n}));\nconst vm1 = new vsphere.VirtualMachine(\"vm1\", {\n name: \"test1\",\n resourcePoolId: cluster.then(cluster =\u003e cluster.resourcePoolId),\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 2048,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst vm2 = new vsphere.VirtualMachine(\"vm2\", {\n name: \"test2\",\n resourcePoolId: cluster.then(cluster =\u003e cluster.resourcePoolId),\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 2048,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst clusterVmGroup1 = new vsphere.ComputeClusterVmGroup(\"cluster_vm_group1\", {\n name: \"test-cluster-vm-group1\",\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n virtualMachineIds: [vm1.id],\n});\nconst clusterVmGroup2 = new vsphere.ComputeClusterVmGroup(\"cluster_vm_group2\", {\n name: \"test-cluster-vm-group2\",\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n virtualMachineIds: [vm2.id],\n});\nconst clusterVmDependencyRule = new vsphere.ComputeClusterVmDependencyRule(\"cluster_vm_dependency_rule\", {\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n name: \"test-cluster-vm-dependency-rule\",\n dependencyVmGroupName: clusterVmGroup1.name,\n vmGroupName: clusterVmGroup2.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datastore(name=\"datastore1\",\n datacenter_id=datacenter.id)\ncluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"network1\",\n datacenter_id=datacenter.id)\nvm1 = vsphere.VirtualMachine(\"vm1\",\n name=\"test1\",\n resource_pool_id=cluster.resource_pool_id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=2048,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\nvm2 = vsphere.VirtualMachine(\"vm2\",\n name=\"test2\",\n resource_pool_id=cluster.resource_pool_id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=2048,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\ncluster_vm_group1 = vsphere.ComputeClusterVmGroup(\"cluster_vm_group1\",\n name=\"test-cluster-vm-group1\",\n compute_cluster_id=cluster.id,\n virtual_machine_ids=[vm1.id])\ncluster_vm_group2 = vsphere.ComputeClusterVmGroup(\"cluster_vm_group2\",\n name=\"test-cluster-vm-group2\",\n compute_cluster_id=cluster.id,\n virtual_machine_ids=[vm2.id])\ncluster_vm_dependency_rule = vsphere.ComputeClusterVmDependencyRule(\"cluster_vm_dependency_rule\",\n compute_cluster_id=cluster.id,\n name=\"test-cluster-vm-dependency-rule\",\n dependency_vm_group_name=cluster_vm_group1.name,\n vm_group_name=cluster_vm_group2.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var cluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"network1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vm1 = new VSphere.VirtualMachine(\"vm1\", new()\n {\n Name = \"test1\",\n ResourcePoolId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 2048,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var vm2 = new VSphere.VirtualMachine(\"vm2\", new()\n {\n Name = \"test2\",\n ResourcePoolId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 2048,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var clusterVmGroup1 = new VSphere.ComputeClusterVmGroup(\"cluster_vm_group1\", new()\n {\n Name = \"test-cluster-vm-group1\",\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n VirtualMachineIds = new[]\n {\n vm1.Id,\n },\n });\n\n var clusterVmGroup2 = new VSphere.ComputeClusterVmGroup(\"cluster_vm_group2\", new()\n {\n Name = \"test-cluster-vm-group2\",\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n VirtualMachineIds = new[]\n {\n vm2.Id,\n },\n });\n\n var clusterVmDependencyRule = new VSphere.ComputeClusterVmDependencyRule(\"cluster_vm_dependency_rule\", new()\n {\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n Name = \"test-cluster-vm-dependency-rule\",\n DependencyVmGroupName = clusterVmGroup1.Name,\n VmGroupName = clusterVmGroup2.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"network1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm1, err := vsphere.NewVirtualMachine(ctx, \"vm1\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test1\"),\n\t\t\tResourcePoolId: pulumi.String(cluster.ResourcePoolId),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(2048),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm2, err := vsphere.NewVirtualMachine(ctx, \"vm2\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test2\"),\n\t\t\tResourcePoolId: pulumi.String(cluster.ResourcePoolId),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(2048),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tclusterVmGroup1, err := vsphere.NewComputeClusterVmGroup(ctx, \"cluster_vm_group1\", \u0026vsphere.ComputeClusterVmGroupArgs{\n\t\t\tName: pulumi.String(\"test-cluster-vm-group1\"),\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tVirtualMachineIds: pulumi.StringArray{\n\t\t\t\tvm1.ID(),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tclusterVmGroup2, err := vsphere.NewComputeClusterVmGroup(ctx, \"cluster_vm_group2\", \u0026vsphere.ComputeClusterVmGroupArgs{\n\t\t\tName: pulumi.String(\"test-cluster-vm-group2\"),\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tVirtualMachineIds: pulumi.StringArray{\n\t\t\t\tvm2.ID(),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewComputeClusterVmDependencyRule(ctx, \"cluster_vm_dependency_rule\", \u0026vsphere.ComputeClusterVmDependencyRuleArgs{\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tName: pulumi.String(\"test-cluster-vm-dependency-rule\"),\n\t\t\tDependencyVmGroupName: clusterVmGroup1.Name,\n\t\t\tVmGroupName: clusterVmGroup2.Name,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.ComputeClusterVmGroup;\nimport com.pulumi.vsphere.ComputeClusterVmGroupArgs;\nimport com.pulumi.vsphere.ComputeClusterVmDependencyRule;\nimport com.pulumi.vsphere.ComputeClusterVmDependencyRuleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var cluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"network1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vm1 = new VirtualMachine(\"vm1\", VirtualMachineArgs.builder()\n .name(\"test1\")\n .resourcePoolId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(2048)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var vm2 = new VirtualMachine(\"vm2\", VirtualMachineArgs.builder()\n .name(\"test2\")\n .resourcePoolId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(2048)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var clusterVmGroup1 = new ComputeClusterVmGroup(\"clusterVmGroup1\", ComputeClusterVmGroupArgs.builder()\n .name(\"test-cluster-vm-group1\")\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .virtualMachineIds(vm1.id())\n .build());\n\n var clusterVmGroup2 = new ComputeClusterVmGroup(\"clusterVmGroup2\", ComputeClusterVmGroupArgs.builder()\n .name(\"test-cluster-vm-group2\")\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .virtualMachineIds(vm2.id())\n .build());\n\n var clusterVmDependencyRule = new ComputeClusterVmDependencyRule(\"clusterVmDependencyRule\", ComputeClusterVmDependencyRuleArgs.builder()\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .name(\"test-cluster-vm-dependency-rule\")\n .dependencyVmGroupName(clusterVmGroup1.name())\n .vmGroupName(clusterVmGroup2.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vm1:\n type: vsphere:VirtualMachine\n properties:\n name: test1\n resourcePoolId: ${cluster.resourcePoolId}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 2048\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n vm2:\n type: vsphere:VirtualMachine\n properties:\n name: test2\n resourcePoolId: ${cluster.resourcePoolId}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 2048\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n clusterVmGroup1:\n type: vsphere:ComputeClusterVmGroup\n name: cluster_vm_group1\n properties:\n name: test-cluster-vm-group1\n computeClusterId: ${cluster.id}\n virtualMachineIds:\n - ${vm1.id}\n clusterVmGroup2:\n type: vsphere:ComputeClusterVmGroup\n name: cluster_vm_group2\n properties:\n name: test-cluster-vm-group2\n computeClusterId: ${cluster.id}\n virtualMachineIds:\n - ${vm2.id}\n clusterVmDependencyRule:\n type: vsphere:ComputeClusterVmDependencyRule\n name: cluster_vm_dependency_rule\n properties:\n computeClusterId: ${cluster.id}\n name: test-cluster-vm-dependency-rule\n dependencyVmGroupName: ${clusterVmGroup1.name}\n vmGroupName: ${clusterVmGroup2.name}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n datastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: datastore1\n datacenterId: ${datacenter.id}\n cluster:\n fn::invoke:\n Function: vsphere:getComputeCluster\n Arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n Function: vsphere:getNetwork\n Arguments:\n name: network1\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing rule can be imported into this resource by supplying\n\nboth the path to the cluster, and the name the rule. If the name or cluster is\n\nnot found, or if the rule is of a different type, an error will be returned. An\n\nexample is below:\n\n```sh\n$ pulumi import vsphere:index/computeClusterVmDependencyRule:ComputeClusterVmDependencyRule cluster_vm_dependency_rule \\\n```\n\n '{\"compute_cluster_path\": \"/dc1/host/cluster1\", \\\n\n \"name\": \"pulumi-test-cluster-vm-dependency-rule\"}'\n\n", + "description": "The `vsphere.ComputeClusterVmDependencyRule` resource can be used to manage\nVM dependency rules in a cluster, either created by the\n`vsphere.ComputeCluster` resource or looked up\nby the `vsphere.ComputeCluster` data source.\n\nA virtual machine dependency rule applies to vSphere HA, and allows\nuser-defined startup orders for virtual machines in the case of host failure.\nVirtual machines are supplied via groups, which can be managed via the\n`vsphere.ComputeClusterVmGroup`\nresource.\n\n\u003e **NOTE:** This resource requires vCenter and is not available on direct ESXi\nconnections.\n\n## Example Usage\n\nThe example below creates two virtual machine in a cluster using the\n`vsphere.VirtualMachine` resource in a cluster\nlooked up by the `vsphere.ComputeCluster`\ndata source. It then creates a group with this virtual machine. Two groups are created, each with one of the created VMs. Finally, a rule is created to ensure that `vm1` starts before `vm2`.\n\n\u003e Note how `dependency_vm_group_name` and\n`vm_group_name` are sourced off of the `name` attributes from\nthe `vsphere.ComputeClusterVmGroup`\nresource. This is to ensure that the rule is not created before the groups\nexist, which may not possibly happen in the event that the names came from a\n\"static\" source such as a variable.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore1\",\n datacenterId: datacenter.id,\n}));\nconst cluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"network1\",\n datacenterId: datacenter.id,\n}));\nconst vm1 = new vsphere.VirtualMachine(\"vm1\", {\n name: \"test1\",\n resourcePoolId: cluster.then(cluster =\u003e cluster.resourcePoolId),\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 2048,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst vm2 = new vsphere.VirtualMachine(\"vm2\", {\n name: \"test2\",\n resourcePoolId: cluster.then(cluster =\u003e cluster.resourcePoolId),\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 2048,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst clusterVmGroup1 = new vsphere.ComputeClusterVmGroup(\"cluster_vm_group1\", {\n name: \"test-cluster-vm-group1\",\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n virtualMachineIds: [vm1.id],\n});\nconst clusterVmGroup2 = new vsphere.ComputeClusterVmGroup(\"cluster_vm_group2\", {\n name: \"test-cluster-vm-group2\",\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n virtualMachineIds: [vm2.id],\n});\nconst clusterVmDependencyRule = new vsphere.ComputeClusterVmDependencyRule(\"cluster_vm_dependency_rule\", {\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n name: \"test-cluster-vm-dependency-rule\",\n dependencyVmGroupName: clusterVmGroup1.name,\n vmGroupName: clusterVmGroup2.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datastore(name=\"datastore1\",\n datacenter_id=datacenter.id)\ncluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"network1\",\n datacenter_id=datacenter.id)\nvm1 = vsphere.VirtualMachine(\"vm1\",\n name=\"test1\",\n resource_pool_id=cluster.resource_pool_id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=2048,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\nvm2 = vsphere.VirtualMachine(\"vm2\",\n name=\"test2\",\n resource_pool_id=cluster.resource_pool_id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=2048,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\ncluster_vm_group1 = vsphere.ComputeClusterVmGroup(\"cluster_vm_group1\",\n name=\"test-cluster-vm-group1\",\n compute_cluster_id=cluster.id,\n virtual_machine_ids=[vm1.id])\ncluster_vm_group2 = vsphere.ComputeClusterVmGroup(\"cluster_vm_group2\",\n name=\"test-cluster-vm-group2\",\n compute_cluster_id=cluster.id,\n virtual_machine_ids=[vm2.id])\ncluster_vm_dependency_rule = vsphere.ComputeClusterVmDependencyRule(\"cluster_vm_dependency_rule\",\n compute_cluster_id=cluster.id,\n name=\"test-cluster-vm-dependency-rule\",\n dependency_vm_group_name=cluster_vm_group1.name,\n vm_group_name=cluster_vm_group2.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var cluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"network1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vm1 = new VSphere.VirtualMachine(\"vm1\", new()\n {\n Name = \"test1\",\n ResourcePoolId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 2048,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var vm2 = new VSphere.VirtualMachine(\"vm2\", new()\n {\n Name = \"test2\",\n ResourcePoolId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 2048,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var clusterVmGroup1 = new VSphere.ComputeClusterVmGroup(\"cluster_vm_group1\", new()\n {\n Name = \"test-cluster-vm-group1\",\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n VirtualMachineIds = new[]\n {\n vm1.Id,\n },\n });\n\n var clusterVmGroup2 = new VSphere.ComputeClusterVmGroup(\"cluster_vm_group2\", new()\n {\n Name = \"test-cluster-vm-group2\",\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n VirtualMachineIds = new[]\n {\n vm2.Id,\n },\n });\n\n var clusterVmDependencyRule = new VSphere.ComputeClusterVmDependencyRule(\"cluster_vm_dependency_rule\", new()\n {\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n Name = \"test-cluster-vm-dependency-rule\",\n DependencyVmGroupName = clusterVmGroup1.Name,\n VmGroupName = clusterVmGroup2.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"network1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm1, err := vsphere.NewVirtualMachine(ctx, \"vm1\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test1\"),\n\t\t\tResourcePoolId: pulumi.String(cluster.ResourcePoolId),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(2048),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm2, err := vsphere.NewVirtualMachine(ctx, \"vm2\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test2\"),\n\t\t\tResourcePoolId: pulumi.String(cluster.ResourcePoolId),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(2048),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tclusterVmGroup1, err := vsphere.NewComputeClusterVmGroup(ctx, \"cluster_vm_group1\", \u0026vsphere.ComputeClusterVmGroupArgs{\n\t\t\tName: pulumi.String(\"test-cluster-vm-group1\"),\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tVirtualMachineIds: pulumi.StringArray{\n\t\t\t\tvm1.ID(),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tclusterVmGroup2, err := vsphere.NewComputeClusterVmGroup(ctx, \"cluster_vm_group2\", \u0026vsphere.ComputeClusterVmGroupArgs{\n\t\t\tName: pulumi.String(\"test-cluster-vm-group2\"),\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tVirtualMachineIds: pulumi.StringArray{\n\t\t\t\tvm2.ID(),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewComputeClusterVmDependencyRule(ctx, \"cluster_vm_dependency_rule\", \u0026vsphere.ComputeClusterVmDependencyRuleArgs{\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tName: pulumi.String(\"test-cluster-vm-dependency-rule\"),\n\t\t\tDependencyVmGroupName: clusterVmGroup1.Name,\n\t\t\tVmGroupName: clusterVmGroup2.Name,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.ComputeClusterVmGroup;\nimport com.pulumi.vsphere.ComputeClusterVmGroupArgs;\nimport com.pulumi.vsphere.ComputeClusterVmDependencyRule;\nimport com.pulumi.vsphere.ComputeClusterVmDependencyRuleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var cluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"network1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vm1 = new VirtualMachine(\"vm1\", VirtualMachineArgs.builder()\n .name(\"test1\")\n .resourcePoolId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(2048)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var vm2 = new VirtualMachine(\"vm2\", VirtualMachineArgs.builder()\n .name(\"test2\")\n .resourcePoolId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(2048)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var clusterVmGroup1 = new ComputeClusterVmGroup(\"clusterVmGroup1\", ComputeClusterVmGroupArgs.builder()\n .name(\"test-cluster-vm-group1\")\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .virtualMachineIds(vm1.id())\n .build());\n\n var clusterVmGroup2 = new ComputeClusterVmGroup(\"clusterVmGroup2\", ComputeClusterVmGroupArgs.builder()\n .name(\"test-cluster-vm-group2\")\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .virtualMachineIds(vm2.id())\n .build());\n\n var clusterVmDependencyRule = new ComputeClusterVmDependencyRule(\"clusterVmDependencyRule\", ComputeClusterVmDependencyRuleArgs.builder()\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .name(\"test-cluster-vm-dependency-rule\")\n .dependencyVmGroupName(clusterVmGroup1.name())\n .vmGroupName(clusterVmGroup2.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vm1:\n type: vsphere:VirtualMachine\n properties:\n name: test1\n resourcePoolId: ${cluster.resourcePoolId}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 2048\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n vm2:\n type: vsphere:VirtualMachine\n properties:\n name: test2\n resourcePoolId: ${cluster.resourcePoolId}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 2048\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n clusterVmGroup1:\n type: vsphere:ComputeClusterVmGroup\n name: cluster_vm_group1\n properties:\n name: test-cluster-vm-group1\n computeClusterId: ${cluster.id}\n virtualMachineIds:\n - ${vm1.id}\n clusterVmGroup2:\n type: vsphere:ComputeClusterVmGroup\n name: cluster_vm_group2\n properties:\n name: test-cluster-vm-group2\n computeClusterId: ${cluster.id}\n virtualMachineIds:\n - ${vm2.id}\n clusterVmDependencyRule:\n type: vsphere:ComputeClusterVmDependencyRule\n name: cluster_vm_dependency_rule\n properties:\n computeClusterId: ${cluster.id}\n name: test-cluster-vm-dependency-rule\n dependencyVmGroupName: ${clusterVmGroup1.name}\n vmGroupName: ${clusterVmGroup2.name}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n datastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: datastore1\n datacenterId: ${datacenter.id}\n cluster:\n fn::invoke:\n function: vsphere:getComputeCluster\n arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n function: vsphere:getNetwork\n arguments:\n name: network1\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing rule can be imported into this resource by supplying\n\nboth the path to the cluster, and the name the rule. If the name or cluster is\n\nnot found, or if the rule is of a different type, an error will be returned. An\n\nexample is below:\n\n```sh\n$ pulumi import vsphere:index/computeClusterVmDependencyRule:ComputeClusterVmDependencyRule cluster_vm_dependency_rule \\\n```\n\n '{\"compute_cluster_path\": \"/dc1/host/cluster1\", \\\n\n \"name\": \"pulumi-test-cluster-vm-dependency-rule\"}'\n\n", "properties": { "computeClusterId": { "type": "string", @@ -3446,7 +3446,7 @@ } }, "vsphere:index/contentLibrary:ContentLibrary": { - "description": "The `vsphere.ContentLibrary` resource can be used to manage content libraries.\n\n\u003e **NOTE:** This resource requires a vCenter Server instance and is not available on direct ESXi host connections.\n\n## Example Usage\n\nThe following example creates a publishing content library using the datastore named `publisher-datastore` as the storage backing.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenterA = vsphere.getDatacenter({\n name: \"dc-01-a\",\n});\nconst publisherDatastore = datacenterA.then(datacenterA =\u003e vsphere.getDatastore({\n name: \"publisher-datastore\",\n datacenterId: datacenterA.id,\n}));\nconst publisherContentLibrary = new vsphere.ContentLibrary(\"publisher_content_library\", {\n name: \"Publisher Content Library\",\n description: \"A publishing content library.\",\n storageBackings: [publisherDatastore.then(publisherDatastore =\u003e publisherDatastore.id)],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter_a = vsphere.get_datacenter(name=\"dc-01-a\")\npublisher_datastore = vsphere.get_datastore(name=\"publisher-datastore\",\n datacenter_id=datacenter_a.id)\npublisher_content_library = vsphere.ContentLibrary(\"publisher_content_library\",\n name=\"Publisher Content Library\",\n description=\"A publishing content library.\",\n storage_backings=[publisher_datastore.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenterA = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01-a\",\n });\n\n var publisherDatastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"publisher-datastore\",\n DatacenterId = datacenterA.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var publisherContentLibrary = new VSphere.ContentLibrary(\"publisher_content_library\", new()\n {\n Name = \"Publisher Content Library\",\n Description = \"A publishing content library.\",\n StorageBackings = new[]\n {\n publisherDatastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenterA, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01-a\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpublisherDatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"publisher-datastore\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterA.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibrary(ctx, \"publisher_content_library\", \u0026vsphere.ContentLibraryArgs{\n\t\t\tName: pulumi.String(\"Publisher Content Library\"),\n\t\t\tDescription: pulumi.String(\"A publishing content library.\"),\n\t\t\tStorageBackings: pulumi.StringArray{\n\t\t\t\tpulumi.String(publisherDatastore.Id),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.ContentLibrary;\nimport com.pulumi.vsphere.ContentLibraryArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenterA = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01-a\")\n .build());\n\n final var publisherDatastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"publisher-datastore\")\n .datacenterId(datacenterA.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var publisherContentLibrary = new ContentLibrary(\"publisherContentLibrary\", ContentLibraryArgs.builder()\n .name(\"Publisher Content Library\")\n .description(\"A publishing content library.\")\n .storageBackings(publisherDatastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n publisherContentLibrary:\n type: vsphere:ContentLibrary\n name: publisher_content_library\n properties:\n name: Publisher Content Library\n description: A publishing content library.\n storageBackings:\n - ${publisherDatastore.id}\nvariables:\n datacenterA:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01-a\n publisherDatastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: publisher-datastore\n datacenterId: ${datacenterA.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe next example creates a subscribed content library using the URL of the publisher content library as the source and the datastore named `subscriber-datastore` as the storage backing.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenterB = vsphere.getDatacenter({\n name: \"dc-01-b\",\n});\nconst subscriberDatastore = datacenterB.then(datacenterB =\u003e vsphere.getDatastore({\n name: \"subscriber-datastore\",\n datacenterId: datacenterB.id,\n}));\nconst subscriberContentLibrary = new vsphere.ContentLibrary(\"subscriber_content_library\", {\n name: \"Subscriber Content Library\",\n description: \"A subscribing content library.\",\n storageBackings: [subscriberDatastore.then(subscriberDatastore =\u003e subscriberDatastore.id)],\n subscription: {\n subscriptionUrl: \"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\",\n automaticSync: true,\n onDemand: false,\n },\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter_b = vsphere.get_datacenter(name=\"dc-01-b\")\nsubscriber_datastore = vsphere.get_datastore(name=\"subscriber-datastore\",\n datacenter_id=datacenter_b.id)\nsubscriber_content_library = vsphere.ContentLibrary(\"subscriber_content_library\",\n name=\"Subscriber Content Library\",\n description=\"A subscribing content library.\",\n storage_backings=[subscriber_datastore.id],\n subscription={\n \"subscription_url\": \"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\",\n \"automatic_sync\": True,\n \"on_demand\": False,\n })\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenterB = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01-b\",\n });\n\n var subscriberDatastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"subscriber-datastore\",\n DatacenterId = datacenterB.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var subscriberContentLibrary = new VSphere.ContentLibrary(\"subscriber_content_library\", new()\n {\n Name = \"Subscriber Content Library\",\n Description = \"A subscribing content library.\",\n StorageBackings = new[]\n {\n subscriberDatastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n },\n Subscription = new VSphere.Inputs.ContentLibrarySubscriptionArgs\n {\n SubscriptionUrl = \"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\",\n AutomaticSync = true,\n OnDemand = false,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenterB, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01-b\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tsubscriberDatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"subscriber-datastore\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterB.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibrary(ctx, \"subscriber_content_library\", \u0026vsphere.ContentLibraryArgs{\n\t\t\tName: pulumi.String(\"Subscriber Content Library\"),\n\t\t\tDescription: pulumi.String(\"A subscribing content library.\"),\n\t\t\tStorageBackings: pulumi.StringArray{\n\t\t\t\tpulumi.String(subscriberDatastore.Id),\n\t\t\t},\n\t\t\tSubscription: \u0026vsphere.ContentLibrarySubscriptionArgs{\n\t\t\t\tSubscriptionUrl: pulumi.String(\"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\"),\n\t\t\t\tAutomaticSync: pulumi.Bool(true),\n\t\t\t\tOnDemand: pulumi.Bool(false),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.ContentLibrary;\nimport com.pulumi.vsphere.ContentLibraryArgs;\nimport com.pulumi.vsphere.inputs.ContentLibrarySubscriptionArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenterB = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01-b\")\n .build());\n\n final var subscriberDatastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"subscriber-datastore\")\n .datacenterId(datacenterB.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var subscriberContentLibrary = new ContentLibrary(\"subscriberContentLibrary\", ContentLibraryArgs.builder()\n .name(\"Subscriber Content Library\")\n .description(\"A subscribing content library.\")\n .storageBackings(subscriberDatastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .subscription(ContentLibrarySubscriptionArgs.builder()\n .subscriptionUrl(\"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\")\n .automaticSync(true)\n .onDemand(false)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n subscriberContentLibrary:\n type: vsphere:ContentLibrary\n name: subscriber_content_library\n properties:\n name: Subscriber Content Library\n description: A subscribing content library.\n storageBackings:\n - ${subscriberDatastore.id}\n subscription:\n subscriptionUrl: https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\n automaticSync: true\n onDemand: false\nvariables:\n datacenterB:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01-b\n subscriberDatastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: subscriber-datastore\n datacenterId: ${datacenterB.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing content library can be imported into this resource by supplying the content library ID. For example:\n\n```sh\n$ pulumi import vsphere:index/contentLibrary:ContentLibrary vsphere_content_library publisher_content_library f42a4b25-844a-44ec-9063-a3a5e9cc88c7\n```\n\n", + "description": "The `vsphere.ContentLibrary` resource can be used to manage content libraries.\n\n\u003e **NOTE:** This resource requires a vCenter Server instance and is not available on direct ESXi host connections.\n\n## Example Usage\n\nThe following example creates a publishing content library using the datastore named `publisher-datastore` as the storage backing.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenterA = vsphere.getDatacenter({\n name: \"dc-01-a\",\n});\nconst publisherDatastore = datacenterA.then(datacenterA =\u003e vsphere.getDatastore({\n name: \"publisher-datastore\",\n datacenterId: datacenterA.id,\n}));\nconst publisherContentLibrary = new vsphere.ContentLibrary(\"publisher_content_library\", {\n name: \"Publisher Content Library\",\n description: \"A publishing content library.\",\n storageBackings: [publisherDatastore.then(publisherDatastore =\u003e publisherDatastore.id)],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter_a = vsphere.get_datacenter(name=\"dc-01-a\")\npublisher_datastore = vsphere.get_datastore(name=\"publisher-datastore\",\n datacenter_id=datacenter_a.id)\npublisher_content_library = vsphere.ContentLibrary(\"publisher_content_library\",\n name=\"Publisher Content Library\",\n description=\"A publishing content library.\",\n storage_backings=[publisher_datastore.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenterA = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01-a\",\n });\n\n var publisherDatastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"publisher-datastore\",\n DatacenterId = datacenterA.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var publisherContentLibrary = new VSphere.ContentLibrary(\"publisher_content_library\", new()\n {\n Name = \"Publisher Content Library\",\n Description = \"A publishing content library.\",\n StorageBackings = new[]\n {\n publisherDatastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenterA, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01-a\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpublisherDatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"publisher-datastore\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterA.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibrary(ctx, \"publisher_content_library\", \u0026vsphere.ContentLibraryArgs{\n\t\t\tName: pulumi.String(\"Publisher Content Library\"),\n\t\t\tDescription: pulumi.String(\"A publishing content library.\"),\n\t\t\tStorageBackings: pulumi.StringArray{\n\t\t\t\tpulumi.String(publisherDatastore.Id),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.ContentLibrary;\nimport com.pulumi.vsphere.ContentLibraryArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenterA = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01-a\")\n .build());\n\n final var publisherDatastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"publisher-datastore\")\n .datacenterId(datacenterA.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var publisherContentLibrary = new ContentLibrary(\"publisherContentLibrary\", ContentLibraryArgs.builder()\n .name(\"Publisher Content Library\")\n .description(\"A publishing content library.\")\n .storageBackings(publisherDatastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n publisherContentLibrary:\n type: vsphere:ContentLibrary\n name: publisher_content_library\n properties:\n name: Publisher Content Library\n description: A publishing content library.\n storageBackings:\n - ${publisherDatastore.id}\nvariables:\n datacenterA:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01-a\n publisherDatastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: publisher-datastore\n datacenterId: ${datacenterA.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe next example creates a subscribed content library using the URL of the publisher content library as the source and the datastore named `subscriber-datastore` as the storage backing.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenterB = vsphere.getDatacenter({\n name: \"dc-01-b\",\n});\nconst subscriberDatastore = datacenterB.then(datacenterB =\u003e vsphere.getDatastore({\n name: \"subscriber-datastore\",\n datacenterId: datacenterB.id,\n}));\nconst subscriberContentLibrary = new vsphere.ContentLibrary(\"subscriber_content_library\", {\n name: \"Subscriber Content Library\",\n description: \"A subscribing content library.\",\n storageBackings: [subscriberDatastore.then(subscriberDatastore =\u003e subscriberDatastore.id)],\n subscription: {\n subscriptionUrl: \"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\",\n automaticSync: true,\n onDemand: false,\n },\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter_b = vsphere.get_datacenter(name=\"dc-01-b\")\nsubscriber_datastore = vsphere.get_datastore(name=\"subscriber-datastore\",\n datacenter_id=datacenter_b.id)\nsubscriber_content_library = vsphere.ContentLibrary(\"subscriber_content_library\",\n name=\"Subscriber Content Library\",\n description=\"A subscribing content library.\",\n storage_backings=[subscriber_datastore.id],\n subscription={\n \"subscription_url\": \"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\",\n \"automatic_sync\": True,\n \"on_demand\": False,\n })\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenterB = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01-b\",\n });\n\n var subscriberDatastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"subscriber-datastore\",\n DatacenterId = datacenterB.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var subscriberContentLibrary = new VSphere.ContentLibrary(\"subscriber_content_library\", new()\n {\n Name = \"Subscriber Content Library\",\n Description = \"A subscribing content library.\",\n StorageBackings = new[]\n {\n subscriberDatastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n },\n Subscription = new VSphere.Inputs.ContentLibrarySubscriptionArgs\n {\n SubscriptionUrl = \"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\",\n AutomaticSync = true,\n OnDemand = false,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenterB, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01-b\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tsubscriberDatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"subscriber-datastore\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterB.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibrary(ctx, \"subscriber_content_library\", \u0026vsphere.ContentLibraryArgs{\n\t\t\tName: pulumi.String(\"Subscriber Content Library\"),\n\t\t\tDescription: pulumi.String(\"A subscribing content library.\"),\n\t\t\tStorageBackings: pulumi.StringArray{\n\t\t\t\tpulumi.String(subscriberDatastore.Id),\n\t\t\t},\n\t\t\tSubscription: \u0026vsphere.ContentLibrarySubscriptionArgs{\n\t\t\t\tSubscriptionUrl: pulumi.String(\"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\"),\n\t\t\t\tAutomaticSync: pulumi.Bool(true),\n\t\t\t\tOnDemand: pulumi.Bool(false),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.ContentLibrary;\nimport com.pulumi.vsphere.ContentLibraryArgs;\nimport com.pulumi.vsphere.inputs.ContentLibrarySubscriptionArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenterB = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01-b\")\n .build());\n\n final var subscriberDatastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"subscriber-datastore\")\n .datacenterId(datacenterB.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var subscriberContentLibrary = new ContentLibrary(\"subscriberContentLibrary\", ContentLibraryArgs.builder()\n .name(\"Subscriber Content Library\")\n .description(\"A subscribing content library.\")\n .storageBackings(subscriberDatastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .subscription(ContentLibrarySubscriptionArgs.builder()\n .subscriptionUrl(\"https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\")\n .automaticSync(true)\n .onDemand(false)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n subscriberContentLibrary:\n type: vsphere:ContentLibrary\n name: subscriber_content_library\n properties:\n name: Subscriber Content Library\n description: A subscribing content library.\n storageBackings:\n - ${subscriberDatastore.id}\n subscription:\n subscriptionUrl: https://vc-01-a.example.com:443/cls/vcsp/lib/f42a4b25-844a-44ec-9063-a3a5e9cc88c7/lib.json\n automaticSync: true\n onDemand: false\nvariables:\n datacenterB:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01-b\n subscriberDatastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: subscriber-datastore\n datacenterId: ${datacenterB.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing content library can be imported into this resource by supplying the content library ID. For example:\n\n```sh\n$ pulumi import vsphere:index/contentLibrary:ContentLibrary vsphere_content_library publisher_content_library f42a4b25-844a-44ec-9063-a3a5e9cc88c7\n```\n\n", "properties": { "description": { "type": "string", @@ -3546,7 +3546,7 @@ } }, "vsphere:index/contentLibraryItem:ContentLibraryItem": { - "description": "The `vsphere.ContentLibraryItem` resource can be used to create items in a\nvSphere content library. The `file_url` must be accessible from the vSphere\nenvironment as it will be downloaded from the specified location and stored\non the content library's storage backing.\n\n## Example Usage\n\nThe first example below imports an OVF Template to a content\nlibrary.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"clb-01\",\n});\nconst contentLibraryItem = new vsphere.ContentLibraryItem(\"content_library_item\", {\n name: \"ovf-linux-ubuntu-server-lts\",\n description: \"Ubuntu Server LTS OVF Template\",\n fileUrl: \"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\",\n libraryId: contentLibrary.then(contentLibrary =\u003e contentLibrary.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncontent_library = vsphere.get_content_library(name=\"clb-01\")\ncontent_library_item = vsphere.ContentLibraryItem(\"content_library_item\",\n name=\"ovf-linux-ubuntu-server-lts\",\n description=\"Ubuntu Server LTS OVF Template\",\n file_url=\"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\",\n library_id=content_library.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"clb-01\",\n });\n\n var contentLibraryItem = new VSphere.ContentLibraryItem(\"content_library_item\", new()\n {\n Name = \"ovf-linux-ubuntu-server-lts\",\n Description = \"Ubuntu Server LTS OVF Template\",\n FileUrl = \"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\",\n LibraryId = contentLibrary.Apply(getContentLibraryResult =\u003e getContentLibraryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcontentLibrary, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"clb-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibraryItem(ctx, \"content_library_item\", \u0026vsphere.ContentLibraryItemArgs{\n\t\t\tName: pulumi.String(\"ovf-linux-ubuntu-server-lts\"),\n\t\t\tDescription: pulumi.String(\"Ubuntu Server LTS OVF Template\"),\n\t\t\tFileUrl: pulumi.String(\"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\"),\n\t\t\tLibraryId: pulumi.String(contentLibrary.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport com.pulumi.vsphere.ContentLibraryItem;\nimport com.pulumi.vsphere.ContentLibraryItemArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"clb-01\")\n .build());\n\n var contentLibraryItem = new ContentLibraryItem(\"contentLibraryItem\", ContentLibraryItemArgs.builder()\n .name(\"ovf-linux-ubuntu-server-lts\")\n .description(\"Ubuntu Server LTS OVF Template\")\n .fileUrl(\"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\")\n .libraryId(contentLibrary.applyValue(getContentLibraryResult -\u003e getContentLibraryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n contentLibraryItem:\n type: vsphere:ContentLibraryItem\n name: content_library_item\n properties:\n name: ovf-linux-ubuntu-server-lts\n description: Ubuntu Server LTS OVF Template\n fileUrl: https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\n libraryId: ${contentLibrary.id}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n contentLibrary:\n fn::invoke:\n Function: vsphere:getContentLibrary\n Arguments:\n name: clb-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe next example imports an .iso image to a content library.\n\n[tf-vsphere-vm-resource]: /docs/providers/vsphere/r/virtual_machine.html\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"clb-01\",\n});\nconst contentLibraryItem = new vsphere.ContentLibraryItem(\"content_library_item\", {\n name: \"iso-linux-ubuntu-server-lts\",\n description: \"Ubuntu Server LTS .iso\",\n type: \"iso\",\n fileUrl: \"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\",\n libraryId: contentLibrary.then(contentLibrary =\u003e contentLibrary.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncontent_library = vsphere.get_content_library(name=\"clb-01\")\ncontent_library_item = vsphere.ContentLibraryItem(\"content_library_item\",\n name=\"iso-linux-ubuntu-server-lts\",\n description=\"Ubuntu Server LTS .iso\",\n type=\"iso\",\n file_url=\"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\",\n library_id=content_library.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"clb-01\",\n });\n\n var contentLibraryItem = new VSphere.ContentLibraryItem(\"content_library_item\", new()\n {\n Name = \"iso-linux-ubuntu-server-lts\",\n Description = \"Ubuntu Server LTS .iso\",\n Type = \"iso\",\n FileUrl = \"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\",\n LibraryId = contentLibrary.Apply(getContentLibraryResult =\u003e getContentLibraryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcontentLibrary, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"clb-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibraryItem(ctx, \"content_library_item\", \u0026vsphere.ContentLibraryItemArgs{\n\t\t\tName: pulumi.String(\"iso-linux-ubuntu-server-lts\"),\n\t\t\tDescription: pulumi.String(\"Ubuntu Server LTS .iso\"),\n\t\t\tType: pulumi.String(\"iso\"),\n\t\t\tFileUrl: pulumi.String(\"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\"),\n\t\t\tLibraryId: pulumi.String(contentLibrary.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport com.pulumi.vsphere.ContentLibraryItem;\nimport com.pulumi.vsphere.ContentLibraryItemArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"clb-01\")\n .build());\n\n var contentLibraryItem = new ContentLibraryItem(\"contentLibraryItem\", ContentLibraryItemArgs.builder()\n .name(\"iso-linux-ubuntu-server-lts\")\n .description(\"Ubuntu Server LTS .iso\")\n .type(\"iso\")\n .fileUrl(\"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\")\n .libraryId(contentLibrary.applyValue(getContentLibraryResult -\u003e getContentLibraryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n contentLibraryItem:\n type: vsphere:ContentLibraryItem\n name: content_library_item\n properties:\n name: iso-linux-ubuntu-server-lts\n description: Ubuntu Server LTS .iso\n type: iso\n fileUrl: https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\n libraryId: ${contentLibrary.id}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n contentLibrary:\n fn::invoke:\n Function: vsphere:getContentLibrary\n Arguments:\n name: clb-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe last example imports a virtual machine image to a content library from an\nexisting virtual machine.\n\n[tf-vsphere-vm-resource]: /docs/providers/vsphere/r/virtual_machine.html\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"clb-01\",\n});\nconst contentLibraryItem = new vsphere.ContentLibraryItem(\"content_library_item\", {\n name: \"tpl-linux-ubuntu-server-lts\",\n description: \"Ubuntu Server LTS\",\n sourceUuid: \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\",\n libraryId: contentLibrary.then(contentLibrary =\u003e contentLibrary.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncontent_library = vsphere.get_content_library(name=\"clb-01\")\ncontent_library_item = vsphere.ContentLibraryItem(\"content_library_item\",\n name=\"tpl-linux-ubuntu-server-lts\",\n description=\"Ubuntu Server LTS\",\n source_uuid=\"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\",\n library_id=content_library.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"clb-01\",\n });\n\n var contentLibraryItem = new VSphere.ContentLibraryItem(\"content_library_item\", new()\n {\n Name = \"tpl-linux-ubuntu-server-lts\",\n Description = \"Ubuntu Server LTS\",\n SourceUuid = \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\",\n LibraryId = contentLibrary.Apply(getContentLibraryResult =\u003e getContentLibraryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcontentLibrary, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"clb-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibraryItem(ctx, \"content_library_item\", \u0026vsphere.ContentLibraryItemArgs{\n\t\t\tName: pulumi.String(\"tpl-linux-ubuntu-server-lts\"),\n\t\t\tDescription: pulumi.String(\"Ubuntu Server LTS\"),\n\t\t\tSourceUuid: pulumi.String(\"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\"),\n\t\t\tLibraryId: pulumi.String(contentLibrary.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport com.pulumi.vsphere.ContentLibraryItem;\nimport com.pulumi.vsphere.ContentLibraryItemArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"clb-01\")\n .build());\n\n var contentLibraryItem = new ContentLibraryItem(\"contentLibraryItem\", ContentLibraryItemArgs.builder()\n .name(\"tpl-linux-ubuntu-server-lts\")\n .description(\"Ubuntu Server LTS\")\n .sourceUuid(\"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\")\n .libraryId(contentLibrary.applyValue(getContentLibraryResult -\u003e getContentLibraryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n contentLibraryItem:\n type: vsphere:ContentLibraryItem\n name: content_library_item\n properties:\n name: tpl-linux-ubuntu-server-lts\n description: Ubuntu Server LTS\n sourceUuid: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\n libraryId: ${contentLibrary.id}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n contentLibrary:\n fn::invoke:\n Function: vsphere:getContentLibrary\n Arguments:\n name: clb-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing content library item can be imported into this resource by\n\nsupplying the content library ID. An example is below:\n\n```sh\n$ pulumi import vsphere:index/contentLibraryItem:ContentLibraryItem vsphere_content_library_item iso-linux-ubuntu-server-lts xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\n```\n\n", + "description": "The `vsphere.ContentLibraryItem` resource can be used to create items in a\nvSphere content library. The `file_url` must be accessible from the vSphere\nenvironment as it will be downloaded from the specified location and stored\non the content library's storage backing.\n\n## Example Usage\n\nThe first example below imports an OVF Template to a content\nlibrary.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"clb-01\",\n});\nconst contentLibraryItem = new vsphere.ContentLibraryItem(\"content_library_item\", {\n name: \"ovf-linux-ubuntu-server-lts\",\n description: \"Ubuntu Server LTS OVF Template\",\n fileUrl: \"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\",\n libraryId: contentLibrary.then(contentLibrary =\u003e contentLibrary.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncontent_library = vsphere.get_content_library(name=\"clb-01\")\ncontent_library_item = vsphere.ContentLibraryItem(\"content_library_item\",\n name=\"ovf-linux-ubuntu-server-lts\",\n description=\"Ubuntu Server LTS OVF Template\",\n file_url=\"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\",\n library_id=content_library.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"clb-01\",\n });\n\n var contentLibraryItem = new VSphere.ContentLibraryItem(\"content_library_item\", new()\n {\n Name = \"ovf-linux-ubuntu-server-lts\",\n Description = \"Ubuntu Server LTS OVF Template\",\n FileUrl = \"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\",\n LibraryId = contentLibrary.Apply(getContentLibraryResult =\u003e getContentLibraryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcontentLibrary, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"clb-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibraryItem(ctx, \"content_library_item\", \u0026vsphere.ContentLibraryItemArgs{\n\t\t\tName: pulumi.String(\"ovf-linux-ubuntu-server-lts\"),\n\t\t\tDescription: pulumi.String(\"Ubuntu Server LTS OVF Template\"),\n\t\t\tFileUrl: pulumi.String(\"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\"),\n\t\t\tLibraryId: pulumi.String(contentLibrary.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport com.pulumi.vsphere.ContentLibraryItem;\nimport com.pulumi.vsphere.ContentLibraryItemArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"clb-01\")\n .build());\n\n var contentLibraryItem = new ContentLibraryItem(\"contentLibraryItem\", ContentLibraryItemArgs.builder()\n .name(\"ovf-linux-ubuntu-server-lts\")\n .description(\"Ubuntu Server LTS OVF Template\")\n .fileUrl(\"https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\")\n .libraryId(contentLibrary.applyValue(getContentLibraryResult -\u003e getContentLibraryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n contentLibraryItem:\n type: vsphere:ContentLibraryItem\n name: content_library_item\n properties:\n name: ovf-linux-ubuntu-server-lts\n description: Ubuntu Server LTS OVF Template\n fileUrl: https://releases.example.com/ubuntu/ubuntu/ubuntu-live-server-amd64.ovf\n libraryId: ${contentLibrary.id}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n contentLibrary:\n fn::invoke:\n function: vsphere:getContentLibrary\n arguments:\n name: clb-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe next example imports an .iso image to a content library.\n\n[tf-vsphere-vm-resource]: /docs/providers/vsphere/r/virtual_machine.html\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"clb-01\",\n});\nconst contentLibraryItem = new vsphere.ContentLibraryItem(\"content_library_item\", {\n name: \"iso-linux-ubuntu-server-lts\",\n description: \"Ubuntu Server LTS .iso\",\n type: \"iso\",\n fileUrl: \"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\",\n libraryId: contentLibrary.then(contentLibrary =\u003e contentLibrary.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncontent_library = vsphere.get_content_library(name=\"clb-01\")\ncontent_library_item = vsphere.ContentLibraryItem(\"content_library_item\",\n name=\"iso-linux-ubuntu-server-lts\",\n description=\"Ubuntu Server LTS .iso\",\n type=\"iso\",\n file_url=\"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\",\n library_id=content_library.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"clb-01\",\n });\n\n var contentLibraryItem = new VSphere.ContentLibraryItem(\"content_library_item\", new()\n {\n Name = \"iso-linux-ubuntu-server-lts\",\n Description = \"Ubuntu Server LTS .iso\",\n Type = \"iso\",\n FileUrl = \"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\",\n LibraryId = contentLibrary.Apply(getContentLibraryResult =\u003e getContentLibraryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcontentLibrary, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"clb-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibraryItem(ctx, \"content_library_item\", \u0026vsphere.ContentLibraryItemArgs{\n\t\t\tName: pulumi.String(\"iso-linux-ubuntu-server-lts\"),\n\t\t\tDescription: pulumi.String(\"Ubuntu Server LTS .iso\"),\n\t\t\tType: pulumi.String(\"iso\"),\n\t\t\tFileUrl: pulumi.String(\"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\"),\n\t\t\tLibraryId: pulumi.String(contentLibrary.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport com.pulumi.vsphere.ContentLibraryItem;\nimport com.pulumi.vsphere.ContentLibraryItemArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"clb-01\")\n .build());\n\n var contentLibraryItem = new ContentLibraryItem(\"contentLibraryItem\", ContentLibraryItemArgs.builder()\n .name(\"iso-linux-ubuntu-server-lts\")\n .description(\"Ubuntu Server LTS .iso\")\n .type(\"iso\")\n .fileUrl(\"https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\")\n .libraryId(contentLibrary.applyValue(getContentLibraryResult -\u003e getContentLibraryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n contentLibraryItem:\n type: vsphere:ContentLibraryItem\n name: content_library_item\n properties:\n name: iso-linux-ubuntu-server-lts\n description: Ubuntu Server LTS .iso\n type: iso\n fileUrl: https://releases.example.com/ubuntu/ubuntu-live-server-amd64.iso\n libraryId: ${contentLibrary.id}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n contentLibrary:\n fn::invoke:\n function: vsphere:getContentLibrary\n arguments:\n name: clb-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe last example imports a virtual machine image to a content library from an\nexisting virtual machine.\n\n[tf-vsphere-vm-resource]: /docs/providers/vsphere/r/virtual_machine.html\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"clb-01\",\n});\nconst contentLibraryItem = new vsphere.ContentLibraryItem(\"content_library_item\", {\n name: \"tpl-linux-ubuntu-server-lts\",\n description: \"Ubuntu Server LTS\",\n sourceUuid: \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\",\n libraryId: contentLibrary.then(contentLibrary =\u003e contentLibrary.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncontent_library = vsphere.get_content_library(name=\"clb-01\")\ncontent_library_item = vsphere.ContentLibraryItem(\"content_library_item\",\n name=\"tpl-linux-ubuntu-server-lts\",\n description=\"Ubuntu Server LTS\",\n source_uuid=\"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\",\n library_id=content_library.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"clb-01\",\n });\n\n var contentLibraryItem = new VSphere.ContentLibraryItem(\"content_library_item\", new()\n {\n Name = \"tpl-linux-ubuntu-server-lts\",\n Description = \"Ubuntu Server LTS\",\n SourceUuid = \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\",\n LibraryId = contentLibrary.Apply(getContentLibraryResult =\u003e getContentLibraryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcontentLibrary, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"clb-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewContentLibraryItem(ctx, \"content_library_item\", \u0026vsphere.ContentLibraryItemArgs{\n\t\t\tName: pulumi.String(\"tpl-linux-ubuntu-server-lts\"),\n\t\t\tDescription: pulumi.String(\"Ubuntu Server LTS\"),\n\t\t\tSourceUuid: pulumi.String(\"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\"),\n\t\t\tLibraryId: pulumi.String(contentLibrary.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport com.pulumi.vsphere.ContentLibraryItem;\nimport com.pulumi.vsphere.ContentLibraryItemArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"clb-01\")\n .build());\n\n var contentLibraryItem = new ContentLibraryItem(\"contentLibraryItem\", ContentLibraryItemArgs.builder()\n .name(\"tpl-linux-ubuntu-server-lts\")\n .description(\"Ubuntu Server LTS\")\n .sourceUuid(\"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\")\n .libraryId(contentLibrary.applyValue(getContentLibraryResult -\u003e getContentLibraryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n contentLibraryItem:\n type: vsphere:ContentLibraryItem\n name: content_library_item\n properties:\n name: tpl-linux-ubuntu-server-lts\n description: Ubuntu Server LTS\n sourceUuid: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\n libraryId: ${contentLibrary.id}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n contentLibrary:\n fn::invoke:\n function: vsphere:getContentLibrary\n arguments:\n name: clb-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing content library item can be imported into this resource by\n\nsupplying the content library ID. An example is below:\n\n```sh\n$ pulumi import vsphere:index/contentLibraryItem:ContentLibraryItem vsphere_content_library_item iso-linux-ubuntu-server-lts xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\n```\n\n", "properties": { "description": { "type": "string", @@ -6522,7 +6522,7 @@ } }, "vsphere:index/folder:Folder": { - "description": "The `vsphere.Folder` resource can be used to manage vSphere inventory folders.\nThe resource supports creating folders of the 5 major types - datacenter\nfolders, host and cluster folders, virtual machine folders, storage folders,\nand network folders.\n\nPaths are always relative to the specific type of folder you are creating.\nA subfolder is discovered by parsing the relative path specified in `path`, so\n`foo/bar` will create a folder named `bar` in the parent folder `foo`, as long\nas that folder exists.\n\n## Example Usage\n\nThe basic example below creates a virtual machine folder named\n`test-folder` in the default datacenter's VM hierarchy. \n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({});\nconst folder = new vsphere.Folder(\"folder\", {\n path: \"test-folder\",\n type: \"vm\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter()\nfolder = vsphere.Folder(\"folder\",\n path=\"test-folder\",\n type=\"vm\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke();\n\n var folder = new VSphere.Folder(\"folder\", new()\n {\n Path = \"test-folder\",\n Type = \"vm\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewFolder(ctx, \"folder\", \u0026vsphere.FolderArgs{\n\t\t\tPath: pulumi.String(\"test-folder\"),\n\t\t\tType: pulumi.String(\"vm\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.Folder;\nimport com.pulumi.vsphere.FolderArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter();\n\n var folder = new Folder(\"folder\", FolderArgs.builder()\n .path(\"test-folder\")\n .type(\"vm\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n folder:\n type: vsphere:Folder\n properties:\n path: test-folder\n type: vm\n datacenterId: ${datacenter.id}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Example with subfolders\n\nThe below example builds off of the above by first creating a folder named\n`test-parent`, and then locating `test-folder` in that\nfolder. To ensure the parent is created first, we create an interpolation\ndependency off the parent's `path` attribute.\n\nNote that if you change parents (for example, went from the above basic\nconfiguration to this one), your folder will be moved to be under the correct\nparent.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({});\nconst parent = new vsphere.Folder(\"parent\", {\n path: \"test-parent\",\n type: \"vm\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n});\nconst folder = new vsphere.Folder(\"folder\", {\n path: pulumi.interpolate`${parent.path}/test-folder`,\n type: \"vm\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter()\nparent = vsphere.Folder(\"parent\",\n path=\"test-parent\",\n type=\"vm\",\n datacenter_id=datacenter.id)\nfolder = vsphere.Folder(\"folder\",\n path=parent.path.apply(lambda path: f\"{path}/test-folder\"),\n type=\"vm\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke();\n\n var parent = new VSphere.Folder(\"parent\", new()\n {\n Path = \"test-parent\",\n Type = \"vm\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var folder = new VSphere.Folder(\"folder\", new()\n {\n Path = parent.Path.Apply(path =\u003e $\"{path}/test-folder\"),\n Type = \"vm\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"fmt\"\n\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tparent, err := vsphere.NewFolder(ctx, \"parent\", \u0026vsphere.FolderArgs{\n\t\t\tPath: pulumi.String(\"test-parent\"),\n\t\t\tType: pulumi.String(\"vm\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewFolder(ctx, \"folder\", \u0026vsphere.FolderArgs{\n\t\t\tPath: parent.Path.ApplyT(func(path string) (string, error) {\n\t\t\t\treturn fmt.Sprintf(\"%v/test-folder\", path), nil\n\t\t\t}).(pulumi.StringOutput),\n\t\t\tType: pulumi.String(\"vm\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.Folder;\nimport com.pulumi.vsphere.FolderArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter();\n\n var parent = new Folder(\"parent\", FolderArgs.builder()\n .path(\"test-parent\")\n .type(\"vm\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var folder = new Folder(\"folder\", FolderArgs.builder()\n .path(parent.path().applyValue(path -\u003e String.format(\"%s/test-folder\", path)))\n .type(\"vm\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n parent:\n type: vsphere:Folder\n properties:\n path: test-parent\n type: vm\n datacenterId: ${datacenter.id}\n folder:\n type: vsphere:Folder\n properties:\n path: ${parent.path}/test-folder\n type: vm\n datacenterId: ${datacenter.id}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing folder can be imported into this resource via\n\nits full path, via the following command:\n\n```sh\n$ pulumi import vsphere:index/folder:Folder folder /default-dc/vm/terraform-test-folder\n```\n\nThe above command would import the folder from our examples above, the VM\n\nfolder named `terraform-test-folder` located in the datacenter named\n\n`default-dc`.\n\n", + "description": "The `vsphere.Folder` resource can be used to manage vSphere inventory folders.\nThe resource supports creating folders of the 5 major types - datacenter\nfolders, host and cluster folders, virtual machine folders, storage folders,\nand network folders.\n\nPaths are always relative to the specific type of folder you are creating.\nA subfolder is discovered by parsing the relative path specified in `path`, so\n`foo/bar` will create a folder named `bar` in the parent folder `foo`, as long\nas that folder exists.\n\n## Example Usage\n\nThe basic example below creates a virtual machine folder named\n`test-folder` in the default datacenter's VM hierarchy. \n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({});\nconst folder = new vsphere.Folder(\"folder\", {\n path: \"test-folder\",\n type: \"vm\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter()\nfolder = vsphere.Folder(\"folder\",\n path=\"test-folder\",\n type=\"vm\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke();\n\n var folder = new VSphere.Folder(\"folder\", new()\n {\n Path = \"test-folder\",\n Type = \"vm\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewFolder(ctx, \"folder\", \u0026vsphere.FolderArgs{\n\t\t\tPath: pulumi.String(\"test-folder\"),\n\t\t\tType: pulumi.String(\"vm\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.Folder;\nimport com.pulumi.vsphere.FolderArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter();\n\n var folder = new Folder(\"folder\", FolderArgs.builder()\n .path(\"test-folder\")\n .type(\"vm\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n folder:\n type: vsphere:Folder\n properties:\n path: test-folder\n type: vm\n datacenterId: ${datacenter.id}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Example with subfolders\n\nThe below example builds off of the above by first creating a folder named\n`test-parent`, and then locating `test-folder` in that\nfolder. To ensure the parent is created first, we create an interpolation\ndependency off the parent's `path` attribute.\n\nNote that if you change parents (for example, went from the above basic\nconfiguration to this one), your folder will be moved to be under the correct\nparent.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({});\nconst parent = new vsphere.Folder(\"parent\", {\n path: \"test-parent\",\n type: \"vm\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n});\nconst folder = new vsphere.Folder(\"folder\", {\n path: pulumi.interpolate`${parent.path}/test-folder`,\n type: \"vm\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter()\nparent = vsphere.Folder(\"parent\",\n path=\"test-parent\",\n type=\"vm\",\n datacenter_id=datacenter.id)\nfolder = vsphere.Folder(\"folder\",\n path=parent.path.apply(lambda path: f\"{path}/test-folder\"),\n type=\"vm\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke();\n\n var parent = new VSphere.Folder(\"parent\", new()\n {\n Path = \"test-parent\",\n Type = \"vm\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var folder = new VSphere.Folder(\"folder\", new()\n {\n Path = parent.Path.Apply(path =\u003e $\"{path}/test-folder\"),\n Type = \"vm\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"fmt\"\n\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tparent, err := vsphere.NewFolder(ctx, \"parent\", \u0026vsphere.FolderArgs{\n\t\t\tPath: pulumi.String(\"test-parent\"),\n\t\t\tType: pulumi.String(\"vm\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewFolder(ctx, \"folder\", \u0026vsphere.FolderArgs{\n\t\t\tPath: parent.Path.ApplyT(func(path string) (string, error) {\n\t\t\t\treturn fmt.Sprintf(\"%v/test-folder\", path), nil\n\t\t\t}).(pulumi.StringOutput),\n\t\t\tType: pulumi.String(\"vm\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.Folder;\nimport com.pulumi.vsphere.FolderArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter();\n\n var parent = new Folder(\"parent\", FolderArgs.builder()\n .path(\"test-parent\")\n .type(\"vm\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var folder = new Folder(\"folder\", FolderArgs.builder()\n .path(parent.path().applyValue(path -\u003e String.format(\"%s/test-folder\", path)))\n .type(\"vm\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n parent:\n type: vsphere:Folder\n properties:\n path: test-parent\n type: vm\n datacenterId: ${datacenter.id}\n folder:\n type: vsphere:Folder\n properties:\n path: ${parent.path}/test-folder\n type: vm\n datacenterId: ${datacenter.id}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing folder can be imported into this resource via\n\nits full path, via the following command:\n\n```sh\n$ pulumi import vsphere:index/folder:Folder folder /default-dc/vm/terraform-test-folder\n```\n\nThe above command would import the folder from our examples above, the VM\n\nfolder named `terraform-test-folder` located in the datacenter named\n\n`default-dc`.\n\n", "properties": { "customAttributes": { "type": "object", @@ -6713,7 +6713,7 @@ } }, "vsphere:index/haVmOverride:HaVmOverride": { - "description": "The `vsphere.HaVmOverride` resource can be used to add an override for\nvSphere HA settings on a cluster for a specific virtual machine. With this\nresource, one can control specific HA settings so that they are different than\nthe cluster default, accommodating the needs of that specific virtual machine,\nwhile not affecting the rest of the cluster.\n\nFor more information on vSphere HA, see [this page][ref-vsphere-ha-clusters].\n\n[ref-vsphere-ha-clusters]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-availability/GUID-5432CA24-14F1-44E3-87FB-61D937831CF6.html\n\n\u003e **NOTE:** This resource requires vCenter and is not available on direct ESXi\nconnections.\n\n## Example Usage\n\nThe example below creates a virtual machine in a cluster using the\n`vsphere.VirtualMachine` resource, creating the\nvirtual machine in the cluster looked up by the\n`vsphere.ComputeCluster` data source.\n\nConsidering a scenario where this virtual machine is of high value to the\napplication or organization for which it does its work, it's been determined in\nthe event of a host failure, that this should be one of the first virtual\nmachines to be started by vSphere HA during recovery. Hence, it\n`ha_vm_restart_priority` has been set to `highest`,\nwhich, assuming that the default restart priority is `medium` and no other\nvirtual machine has been assigned the `highest` priority, will mean that this\nVM will be started before any other virtual machine in the event of host\nfailure.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore1\",\n datacenterId: datacenter.id,\n}));\nconst cluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"network1\",\n datacenterId: datacenter.id,\n}));\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"test\",\n resourcePoolId: cluster.then(cluster =\u003e cluster.resourcePoolId),\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 2048,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst haVmOverride = new vsphere.HaVmOverride(\"ha_vm_override\", {\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n virtualMachineId: vm.id,\n haVmRestartPriority: \"highest\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datastore(name=\"datastore1\",\n datacenter_id=datacenter.id)\ncluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"network1\",\n datacenter_id=datacenter.id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"test\",\n resource_pool_id=cluster.resource_pool_id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=2048,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\nha_vm_override = vsphere.HaVmOverride(\"ha_vm_override\",\n compute_cluster_id=cluster.id,\n virtual_machine_id=vm.id,\n ha_vm_restart_priority=\"highest\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var cluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"network1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"test\",\n ResourcePoolId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 2048,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var haVmOverride = new VSphere.HaVmOverride(\"ha_vm_override\", new()\n {\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n VirtualMachineId = vm.Id,\n HaVmRestartPriority = \"highest\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"network1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm, err := vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tResourcePoolId: pulumi.String(cluster.ResourcePoolId),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(2048),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHaVmOverride(ctx, \"ha_vm_override\", \u0026vsphere.HaVmOverrideArgs{\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tVirtualMachineId: vm.ID(),\n\t\t\tHaVmRestartPriority: pulumi.String(\"highest\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.HaVmOverride;\nimport com.pulumi.vsphere.HaVmOverrideArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var cluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"network1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"test\")\n .resourcePoolId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(2048)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var haVmOverride = new HaVmOverride(\"haVmOverride\", HaVmOverrideArgs.builder()\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .virtualMachineId(vm.id())\n .haVmRestartPriority(\"highest\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: test\n resourcePoolId: ${cluster.resourcePoolId}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 2048\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n haVmOverride:\n type: vsphere:HaVmOverride\n name: ha_vm_override\n properties:\n computeClusterId: ${cluster.id}\n virtualMachineId: ${vm.id}\n haVmRestartPriority: highest\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n datastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: datastore1\n datacenterId: ${datacenter.id}\n cluster:\n fn::invoke:\n Function: vsphere:getComputeCluster\n Arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n Function: vsphere:getNetwork\n Arguments:\n name: network1\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing override can be imported into this resource by\n\nsupplying both the path to the cluster, and the path to the virtual machine, to\n\n`pulumi import`. If no override exists, an error will be given. An example\n\nis below:\n\n```sh\n$ pulumi import vsphere:index/haVmOverride:HaVmOverride ha_vm_override \\\n```\n\n '{\"compute_cluster_path\": \"/dc1/host/cluster1\", \\\n\n \"virtual_machine_path\": \"/dc1/vm/srv1\"}'\n\n", + "description": "The `vsphere.HaVmOverride` resource can be used to add an override for\nvSphere HA settings on a cluster for a specific virtual machine. With this\nresource, one can control specific HA settings so that they are different than\nthe cluster default, accommodating the needs of that specific virtual machine,\nwhile not affecting the rest of the cluster.\n\nFor more information on vSphere HA, see [this page][ref-vsphere-ha-clusters].\n\n[ref-vsphere-ha-clusters]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-availability/GUID-5432CA24-14F1-44E3-87FB-61D937831CF6.html\n\n\u003e **NOTE:** This resource requires vCenter and is not available on direct ESXi\nconnections.\n\n## Example Usage\n\nThe example below creates a virtual machine in a cluster using the\n`vsphere.VirtualMachine` resource, creating the\nvirtual machine in the cluster looked up by the\n`vsphere.ComputeCluster` data source.\n\nConsidering a scenario where this virtual machine is of high value to the\napplication or organization for which it does its work, it's been determined in\nthe event of a host failure, that this should be one of the first virtual\nmachines to be started by vSphere HA during recovery. Hence, it\n`ha_vm_restart_priority` has been set to `highest`,\nwhich, assuming that the default restart priority is `medium` and no other\nvirtual machine has been assigned the `highest` priority, will mean that this\nVM will be started before any other virtual machine in the event of host\nfailure.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore1\",\n datacenterId: datacenter.id,\n}));\nconst cluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"network1\",\n datacenterId: datacenter.id,\n}));\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"test\",\n resourcePoolId: cluster.then(cluster =\u003e cluster.resourcePoolId),\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 2048,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst haVmOverride = new vsphere.HaVmOverride(\"ha_vm_override\", {\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n virtualMachineId: vm.id,\n haVmRestartPriority: \"highest\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datastore(name=\"datastore1\",\n datacenter_id=datacenter.id)\ncluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"network1\",\n datacenter_id=datacenter.id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"test\",\n resource_pool_id=cluster.resource_pool_id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=2048,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\nha_vm_override = vsphere.HaVmOverride(\"ha_vm_override\",\n compute_cluster_id=cluster.id,\n virtual_machine_id=vm.id,\n ha_vm_restart_priority=\"highest\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var cluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"network1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"test\",\n ResourcePoolId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 2048,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var haVmOverride = new VSphere.HaVmOverride(\"ha_vm_override\", new()\n {\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n VirtualMachineId = vm.Id,\n HaVmRestartPriority = \"highest\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"network1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm, err := vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tResourcePoolId: pulumi.String(cluster.ResourcePoolId),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(2048),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHaVmOverride(ctx, \"ha_vm_override\", \u0026vsphere.HaVmOverrideArgs{\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tVirtualMachineId: vm.ID(),\n\t\t\tHaVmRestartPriority: pulumi.String(\"highest\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.HaVmOverride;\nimport com.pulumi.vsphere.HaVmOverrideArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var cluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"network1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"test\")\n .resourcePoolId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(2048)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var haVmOverride = new HaVmOverride(\"haVmOverride\", HaVmOverrideArgs.builder()\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .virtualMachineId(vm.id())\n .haVmRestartPriority(\"highest\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: test\n resourcePoolId: ${cluster.resourcePoolId}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 2048\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n haVmOverride:\n type: vsphere:HaVmOverride\n name: ha_vm_override\n properties:\n computeClusterId: ${cluster.id}\n virtualMachineId: ${vm.id}\n haVmRestartPriority: highest\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n datastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: datastore1\n datacenterId: ${datacenter.id}\n cluster:\n fn::invoke:\n function: vsphere:getComputeCluster\n arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n function: vsphere:getNetwork\n arguments:\n name: network1\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing override can be imported into this resource by\n\nsupplying both the path to the cluster, and the path to the virtual machine, to\n\n`pulumi import`. If no override exists, an error will be given. An example\n\nis below:\n\n```sh\n$ pulumi import vsphere:index/haVmOverride:HaVmOverride ha_vm_override \\\n```\n\n '{\"compute_cluster_path\": \"/dc1/host/cluster1\", \\\n\n \"virtual_machine_path\": \"/dc1/vm/srv1\"}'\n\n", "properties": { "computeClusterId": { "type": "string", @@ -6918,7 +6918,7 @@ } }, "vsphere:index/host:Host": { - "description": "Provides a VMware vSphere host resource. This represents an ESXi host that\ncan be used either as a member of a cluster or as a standalone host.\n\n## Example Usage\n\n### Create a standalone host\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst thumbprint = vsphere.getHostThumbprint({\n address: \"esxi-01.example.com\",\n insecure: true,\n});\nconst esx_01 = new vsphere.Host(\"esx-01\", {\n hostname: \"esxi-01.example.com\",\n username: \"root\",\n password: \"password\",\n license: \"00000-00000-00000-00000-00000\",\n thumbprint: thumbprint.then(thumbprint =\u003e thumbprint.id),\n datacenter: datacenter.then(datacenter =\u003e datacenter.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nthumbprint = vsphere.get_host_thumbprint(address=\"esxi-01.example.com\",\n insecure=True)\nesx_01 = vsphere.Host(\"esx-01\",\n hostname=\"esxi-01.example.com\",\n username=\"root\",\n password=\"password\",\n license=\"00000-00000-00000-00000-00000\",\n thumbprint=thumbprint.id,\n datacenter=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var thumbprint = VSphere.GetHostThumbprint.Invoke(new()\n {\n Address = \"esxi-01.example.com\",\n Insecure = true,\n });\n\n var esx_01 = new VSphere.Host(\"esx-01\", new()\n {\n Hostname = \"esxi-01.example.com\",\n Username = \"root\",\n Password = \"password\",\n License = \"00000-00000-00000-00000-00000\",\n Thumbprint = thumbprint.Apply(getHostThumbprintResult =\u003e getHostThumbprintResult.Id),\n Datacenter = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tthumbprint, err := vsphere.GetHostThumbprint(ctx, \u0026vsphere.GetHostThumbprintArgs{\n\t\t\tAddress: \"esxi-01.example.com\",\n\t\t\tInsecure: pulumi.BoolRef(true),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHost(ctx, \"esx-01\", \u0026vsphere.HostArgs{\n\t\t\tHostname: pulumi.String(\"esxi-01.example.com\"),\n\t\t\tUsername: pulumi.String(\"root\"),\n\t\t\tPassword: pulumi.String(\"password\"),\n\t\t\tLicense: pulumi.String(\"00000-00000-00000-00000-00000\"),\n\t\t\tThumbprint: pulumi.String(thumbprint.Id),\n\t\t\tDatacenter: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostThumbprintArgs;\nimport com.pulumi.vsphere.Host;\nimport com.pulumi.vsphere.HostArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var thumbprint = VsphereFunctions.getHostThumbprint(GetHostThumbprintArgs.builder()\n .address(\"esxi-01.example.com\")\n .insecure(true)\n .build());\n\n var esx_01 = new Host(\"esx-01\", HostArgs.builder()\n .hostname(\"esxi-01.example.com\")\n .username(\"root\")\n .password(\"password\")\n .license(\"00000-00000-00000-00000-00000\")\n .thumbprint(thumbprint.applyValue(getHostThumbprintResult -\u003e getHostThumbprintResult.id()))\n .datacenter(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n esx-01:\n type: vsphere:Host\n properties:\n hostname: esxi-01.example.com\n username: root\n password: password\n license: 00000-00000-00000-00000-00000\n thumbprint: ${thumbprint.id}\n datacenter: ${datacenter.id}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n thumbprint:\n fn::invoke:\n Function: vsphere:getHostThumbprint\n Arguments:\n address: esxi-01.example.com\n insecure: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing host can be imported into this resource by supplying\n\nthe host's ID.\n\n[docs-import]: /docs/import/index.html\n\nObtain the host's ID using the data source. For example:\n\nhcl\n\ndata \"vsphere_datacenter\" \"datacenter\" {\n\n name = \"dc-01\"\n\n}\n\ndata \"vsphere_host\" \"host\" {\n\n name = \"esxi-01.example.com\"\n\n datacenter_id = data.vsphere_datacenter.datacenter.id\n\n}\n\noutput \"host_id\" {\n\n value = data.vsphere_host.host.id\n\n}\n\nNext, create a resource configuration, For example:\n\nhcl\n\ndata \"vsphere_datacenter\" \"datacenter\" {\n\n name = \"dc-01\"\n\n}\n\ndata \"vsphere_host_thumbprint\" \"thumbprint\" {\n\n address = \"esxi-01.example.com\"\n\n insecure = true\n\n}\n\nresource \"vsphere_host\" \"esx-01\" {\n\n hostname = \"esxi-01.example.com\"\n\n username = \"root\"\n\n password = \"password\"\n\n thumbprint = data.vsphere_host_thumbprint.thumbprint.id\n\n datacenter = data.vsphere_datacenter.datacenter.id\n\n}\n\nhcl\n\nresource \"vsphere_host\" \"esx-01\" {\n\n hostname = \"esxi-01.example.com\"\n\n username = \"root\"\n\n password = \"password\"\n\n license = \"00000-00000-00000-00000-00000\"\n\n thumbprint = data.vsphere_host_thumbprint.thumbprint.id\n\n cluster = data.vsphere_compute_cluster.cluster.id\n\n services {\n\n ntpd {\n\n enabled = true\n\n policy = \"on\"\n\n ntp_servers = [\"pool.ntp.org\"]\n\n }\n\n}\n\nconsole\n\n```sh\n$ pulumi import vsphere:index/host:Host esx-01 host-123\n```\n\nThe above would import the host `esxi-01.example.com` with the host ID `host-123`.\n\n", + "description": "Provides a VMware vSphere host resource. This represents an ESXi host that\ncan be used either as a member of a cluster or as a standalone host.\n\n## Example Usage\n\n### Create a standalone host\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst thumbprint = vsphere.getHostThumbprint({\n address: \"esxi-01.example.com\",\n insecure: true,\n});\nconst esx_01 = new vsphere.Host(\"esx-01\", {\n hostname: \"esxi-01.example.com\",\n username: \"root\",\n password: \"password\",\n license: \"00000-00000-00000-00000-00000\",\n thumbprint: thumbprint.then(thumbprint =\u003e thumbprint.id),\n datacenter: datacenter.then(datacenter =\u003e datacenter.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nthumbprint = vsphere.get_host_thumbprint(address=\"esxi-01.example.com\",\n insecure=True)\nesx_01 = vsphere.Host(\"esx-01\",\n hostname=\"esxi-01.example.com\",\n username=\"root\",\n password=\"password\",\n license=\"00000-00000-00000-00000-00000\",\n thumbprint=thumbprint.id,\n datacenter=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var thumbprint = VSphere.GetHostThumbprint.Invoke(new()\n {\n Address = \"esxi-01.example.com\",\n Insecure = true,\n });\n\n var esx_01 = new VSphere.Host(\"esx-01\", new()\n {\n Hostname = \"esxi-01.example.com\",\n Username = \"root\",\n Password = \"password\",\n License = \"00000-00000-00000-00000-00000\",\n Thumbprint = thumbprint.Apply(getHostThumbprintResult =\u003e getHostThumbprintResult.Id),\n Datacenter = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tthumbprint, err := vsphere.GetHostThumbprint(ctx, \u0026vsphere.GetHostThumbprintArgs{\n\t\t\tAddress: \"esxi-01.example.com\",\n\t\t\tInsecure: pulumi.BoolRef(true),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHost(ctx, \"esx-01\", \u0026vsphere.HostArgs{\n\t\t\tHostname: pulumi.String(\"esxi-01.example.com\"),\n\t\t\tUsername: pulumi.String(\"root\"),\n\t\t\tPassword: pulumi.String(\"password\"),\n\t\t\tLicense: pulumi.String(\"00000-00000-00000-00000-00000\"),\n\t\t\tThumbprint: pulumi.String(thumbprint.Id),\n\t\t\tDatacenter: pulumi.String(datacenter.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostThumbprintArgs;\nimport com.pulumi.vsphere.Host;\nimport com.pulumi.vsphere.HostArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var thumbprint = VsphereFunctions.getHostThumbprint(GetHostThumbprintArgs.builder()\n .address(\"esxi-01.example.com\")\n .insecure(true)\n .build());\n\n var esx_01 = new Host(\"esx-01\", HostArgs.builder()\n .hostname(\"esxi-01.example.com\")\n .username(\"root\")\n .password(\"password\")\n .license(\"00000-00000-00000-00000-00000\")\n .thumbprint(thumbprint.applyValue(getHostThumbprintResult -\u003e getHostThumbprintResult.id()))\n .datacenter(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n esx-01:\n type: vsphere:Host\n properties:\n hostname: esxi-01.example.com\n username: root\n password: password\n license: 00000-00000-00000-00000-00000\n thumbprint: ${thumbprint.id}\n datacenter: ${datacenter.id}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n thumbprint:\n fn::invoke:\n function: vsphere:getHostThumbprint\n arguments:\n address: esxi-01.example.com\n insecure: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing host can be imported into this resource by supplying\n\nthe host's ID.\n\n[docs-import]: /docs/import/index.html\n\nObtain the host's ID using the data source. For example:\n\nhcl\n\ndata \"vsphere_datacenter\" \"datacenter\" {\n\n name = \"dc-01\"\n\n}\n\ndata \"vsphere_host\" \"host\" {\n\n name = \"esxi-01.example.com\"\n\n datacenter_id = data.vsphere_datacenter.datacenter.id\n\n}\n\noutput \"host_id\" {\n\n value = data.vsphere_host.host.id\n\n}\n\nNext, create a resource configuration, For example:\n\nhcl\n\ndata \"vsphere_datacenter\" \"datacenter\" {\n\n name = \"dc-01\"\n\n}\n\ndata \"vsphere_host_thumbprint\" \"thumbprint\" {\n\n address = \"esxi-01.example.com\"\n\n insecure = true\n\n}\n\nresource \"vsphere_host\" \"esx-01\" {\n\n hostname = \"esxi-01.example.com\"\n\n username = \"root\"\n\n password = \"password\"\n\n thumbprint = data.vsphere_host_thumbprint.thumbprint.id\n\n datacenter = data.vsphere_datacenter.datacenter.id\n\n}\n\nhcl\n\nresource \"vsphere_host\" \"esx-01\" {\n\n hostname = \"esxi-01.example.com\"\n\n username = \"root\"\n\n password = \"password\"\n\n license = \"00000-00000-00000-00000-00000\"\n\n thumbprint = data.vsphere_host_thumbprint.thumbprint.id\n\n cluster = data.vsphere_compute_cluster.cluster.id\n\n services {\n\n ntpd {\n\n enabled = true\n\n policy = \"on\"\n\n ntp_servers = [\"pool.ntp.org\"]\n\n }\n\n}\n\nconsole\n\n```sh\n$ pulumi import vsphere:index/host:Host esx-01 host-123\n```\n\nThe above would import the host `esxi-01.example.com` with the host ID `host-123`.\n\n", "properties": { "cluster": { "type": "string", @@ -7151,7 +7151,7 @@ } }, "vsphere:index/hostPortGroup:HostPortGroup": { - "description": "The `vsphere.HostPortGroup` resource can be used to manage port groups on\nESXi hosts. These port groups are connected to standard switches, which\ncan be managed by the `vsphere.HostVirtualSwitch`\nresource.\n\nFor an overview on vSphere networking concepts, see [the product documentation][ref-vsphere-net-concepts].\n\n[ref-vsphere-net-concepts]: https://docs.vmware.com/en/VMware-vSphere/7.0/com.vmware.vsphere.networking.doc/GUID-2B11DBB8-CB3C-4AFF-8885-EFEA0FC562F4.html\n\n## Example Usage\n\n**Create a Virtual Switch and Bind a Port Group:**\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst hostVirtualSwitch = new vsphere.HostVirtualSwitch(\"host_virtual_switch\", {\n name: \"switch-01\",\n hostSystemId: host.then(host =\u003e host.id),\n networkAdapters: [\n \"vmnic0\",\n \"vmnic1\",\n ],\n activeNics: [\"vmnic0\"],\n standbyNics: [\"vmnic1\"],\n});\nconst pg = new vsphere.HostPortGroup(\"pg\", {\n name: \"portgroup-01\",\n hostSystemId: host.then(host =\u003e host.id),\n virtualSwitchName: hostVirtualSwitch.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nhost_virtual_switch = vsphere.HostVirtualSwitch(\"host_virtual_switch\",\n name=\"switch-01\",\n host_system_id=host.id,\n network_adapters=[\n \"vmnic0\",\n \"vmnic1\",\n ],\n active_nics=[\"vmnic0\"],\n standby_nics=[\"vmnic1\"])\npg = vsphere.HostPortGroup(\"pg\",\n name=\"portgroup-01\",\n host_system_id=host.id,\n virtual_switch_name=host_virtual_switch.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hostVirtualSwitch = new VSphere.HostVirtualSwitch(\"host_virtual_switch\", new()\n {\n Name = \"switch-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NetworkAdapters = new[]\n {\n \"vmnic0\",\n \"vmnic1\",\n },\n ActiveNics = new[]\n {\n \"vmnic0\",\n },\n StandbyNics = new[]\n {\n \"vmnic1\",\n },\n });\n\n var pg = new VSphere.HostPortGroup(\"pg\", new()\n {\n Name = \"portgroup-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n VirtualSwitchName = hostVirtualSwitch.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thostVirtualSwitch, err := vsphere.NewHostVirtualSwitch(ctx, \"host_virtual_switch\", \u0026vsphere.HostVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"switch-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tNetworkAdapters: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t\tActiveNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t},\n\t\t\tStandbyNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHostPortGroup(ctx, \"pg\", \u0026vsphere.HostPortGroupArgs{\n\t\t\tName: pulumi.String(\"portgroup-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tVirtualSwitchName: hostVirtualSwitch.Name,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.HostVirtualSwitch;\nimport com.pulumi.vsphere.HostVirtualSwitchArgs;\nimport com.pulumi.vsphere.HostPortGroup;\nimport com.pulumi.vsphere.HostPortGroupArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var hostVirtualSwitch = new HostVirtualSwitch(\"hostVirtualSwitch\", HostVirtualSwitchArgs.builder()\n .name(\"switch-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .networkAdapters( \n \"vmnic0\",\n \"vmnic1\")\n .activeNics(\"vmnic0\")\n .standbyNics(\"vmnic1\")\n .build());\n\n var pg = new HostPortGroup(\"pg\", HostPortGroupArgs.builder()\n .name(\"portgroup-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .virtualSwitchName(hostVirtualSwitch.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hostVirtualSwitch:\n type: vsphere:HostVirtualSwitch\n name: host_virtual_switch\n properties:\n name: switch-01\n hostSystemId: ${host.id}\n networkAdapters:\n - vmnic0\n - vmnic1\n activeNics:\n - vmnic0\n standbyNics:\n - vmnic1\n pg:\n type: vsphere:HostPortGroup\n properties:\n name: portgroup-01\n hostSystemId: ${host.id}\n virtualSwitchName: ${hostVirtualSwitch.name}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n**Create a Port Group with a VLAN and ab Override:**\n\nThis example sets the trunk mode VLAN (`4095`, which passes through all tags)\nand sets\n`allow_promiscuous`\nto ensure that all traffic is seen on the port. The setting overrides\nthe implicit default of `false` set on the standard switch.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst hostVirtualSwitch = new vsphere.HostVirtualSwitch(\"host_virtual_switch\", {\n name: \"switch-01\",\n hostSystemId: host.then(host =\u003e host.id),\n networkAdapters: [\n \"vmnic0\",\n \"vmnic1\",\n ],\n activeNics: [\"vmnic0\"],\n standbyNics: [\"vmnic1\"],\n});\nconst pg = new vsphere.HostPortGroup(\"pg\", {\n name: \"portgroup-01\",\n hostSystemId: host.then(host =\u003e host.id),\n virtualSwitchName: hostVirtualSwitch.name,\n vlanId: 4095,\n allowPromiscuous: true,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nhost_virtual_switch = vsphere.HostVirtualSwitch(\"host_virtual_switch\",\n name=\"switch-01\",\n host_system_id=host.id,\n network_adapters=[\n \"vmnic0\",\n \"vmnic1\",\n ],\n active_nics=[\"vmnic0\"],\n standby_nics=[\"vmnic1\"])\npg = vsphere.HostPortGroup(\"pg\",\n name=\"portgroup-01\",\n host_system_id=host.id,\n virtual_switch_name=host_virtual_switch.name,\n vlan_id=4095,\n allow_promiscuous=True)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hostVirtualSwitch = new VSphere.HostVirtualSwitch(\"host_virtual_switch\", new()\n {\n Name = \"switch-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NetworkAdapters = new[]\n {\n \"vmnic0\",\n \"vmnic1\",\n },\n ActiveNics = new[]\n {\n \"vmnic0\",\n },\n StandbyNics = new[]\n {\n \"vmnic1\",\n },\n });\n\n var pg = new VSphere.HostPortGroup(\"pg\", new()\n {\n Name = \"portgroup-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n VirtualSwitchName = hostVirtualSwitch.Name,\n VlanId = 4095,\n AllowPromiscuous = true,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thostVirtualSwitch, err := vsphere.NewHostVirtualSwitch(ctx, \"host_virtual_switch\", \u0026vsphere.HostVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"switch-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tNetworkAdapters: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t\tActiveNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t},\n\t\t\tStandbyNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHostPortGroup(ctx, \"pg\", \u0026vsphere.HostPortGroupArgs{\n\t\t\tName: pulumi.String(\"portgroup-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tVirtualSwitchName: hostVirtualSwitch.Name,\n\t\t\tVlanId: pulumi.Int(4095),\n\t\t\tAllowPromiscuous: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.HostVirtualSwitch;\nimport com.pulumi.vsphere.HostVirtualSwitchArgs;\nimport com.pulumi.vsphere.HostPortGroup;\nimport com.pulumi.vsphere.HostPortGroupArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var hostVirtualSwitch = new HostVirtualSwitch(\"hostVirtualSwitch\", HostVirtualSwitchArgs.builder()\n .name(\"switch-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .networkAdapters( \n \"vmnic0\",\n \"vmnic1\")\n .activeNics(\"vmnic0\")\n .standbyNics(\"vmnic1\")\n .build());\n\n var pg = new HostPortGroup(\"pg\", HostPortGroupArgs.builder()\n .name(\"portgroup-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .virtualSwitchName(hostVirtualSwitch.name())\n .vlanId(4095)\n .allowPromiscuous(true)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hostVirtualSwitch:\n type: vsphere:HostVirtualSwitch\n name: host_virtual_switch\n properties:\n name: switch-01\n hostSystemId: ${host.id}\n networkAdapters:\n - vmnic0\n - vmnic1\n activeNics:\n - vmnic0\n standbyNics:\n - vmnic1\n pg:\n type: vsphere:HostPortGroup\n properties:\n name: portgroup-01\n hostSystemId: ${host.id}\n virtualSwitchName: ${hostVirtualSwitch.name}\n vlanId: 4095\n allowPromiscuous: true\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing host port group can be imported into this resource\n\nusing the host port group's ID. An example is below:\n\n```sh\n$ pulumi import vsphere:index/hostPortGroup:HostPortGroup management tf-HostPortGroup:host-123:management\n```\n\nThe above would import the `management` host port group from host with ID `host-123`.\n\n", + "description": "The `vsphere.HostPortGroup` resource can be used to manage port groups on\nESXi hosts. These port groups are connected to standard switches, which\ncan be managed by the `vsphere.HostVirtualSwitch`\nresource.\n\nFor an overview on vSphere networking concepts, see [the product documentation][ref-vsphere-net-concepts].\n\n[ref-vsphere-net-concepts]: https://docs.vmware.com/en/VMware-vSphere/7.0/com.vmware.vsphere.networking.doc/GUID-2B11DBB8-CB3C-4AFF-8885-EFEA0FC562F4.html\n\n## Example Usage\n\n**Create a Virtual Switch and Bind a Port Group:**\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst hostVirtualSwitch = new vsphere.HostVirtualSwitch(\"host_virtual_switch\", {\n name: \"switch-01\",\n hostSystemId: host.then(host =\u003e host.id),\n networkAdapters: [\n \"vmnic0\",\n \"vmnic1\",\n ],\n activeNics: [\"vmnic0\"],\n standbyNics: [\"vmnic1\"],\n});\nconst pg = new vsphere.HostPortGroup(\"pg\", {\n name: \"portgroup-01\",\n hostSystemId: host.then(host =\u003e host.id),\n virtualSwitchName: hostVirtualSwitch.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nhost_virtual_switch = vsphere.HostVirtualSwitch(\"host_virtual_switch\",\n name=\"switch-01\",\n host_system_id=host.id,\n network_adapters=[\n \"vmnic0\",\n \"vmnic1\",\n ],\n active_nics=[\"vmnic0\"],\n standby_nics=[\"vmnic1\"])\npg = vsphere.HostPortGroup(\"pg\",\n name=\"portgroup-01\",\n host_system_id=host.id,\n virtual_switch_name=host_virtual_switch.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hostVirtualSwitch = new VSphere.HostVirtualSwitch(\"host_virtual_switch\", new()\n {\n Name = \"switch-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NetworkAdapters = new[]\n {\n \"vmnic0\",\n \"vmnic1\",\n },\n ActiveNics = new[]\n {\n \"vmnic0\",\n },\n StandbyNics = new[]\n {\n \"vmnic1\",\n },\n });\n\n var pg = new VSphere.HostPortGroup(\"pg\", new()\n {\n Name = \"portgroup-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n VirtualSwitchName = hostVirtualSwitch.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thostVirtualSwitch, err := vsphere.NewHostVirtualSwitch(ctx, \"host_virtual_switch\", \u0026vsphere.HostVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"switch-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tNetworkAdapters: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t\tActiveNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t},\n\t\t\tStandbyNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHostPortGroup(ctx, \"pg\", \u0026vsphere.HostPortGroupArgs{\n\t\t\tName: pulumi.String(\"portgroup-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tVirtualSwitchName: hostVirtualSwitch.Name,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.HostVirtualSwitch;\nimport com.pulumi.vsphere.HostVirtualSwitchArgs;\nimport com.pulumi.vsphere.HostPortGroup;\nimport com.pulumi.vsphere.HostPortGroupArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var hostVirtualSwitch = new HostVirtualSwitch(\"hostVirtualSwitch\", HostVirtualSwitchArgs.builder()\n .name(\"switch-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .networkAdapters( \n \"vmnic0\",\n \"vmnic1\")\n .activeNics(\"vmnic0\")\n .standbyNics(\"vmnic1\")\n .build());\n\n var pg = new HostPortGroup(\"pg\", HostPortGroupArgs.builder()\n .name(\"portgroup-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .virtualSwitchName(hostVirtualSwitch.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hostVirtualSwitch:\n type: vsphere:HostVirtualSwitch\n name: host_virtual_switch\n properties:\n name: switch-01\n hostSystemId: ${host.id}\n networkAdapters:\n - vmnic0\n - vmnic1\n activeNics:\n - vmnic0\n standbyNics:\n - vmnic1\n pg:\n type: vsphere:HostPortGroup\n properties:\n name: portgroup-01\n hostSystemId: ${host.id}\n virtualSwitchName: ${hostVirtualSwitch.name}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n**Create a Port Group with a VLAN and ab Override:**\n\nThis example sets the trunk mode VLAN (`4095`, which passes through all tags)\nand sets\n`allow_promiscuous`\nto ensure that all traffic is seen on the port. The setting overrides\nthe implicit default of `false` set on the standard switch.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst hostVirtualSwitch = new vsphere.HostVirtualSwitch(\"host_virtual_switch\", {\n name: \"switch-01\",\n hostSystemId: host.then(host =\u003e host.id),\n networkAdapters: [\n \"vmnic0\",\n \"vmnic1\",\n ],\n activeNics: [\"vmnic0\"],\n standbyNics: [\"vmnic1\"],\n});\nconst pg = new vsphere.HostPortGroup(\"pg\", {\n name: \"portgroup-01\",\n hostSystemId: host.then(host =\u003e host.id),\n virtualSwitchName: hostVirtualSwitch.name,\n vlanId: 4095,\n allowPromiscuous: true,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nhost_virtual_switch = vsphere.HostVirtualSwitch(\"host_virtual_switch\",\n name=\"switch-01\",\n host_system_id=host.id,\n network_adapters=[\n \"vmnic0\",\n \"vmnic1\",\n ],\n active_nics=[\"vmnic0\"],\n standby_nics=[\"vmnic1\"])\npg = vsphere.HostPortGroup(\"pg\",\n name=\"portgroup-01\",\n host_system_id=host.id,\n virtual_switch_name=host_virtual_switch.name,\n vlan_id=4095,\n allow_promiscuous=True)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hostVirtualSwitch = new VSphere.HostVirtualSwitch(\"host_virtual_switch\", new()\n {\n Name = \"switch-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NetworkAdapters = new[]\n {\n \"vmnic0\",\n \"vmnic1\",\n },\n ActiveNics = new[]\n {\n \"vmnic0\",\n },\n StandbyNics = new[]\n {\n \"vmnic1\",\n },\n });\n\n var pg = new VSphere.HostPortGroup(\"pg\", new()\n {\n Name = \"portgroup-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n VirtualSwitchName = hostVirtualSwitch.Name,\n VlanId = 4095,\n AllowPromiscuous = true,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thostVirtualSwitch, err := vsphere.NewHostVirtualSwitch(ctx, \"host_virtual_switch\", \u0026vsphere.HostVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"switch-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tNetworkAdapters: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t\tActiveNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic0\"),\n\t\t\t},\n\t\t\tStandbyNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic1\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewHostPortGroup(ctx, \"pg\", \u0026vsphere.HostPortGroupArgs{\n\t\t\tName: pulumi.String(\"portgroup-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tVirtualSwitchName: hostVirtualSwitch.Name,\n\t\t\tVlanId: pulumi.Int(4095),\n\t\t\tAllowPromiscuous: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.HostVirtualSwitch;\nimport com.pulumi.vsphere.HostVirtualSwitchArgs;\nimport com.pulumi.vsphere.HostPortGroup;\nimport com.pulumi.vsphere.HostPortGroupArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var hostVirtualSwitch = new HostVirtualSwitch(\"hostVirtualSwitch\", HostVirtualSwitchArgs.builder()\n .name(\"switch-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .networkAdapters( \n \"vmnic0\",\n \"vmnic1\")\n .activeNics(\"vmnic0\")\n .standbyNics(\"vmnic1\")\n .build());\n\n var pg = new HostPortGroup(\"pg\", HostPortGroupArgs.builder()\n .name(\"portgroup-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .virtualSwitchName(hostVirtualSwitch.name())\n .vlanId(4095)\n .allowPromiscuous(true)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hostVirtualSwitch:\n type: vsphere:HostVirtualSwitch\n name: host_virtual_switch\n properties:\n name: switch-01\n hostSystemId: ${host.id}\n networkAdapters:\n - vmnic0\n - vmnic1\n activeNics:\n - vmnic0\n standbyNics:\n - vmnic1\n pg:\n type: vsphere:HostPortGroup\n properties:\n name: portgroup-01\n hostSystemId: ${host.id}\n virtualSwitchName: ${hostVirtualSwitch.name}\n vlanId: 4095\n allowPromiscuous: true\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing host port group can be imported into this resource\n\nusing the host port group's ID. An example is below:\n\n```sh\n$ pulumi import vsphere:index/hostPortGroup:HostPortGroup management tf-HostPortGroup:host-123:management\n```\n\nThe above would import the `management` host port group from host with ID `host-123`.\n\n", "properties": { "activeNics": { "type": "array", @@ -8436,7 +8436,7 @@ } }, "vsphere:index/storageDrsVmOverride:StorageDrsVmOverride": { - "description": "The `vsphere.StorageDrsVmOverride` resource can be used to add a Storage DRS\noverride to a datastore cluster for a specific virtual machine. With this\nresource, one can enable or disable Storage DRS, and control the automation\nlevel and disk affinity for a single virtual machine without affecting the rest\nof the datastore cluster.\n\nFor more information on vSphere datastore clusters and Storage DRS, see [this\npage][ref-vsphere-datastore-clusters].\n\n[ref-vsphere-datastore-clusters]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-resource-management/GUID-598DF695-107E-406B-9C95-0AF961FC227A.html\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastoreCluster = datacenter.then(datacenter =\u003e vsphere.getDatastoreCluster({\n name: \"datastore-cluster1\",\n datacenterId: datacenter.id,\n}));\nconst memberDatastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore-cluster1-member1\",\n datacenterId: datacenter.id,\n}));\nconst pool = datacenter.then(datacenter =\u003e vsphere.getResourcePool({\n name: \"cluster1/Resources\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"public\",\n datacenterId: datacenter.id,\n}));\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"test\",\n resourcePoolId: pool.then(pool =\u003e pool.id),\n datastoreId: memberDatastore.then(memberDatastore =\u003e memberDatastore.id),\n numCpus: 2,\n memory: 1024,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst drsVmOverride = new vsphere.StorageDrsVmOverride(\"drs_vm_override\", {\n datastoreClusterId: datastoreCluster.then(datastoreCluster =\u003e datastoreCluster.id),\n virtualMachineId: vm.id,\n sdrsEnabled: \"false\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore_cluster = vsphere.get_datastore_cluster(name=\"datastore-cluster1\",\n datacenter_id=datacenter.id)\nmember_datastore = vsphere.get_datastore(name=\"datastore-cluster1-member1\",\n datacenter_id=datacenter.id)\npool = vsphere.get_resource_pool(name=\"cluster1/Resources\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"public\",\n datacenter_id=datacenter.id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"test\",\n resource_pool_id=pool.id,\n datastore_id=member_datastore.id,\n num_cpus=2,\n memory=1024,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\ndrs_vm_override = vsphere.StorageDrsVmOverride(\"drs_vm_override\",\n datastore_cluster_id=datastore_cluster.id,\n virtual_machine_id=vm.id,\n sdrs_enabled=\"false\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastoreCluster = VSphere.GetDatastoreCluster.Invoke(new()\n {\n Name = \"datastore-cluster1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var memberDatastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore-cluster1-member1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var pool = VSphere.GetResourcePool.Invoke(new()\n {\n Name = \"cluster1/Resources\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"public\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"test\",\n ResourcePoolId = pool.Apply(getResourcePoolResult =\u003e getResourcePoolResult.Id),\n DatastoreId = memberDatastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 1024,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var drsVmOverride = new VSphere.StorageDrsVmOverride(\"drs_vm_override\", new()\n {\n DatastoreClusterId = datastoreCluster.Apply(getDatastoreClusterResult =\u003e getDatastoreClusterResult.Id),\n VirtualMachineId = vm.Id,\n SdrsEnabled = \"false\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastoreCluster, err := vsphere.LookupDatastoreCluster(ctx, \u0026vsphere.LookupDatastoreClusterArgs{\n\t\t\tName: \"datastore-cluster1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tmemberDatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore-cluster1-member1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpool, err := vsphere.LookupResourcePool(ctx, \u0026vsphere.LookupResourcePoolArgs{\n\t\t\tName: pulumi.StringRef(\"cluster1/Resources\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"public\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm, err := vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tResourcePoolId: pulumi.String(pool.Id),\n\t\t\tDatastoreId: pulumi.String(memberDatastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(1024),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewStorageDrsVmOverride(ctx, \"drs_vm_override\", \u0026vsphere.StorageDrsVmOverrideArgs{\n\t\t\tDatastoreClusterId: pulumi.String(datastoreCluster.Id),\n\t\t\tVirtualMachineId: vm.ID(),\n\t\t\tSdrsEnabled: pulumi.String(\"false\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreClusterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetResourcePoolArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.StorageDrsVmOverride;\nimport com.pulumi.vsphere.StorageDrsVmOverrideArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastoreCluster = VsphereFunctions.getDatastoreCluster(GetDatastoreClusterArgs.builder()\n .name(\"datastore-cluster1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var memberDatastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore-cluster1-member1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var pool = VsphereFunctions.getResourcePool(GetResourcePoolArgs.builder()\n .name(\"cluster1/Resources\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"public\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"test\")\n .resourcePoolId(pool.applyValue(getResourcePoolResult -\u003e getResourcePoolResult.id()))\n .datastoreId(memberDatastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(1024)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var drsVmOverride = new StorageDrsVmOverride(\"drsVmOverride\", StorageDrsVmOverrideArgs.builder()\n .datastoreClusterId(datastoreCluster.applyValue(getDatastoreClusterResult -\u003e getDatastoreClusterResult.id()))\n .virtualMachineId(vm.id())\n .sdrsEnabled(false)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: test\n resourcePoolId: ${pool.id}\n datastoreId: ${memberDatastore.id}\n numCpus: 2\n memory: 1024\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n drsVmOverride:\n type: vsphere:StorageDrsVmOverride\n name: drs_vm_override\n properties:\n datastoreClusterId: ${datastoreCluster.id}\n virtualMachineId: ${vm.id}\n sdrsEnabled: false\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n datastoreCluster:\n fn::invoke:\n Function: vsphere:getDatastoreCluster\n Arguments:\n name: datastore-cluster1\n datacenterId: ${datacenter.id}\n memberDatastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: datastore-cluster1-member1\n datacenterId: ${datacenter.id}\n pool:\n fn::invoke:\n Function: vsphere:getResourcePool\n Arguments:\n name: cluster1/Resources\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n Function: vsphere:getNetwork\n Arguments:\n name: public\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing override can be imported into this resource by\n\nsupplying both the path to the datastore cluster and the path to the virtual\n\nmachine to `pulumi import`. If no override exists, an error will be given.\n\nAn example is below:\n\n```sh\n$ pulumi import vsphere:index/storageDrsVmOverride:StorageDrsVmOverride drs_vm_override \\\n```\n\n '{\"datastore_cluster_path\": \"/dc1/datastore/ds-cluster\", \\\n\n \"virtual_machine_path\": \"/dc1/vm/srv1\"}'\n\n", + "description": "The `vsphere.StorageDrsVmOverride` resource can be used to add a Storage DRS\noverride to a datastore cluster for a specific virtual machine. With this\nresource, one can enable or disable Storage DRS, and control the automation\nlevel and disk affinity for a single virtual machine without affecting the rest\nof the datastore cluster.\n\nFor more information on vSphere datastore clusters and Storage DRS, see [this\npage][ref-vsphere-datastore-clusters].\n\n[ref-vsphere-datastore-clusters]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-resource-management/GUID-598DF695-107E-406B-9C95-0AF961FC227A.html\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastoreCluster = datacenter.then(datacenter =\u003e vsphere.getDatastoreCluster({\n name: \"datastore-cluster1\",\n datacenterId: datacenter.id,\n}));\nconst memberDatastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore-cluster1-member1\",\n datacenterId: datacenter.id,\n}));\nconst pool = datacenter.then(datacenter =\u003e vsphere.getResourcePool({\n name: \"cluster1/Resources\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"public\",\n datacenterId: datacenter.id,\n}));\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"test\",\n resourcePoolId: pool.then(pool =\u003e pool.id),\n datastoreId: memberDatastore.then(memberDatastore =\u003e memberDatastore.id),\n numCpus: 2,\n memory: 1024,\n guestId: \"otherLinux64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\nconst drsVmOverride = new vsphere.StorageDrsVmOverride(\"drs_vm_override\", {\n datastoreClusterId: datastoreCluster.then(datastoreCluster =\u003e datastoreCluster.id),\n virtualMachineId: vm.id,\n sdrsEnabled: \"false\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore_cluster = vsphere.get_datastore_cluster(name=\"datastore-cluster1\",\n datacenter_id=datacenter.id)\nmember_datastore = vsphere.get_datastore(name=\"datastore-cluster1-member1\",\n datacenter_id=datacenter.id)\npool = vsphere.get_resource_pool(name=\"cluster1/Resources\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"public\",\n datacenter_id=datacenter.id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"test\",\n resource_pool_id=pool.id,\n datastore_id=member_datastore.id,\n num_cpus=2,\n memory=1024,\n guest_id=\"otherLinux64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\ndrs_vm_override = vsphere.StorageDrsVmOverride(\"drs_vm_override\",\n datastore_cluster_id=datastore_cluster.id,\n virtual_machine_id=vm.id,\n sdrs_enabled=\"false\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastoreCluster = VSphere.GetDatastoreCluster.Invoke(new()\n {\n Name = \"datastore-cluster1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var memberDatastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore-cluster1-member1\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var pool = VSphere.GetResourcePool.Invoke(new()\n {\n Name = \"cluster1/Resources\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"public\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"test\",\n ResourcePoolId = pool.Apply(getResourcePoolResult =\u003e getResourcePoolResult.Id),\n DatastoreId = memberDatastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 1024,\n GuestId = \"otherLinux64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n var drsVmOverride = new VSphere.StorageDrsVmOverride(\"drs_vm_override\", new()\n {\n DatastoreClusterId = datastoreCluster.Apply(getDatastoreClusterResult =\u003e getDatastoreClusterResult.Id),\n VirtualMachineId = vm.Id,\n SdrsEnabled = \"false\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastoreCluster, err := vsphere.LookupDatastoreCluster(ctx, \u0026vsphere.LookupDatastoreClusterArgs{\n\t\t\tName: \"datastore-cluster1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tmemberDatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore-cluster1-member1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpool, err := vsphere.LookupResourcePool(ctx, \u0026vsphere.LookupResourcePoolArgs{\n\t\t\tName: pulumi.StringRef(\"cluster1/Resources\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"public\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm, err := vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tResourcePoolId: pulumi.String(pool.Id),\n\t\t\tDatastoreId: pulumi.String(memberDatastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(1024),\n\t\t\tGuestId: pulumi.String(\"otherLinux64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewStorageDrsVmOverride(ctx, \"drs_vm_override\", \u0026vsphere.StorageDrsVmOverrideArgs{\n\t\t\tDatastoreClusterId: pulumi.String(datastoreCluster.Id),\n\t\t\tVirtualMachineId: vm.ID(),\n\t\t\tSdrsEnabled: pulumi.String(\"false\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreClusterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetResourcePoolArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.StorageDrsVmOverride;\nimport com.pulumi.vsphere.StorageDrsVmOverrideArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastoreCluster = VsphereFunctions.getDatastoreCluster(GetDatastoreClusterArgs.builder()\n .name(\"datastore-cluster1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var memberDatastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore-cluster1-member1\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var pool = VsphereFunctions.getResourcePool(GetResourcePoolArgs.builder()\n .name(\"cluster1/Resources\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"public\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"test\")\n .resourcePoolId(pool.applyValue(getResourcePoolResult -\u003e getResourcePoolResult.id()))\n .datastoreId(memberDatastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(1024)\n .guestId(\"otherLinux64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n var drsVmOverride = new StorageDrsVmOverride(\"drsVmOverride\", StorageDrsVmOverrideArgs.builder()\n .datastoreClusterId(datastoreCluster.applyValue(getDatastoreClusterResult -\u003e getDatastoreClusterResult.id()))\n .virtualMachineId(vm.id())\n .sdrsEnabled(false)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: test\n resourcePoolId: ${pool.id}\n datastoreId: ${memberDatastore.id}\n numCpus: 2\n memory: 1024\n guestId: otherLinux64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\n drsVmOverride:\n type: vsphere:StorageDrsVmOverride\n name: drs_vm_override\n properties:\n datastoreClusterId: ${datastoreCluster.id}\n virtualMachineId: ${vm.id}\n sdrsEnabled: false\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n datastoreCluster:\n fn::invoke:\n function: vsphere:getDatastoreCluster\n arguments:\n name: datastore-cluster1\n datacenterId: ${datacenter.id}\n memberDatastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: datastore-cluster1-member1\n datacenterId: ${datacenter.id}\n pool:\n fn::invoke:\n function: vsphere:getResourcePool\n arguments:\n name: cluster1/Resources\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n function: vsphere:getNetwork\n arguments:\n name: public\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing override can be imported into this resource by\n\nsupplying both the path to the datastore cluster and the path to the virtual\n\nmachine to `pulumi import`. If no override exists, an error will be given.\n\nAn example is below:\n\n```sh\n$ pulumi import vsphere:index/storageDrsVmOverride:StorageDrsVmOverride drs_vm_override \\\n```\n\n '{\"datastore_cluster_path\": \"/dc1/datastore/ds-cluster\", \\\n\n \"virtual_machine_path\": \"/dc1/vm/srv1\"}'\n\n", "properties": { "datastoreClusterId": { "type": "string", @@ -8937,7 +8937,7 @@ } }, "vsphere:index/vappContainer:VappContainer": { - "description": "The `vsphere.VappContainer` resource can be used to create and manage\nvApps.\n\nFor more information on vSphere vApps, see the VMware vSphere [product documentation][ref-vsphere-vapp].\n\n[ref-vsphere-vapp]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-vm-administration/GUID-E6E9D2A9-D358-4996-9BC7-F8D9D9645290.html\n\n## Basic Example\n\nThe example below sets up a vSphere vApp container in a compute cluster which uses\nthe default settings for CPU and memory reservations, shares, and limits. The compute cluster\nneeds to already exist in vSphere.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst computeCluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst vappContainer = new vsphere.VappContainer(\"vapp_container\", {\n name: \"vapp-01\",\n parentResourcePoolId: computeCluster.then(computeCluster =\u003e computeCluster.resourcePoolId),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncompute_cluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nvapp_container = vsphere.VappContainer(\"vapp_container\",\n name=\"vapp-01\",\n parent_resource_pool_id=compute_cluster.resource_pool_id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vappContainer = new VSphere.VappContainer(\"vapp_container\", new()\n {\n Name = \"vapp-01\",\n ParentResourcePoolId = computeCluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcomputeCluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVappContainer(ctx, \"vapp_container\", \u0026vsphere.VappContainerArgs{\n\t\t\tName: pulumi.String(\"vapp-01\"),\n\t\t\tParentResourcePoolId: pulumi.String(computeCluster.ResourcePoolId),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.VappContainer;\nimport com.pulumi.vsphere.VappContainerArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vappContainer = new VappContainer(\"vappContainer\", VappContainerArgs.builder()\n .name(\"vapp-01\")\n .parentResourcePoolId(computeCluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vappContainer:\n type: vsphere:VappContainer\n name: vapp_container\n properties:\n name: vapp-01\n parentResourcePoolId: ${computeCluster.resourcePoolId}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n computeCluster:\n fn::invoke:\n Function: vsphere:getComputeCluster\n Arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Example with a Virtual Machine\n\nThe example below builds off the basic example, but includes a virtual machine\nin the new vApp container. To accomplish this, the `resource_pool_id` of the\nvirtual machine is set to the `id` of the vApp container.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst computeCluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore-01\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"VM Network\",\n datacenterId: datacenter.id,\n}));\nconst vappContainer = new vsphere.VappContainer(\"vapp_container\", {\n name: \"vapp-01\",\n parentResourcePoolId: computeCluster.then(computeCluster =\u003e computeCluster.resourcePoolId),\n});\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"foo\",\n resourcePoolId: vappContainerVsphereVappContainer.id,\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 1,\n memory: 1024,\n guestId: \"ubuntu64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncompute_cluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\ndatastore = vsphere.get_datastore(name=\"datastore-01\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"VM Network\",\n datacenter_id=datacenter.id)\nvapp_container = vsphere.VappContainer(\"vapp_container\",\n name=\"vapp-01\",\n parent_resource_pool_id=compute_cluster.resource_pool_id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"foo\",\n resource_pool_id=vapp_container_vsphere_vapp_container[\"id\"],\n datastore_id=datastore.id,\n num_cpus=1,\n memory=1024,\n guest_id=\"ubuntu64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"VM Network\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vappContainer = new VSphere.VappContainer(\"vapp_container\", new()\n {\n Name = \"vapp-01\",\n ParentResourcePoolId = computeCluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"foo\",\n ResourcePoolId = vappContainerVsphereVappContainer.Id,\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 1,\n Memory = 1024,\n GuestId = \"ubuntu64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcomputeCluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"VM Network\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVappContainer(ctx, \"vapp_container\", \u0026vsphere.VappContainerArgs{\n\t\t\tName: pulumi.String(\"vapp-01\"),\n\t\t\tParentResourcePoolId: pulumi.String(computeCluster.ResourcePoolId),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"foo\"),\n\t\t\tResourcePoolId: pulumi.Any(vappContainerVsphereVappContainer.Id),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(1),\n\t\t\tMemory: pulumi.Int(1024),\n\t\t\tGuestId: pulumi.String(\"ubuntu64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VappContainer;\nimport com.pulumi.vsphere.VappContainerArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"VM Network\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vappContainer = new VappContainer(\"vappContainer\", VappContainerArgs.builder()\n .name(\"vapp-01\")\n .parentResourcePoolId(computeCluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"foo\")\n .resourcePoolId(vappContainerVsphereVappContainer.id())\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(1)\n .memory(1024)\n .guestId(\"ubuntu64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vappContainer:\n type: vsphere:VappContainer\n name: vapp_container\n properties:\n name: vapp-01\n parentResourcePoolId: ${computeCluster.resourcePoolId}\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: foo\n resourcePoolId: ${vappContainerVsphereVappContainer.id}\n datastoreId: ${datastore.id}\n numCpus: 1\n memory: 1024\n guestId: ubuntu64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n computeCluster:\n fn::invoke:\n Function: vsphere:getComputeCluster\n Arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n datastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: datastore-01\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n Function: vsphere:getNetwork\n Arguments:\n name: VM Network\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing vApp container can be imported into this resource via\n\nthe path to the vApp container, using the following command:\n\nExample:\n\n```sh\n$ pulumi import vsphere:index/vappContainer:VappContainer vapp_container /dc-01/host/cluster-01/Resources/resource-pool-01/vapp-01\n```\n\nThe example above would import the vApp container named `vapp-01` that is\n\nlocated in the resource pool `resource-pool-01` that is part of the host cluster\n\n`cluster-01` in the `dc-01` datacenter.\n\n", + "description": "The `vsphere.VappContainer` resource can be used to create and manage\nvApps.\n\nFor more information on vSphere vApps, see the VMware vSphere [product documentation][ref-vsphere-vapp].\n\n[ref-vsphere-vapp]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-vm-administration/GUID-E6E9D2A9-D358-4996-9BC7-F8D9D9645290.html\n\n## Basic Example\n\nThe example below sets up a vSphere vApp container in a compute cluster which uses\nthe default settings for CPU and memory reservations, shares, and limits. The compute cluster\nneeds to already exist in vSphere.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst computeCluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst vappContainer = new vsphere.VappContainer(\"vapp_container\", {\n name: \"vapp-01\",\n parentResourcePoolId: computeCluster.then(computeCluster =\u003e computeCluster.resourcePoolId),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncompute_cluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nvapp_container = vsphere.VappContainer(\"vapp_container\",\n name=\"vapp-01\",\n parent_resource_pool_id=compute_cluster.resource_pool_id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vappContainer = new VSphere.VappContainer(\"vapp_container\", new()\n {\n Name = \"vapp-01\",\n ParentResourcePoolId = computeCluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcomputeCluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVappContainer(ctx, \"vapp_container\", \u0026vsphere.VappContainerArgs{\n\t\t\tName: pulumi.String(\"vapp-01\"),\n\t\t\tParentResourcePoolId: pulumi.String(computeCluster.ResourcePoolId),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.VappContainer;\nimport com.pulumi.vsphere.VappContainerArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vappContainer = new VappContainer(\"vappContainer\", VappContainerArgs.builder()\n .name(\"vapp-01\")\n .parentResourcePoolId(computeCluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vappContainer:\n type: vsphere:VappContainer\n name: vapp_container\n properties:\n name: vapp-01\n parentResourcePoolId: ${computeCluster.resourcePoolId}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n computeCluster:\n fn::invoke:\n function: vsphere:getComputeCluster\n arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Example with a Virtual Machine\n\nThe example below builds off the basic example, but includes a virtual machine\nin the new vApp container. To accomplish this, the `resource_pool_id` of the\nvirtual machine is set to the `id` of the vApp container.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst computeCluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore-01\",\n datacenterId: datacenter.id,\n}));\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"VM Network\",\n datacenterId: datacenter.id,\n}));\nconst vappContainer = new vsphere.VappContainer(\"vapp_container\", {\n name: \"vapp-01\",\n parentResourcePoolId: computeCluster.then(computeCluster =\u003e computeCluster.resourcePoolId),\n});\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"foo\",\n resourcePoolId: vappContainerVsphereVappContainer.id,\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 1,\n memory: 1024,\n guestId: \"ubuntu64Guest\",\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n disks: [{\n label: \"disk0\",\n size: 20,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncompute_cluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\ndatastore = vsphere.get_datastore(name=\"datastore-01\",\n datacenter_id=datacenter.id)\nnetwork = vsphere.get_network(name=\"VM Network\",\n datacenter_id=datacenter.id)\nvapp_container = vsphere.VappContainer(\"vapp_container\",\n name=\"vapp-01\",\n parent_resource_pool_id=compute_cluster.resource_pool_id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"foo\",\n resource_pool_id=vapp_container_vsphere_vapp_container[\"id\"],\n datastore_id=datastore.id,\n num_cpus=1,\n memory=1024,\n guest_id=\"ubuntu64Guest\",\n network_interfaces=[{\n \"network_id\": network.id,\n }],\n disks=[{\n \"label\": \"disk0\",\n \"size\": 20,\n }])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"VM Network\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vappContainer = new VSphere.VappContainer(\"vapp_container\", new()\n {\n Name = \"vapp-01\",\n ParentResourcePoolId = computeCluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.ResourcePoolId),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"foo\",\n ResourcePoolId = vappContainerVsphereVappContainer.Id,\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 1,\n Memory = 1024,\n GuestId = \"ubuntu64Guest\",\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 20,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcomputeCluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"VM Network\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVappContainer(ctx, \"vapp_container\", \u0026vsphere.VappContainerArgs{\n\t\t\tName: pulumi.String(\"vapp-01\"),\n\t\t\tParentResourcePoolId: pulumi.String(computeCluster.ResourcePoolId),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"foo\"),\n\t\t\tResourcePoolId: pulumi.Any(vappContainerVsphereVappContainer.Id),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(1),\n\t\t\tMemory: pulumi.Int(1024),\n\t\t\tGuestId: pulumi.String(\"ubuntu64Guest\"),\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(20),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.VappContainer;\nimport com.pulumi.vsphere.VappContainerArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"VM Network\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vappContainer = new VappContainer(\"vappContainer\", VappContainerArgs.builder()\n .name(\"vapp-01\")\n .parentResourcePoolId(computeCluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.resourcePoolId()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"foo\")\n .resourcePoolId(vappContainerVsphereVappContainer.id())\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(1)\n .memory(1024)\n .guestId(\"ubuntu64Guest\")\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(20)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vappContainer:\n type: vsphere:VappContainer\n name: vapp_container\n properties:\n name: vapp-01\n parentResourcePoolId: ${computeCluster.resourcePoolId}\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: foo\n resourcePoolId: ${vappContainerVsphereVappContainer.id}\n datastoreId: ${datastore.id}\n numCpus: 1\n memory: 1024\n guestId: ubuntu64Guest\n networkInterfaces:\n - networkId: ${network.id}\n disks:\n - label: disk0\n size: 20\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n computeCluster:\n fn::invoke:\n function: vsphere:getComputeCluster\n arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n datastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: datastore-01\n datacenterId: ${datacenter.id}\n network:\n fn::invoke:\n function: vsphere:getNetwork\n arguments:\n name: VM Network\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing vApp container can be imported into this resource via\n\nthe path to the vApp container, using the following command:\n\nExample:\n\n```sh\n$ pulumi import vsphere:index/vappContainer:VappContainer vapp_container /dc-01/host/cluster-01/Resources/resource-pool-01/vapp-01\n```\n\nThe example above would import the vApp container named `vapp-01` that is\n\nlocated in the resource pool `resource-pool-01` that is part of the host cluster\n\n`cluster-01` in the `dc-01` datacenter.\n\n", "properties": { "cpuExpandable": { "type": "boolean", @@ -9157,7 +9157,7 @@ } }, "vsphere:index/vappEntity:VappEntity": { - "description": "The `vsphere.VappEntity` resource can be used to describe the behavior of an\nentity (virtual machine or sub-vApp container) in a vApp container.\n\nFor more information on vSphere vApps, see [this\npage][ref-vsphere-vapp].\n\n[ref-vsphere-vapp]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-vm-administration/GUID-2A95EBB8-1779-40FA-B4FB-4D0845750879.html\n\n## Example Usage\n\nThe basic example below sets up a vApp container and a virtual machine in a\ncompute cluster and then creates a vApp entity to change the virtual machine's\npower on behavior in the vApp container.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst config = new pulumi.Config();\nconst datacenter = config.get(\"datacenter\") || \"dc-01\";\nconst cluster = config.get(\"cluster\") || \"cluster-01\";\nconst datacenterGetDatacenter = vsphere.getDatacenter({\n name: datacenter,\n});\nconst computeCluster = datacenterGetDatacenter.then(datacenterGetDatacenter =\u003e vsphere.getComputeCluster({\n name: cluster,\n datacenterId: datacenterGetDatacenter.id,\n}));\nconst network = datacenterGetDatacenter.then(datacenterGetDatacenter =\u003e vsphere.getNetwork({\n name: \"network1\",\n datacenterId: datacenterGetDatacenter.id,\n}));\nconst datastore = datacenterGetDatacenter.then(datacenterGetDatacenter =\u003e vsphere.getDatastore({\n name: \"datastore1\",\n datacenterId: datacenterGetDatacenter.id,\n}));\nconst vappContainer = new vsphere.VappContainer(\"vapp_container\", {\n name: \"vapp-container-test\",\n parentResourcePoolId: computeCluster.then(computeCluster =\u003e computeCluster.id),\n});\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"virtual-machine-test\",\n resourcePoolId: vappContainer.id,\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 1024,\n guestId: \"ubuntu64Guest\",\n disks: [{\n label: \"disk0\",\n size: 1,\n }],\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n});\nconst vappEntity = new vsphere.VappEntity(\"vapp_entity\", {\n targetId: vm.moid,\n containerId: vappContainer.id,\n startAction: \"none\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nconfig = pulumi.Config()\ndatacenter = config.get(\"datacenter\")\nif datacenter is None:\n datacenter = \"dc-01\"\ncluster = config.get(\"cluster\")\nif cluster is None:\n cluster = \"cluster-01\"\ndatacenter_get_datacenter = vsphere.get_datacenter(name=datacenter)\ncompute_cluster = vsphere.get_compute_cluster(name=cluster,\n datacenter_id=datacenter_get_datacenter.id)\nnetwork = vsphere.get_network(name=\"network1\",\n datacenter_id=datacenter_get_datacenter.id)\ndatastore = vsphere.get_datastore(name=\"datastore1\",\n datacenter_id=datacenter_get_datacenter.id)\nvapp_container = vsphere.VappContainer(\"vapp_container\",\n name=\"vapp-container-test\",\n parent_resource_pool_id=compute_cluster.id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"virtual-machine-test\",\n resource_pool_id=vapp_container.id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=1024,\n guest_id=\"ubuntu64Guest\",\n disks=[{\n \"label\": \"disk0\",\n \"size\": 1,\n }],\n network_interfaces=[{\n \"network_id\": network.id,\n }])\nvapp_entity = vsphere.VappEntity(\"vapp_entity\",\n target_id=vm.moid,\n container_id=vapp_container.id,\n start_action=\"none\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var config = new Config();\n var datacenter = config.Get(\"datacenter\") ?? \"dc-01\";\n var cluster = config.Get(\"cluster\") ?? \"cluster-01\";\n var datacenterGetDatacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = datacenter,\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = cluster,\n DatacenterId = datacenterGetDatacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"network1\",\n DatacenterId = datacenterGetDatacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore1\",\n DatacenterId = datacenterGetDatacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vappContainer = new VSphere.VappContainer(\"vapp_container\", new()\n {\n Name = \"vapp-container-test\",\n ParentResourcePoolId = computeCluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"virtual-machine-test\",\n ResourcePoolId = vappContainer.Id,\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 1024,\n GuestId = \"ubuntu64Guest\",\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 1,\n },\n },\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n });\n\n var vappEntity = new VSphere.VappEntity(\"vapp_entity\", new()\n {\n TargetId = vm.Moid,\n ContainerId = vappContainer.Id,\n StartAction = \"none\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tcfg := config.New(ctx, \"\")\n\t\tdatacenter := \"dc-01\"\n\t\tif param := cfg.Get(\"datacenter\"); param != \"\" {\n\t\t\tdatacenter = param\n\t\t}\n\t\tcluster := \"cluster-01\"\n\t\tif param := cfg.Get(\"cluster\"); param != \"\" {\n\t\t\tcluster = param\n\t\t}\n\t\tdatacenterGetDatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(datacenter),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcomputeCluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: cluster,\n\t\t\tDatacenterId: pulumi.StringRef(datacenterGetDatacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"network1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterGetDatacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterGetDatacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvappContainer, err := vsphere.NewVappContainer(ctx, \"vapp_container\", \u0026vsphere.VappContainerArgs{\n\t\t\tName: pulumi.String(\"vapp-container-test\"),\n\t\t\tParentResourcePoolId: pulumi.String(computeCluster.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm, err := vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"virtual-machine-test\"),\n\t\t\tResourcePoolId: vappContainer.ID(),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(1024),\n\t\t\tGuestId: pulumi.String(\"ubuntu64Guest\"),\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(1),\n\t\t\t\t},\n\t\t\t},\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVappEntity(ctx, \"vapp_entity\", \u0026vsphere.VappEntityArgs{\n\t\t\tTargetId: vm.Moid,\n\t\t\tContainerId: vappContainer.ID(),\n\t\t\tStartAction: pulumi.String(\"none\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.VappContainer;\nimport com.pulumi.vsphere.VappContainerArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.VappEntity;\nimport com.pulumi.vsphere.VappEntityArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var config = ctx.config();\n final var datacenter = config.get(\"datacenter\").orElse(\"dc-01\");\n final var cluster = config.get(\"cluster\").orElse(\"cluster-01\");\n final var datacenterGetDatacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(datacenter)\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(cluster)\n .datacenterId(datacenterGetDatacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"network1\")\n .datacenterId(datacenterGetDatacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore1\")\n .datacenterId(datacenterGetDatacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vappContainer = new VappContainer(\"vappContainer\", VappContainerArgs.builder()\n .name(\"vapp-container-test\")\n .parentResourcePoolId(computeCluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"virtual-machine-test\")\n .resourcePoolId(vappContainer.id())\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(1024)\n .guestId(\"ubuntu64Guest\")\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(1)\n .build())\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .build());\n\n var vappEntity = new VappEntity(\"vappEntity\", VappEntityArgs.builder()\n .targetId(vm.moid())\n .containerId(vappContainer.id())\n .startAction(\"none\")\n .build());\n\n }\n}\n```\n```yaml\nconfiguration:\n datacenter:\n type: string\n default: dc-01\n cluster:\n type: string\n default: cluster-01\nresources:\n vappContainer:\n type: vsphere:VappContainer\n name: vapp_container\n properties:\n name: vapp-container-test\n parentResourcePoolId: ${computeCluster.id}\n vappEntity:\n type: vsphere:VappEntity\n name: vapp_entity\n properties:\n targetId: ${vm.moid}\n containerId: ${vappContainer.id}\n startAction: none\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: virtual-machine-test\n resourcePoolId: ${vappContainer.id}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 1024\n guestId: ubuntu64Guest\n disks:\n - label: disk0\n size: 1\n networkInterfaces:\n - networkId: ${network.id}\nvariables:\n datacenterGetDatacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: ${datacenter}\n computeCluster:\n fn::invoke:\n Function: vsphere:getComputeCluster\n Arguments:\n name: ${cluster}\n datacenterId: ${datacenterGetDatacenter.id}\n network:\n fn::invoke:\n Function: vsphere:getNetwork\n Arguments:\n name: network1\n datacenterId: ${datacenterGetDatacenter.id}\n datastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: datastore1\n datacenterId: ${datacenterGetDatacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing vApp entity can be imported into this resource via\n\nthe ID of the vApp Entity.\n\n```sh\n$ pulumi import vsphere:index/vappEntity:VappEntity vapp_entity vm-123:res-456\n```\n\nThe above would import the vApp entity that governs the behavior of the virtual\n\nmachine with a [managed object ID][docs-about-morefs] of vm-123 in the vApp\n\ncontainer with the [managed object ID][docs-about-morefs] res-456.\n\n", + "description": "The `vsphere.VappEntity` resource can be used to describe the behavior of an\nentity (virtual machine or sub-vApp container) in a vApp container.\n\nFor more information on vSphere vApps, see [this\npage][ref-vsphere-vapp].\n\n[ref-vsphere-vapp]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-vm-administration/GUID-2A95EBB8-1779-40FA-B4FB-4D0845750879.html\n\n## Example Usage\n\nThe basic example below sets up a vApp container and a virtual machine in a\ncompute cluster and then creates a vApp entity to change the virtual machine's\npower on behavior in the vApp container.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst config = new pulumi.Config();\nconst datacenter = config.get(\"datacenter\") || \"dc-01\";\nconst cluster = config.get(\"cluster\") || \"cluster-01\";\nconst datacenterGetDatacenter = vsphere.getDatacenter({\n name: datacenter,\n});\nconst computeCluster = datacenterGetDatacenter.then(datacenterGetDatacenter =\u003e vsphere.getComputeCluster({\n name: cluster,\n datacenterId: datacenterGetDatacenter.id,\n}));\nconst network = datacenterGetDatacenter.then(datacenterGetDatacenter =\u003e vsphere.getNetwork({\n name: \"network1\",\n datacenterId: datacenterGetDatacenter.id,\n}));\nconst datastore = datacenterGetDatacenter.then(datacenterGetDatacenter =\u003e vsphere.getDatastore({\n name: \"datastore1\",\n datacenterId: datacenterGetDatacenter.id,\n}));\nconst vappContainer = new vsphere.VappContainer(\"vapp_container\", {\n name: \"vapp-container-test\",\n parentResourcePoolId: computeCluster.then(computeCluster =\u003e computeCluster.id),\n});\nconst vm = new vsphere.VirtualMachine(\"vm\", {\n name: \"virtual-machine-test\",\n resourcePoolId: vappContainer.id,\n datastoreId: datastore.then(datastore =\u003e datastore.id),\n numCpus: 2,\n memory: 1024,\n guestId: \"ubuntu64Guest\",\n disks: [{\n label: \"disk0\",\n size: 1,\n }],\n networkInterfaces: [{\n networkId: network.then(network =\u003e network.id),\n }],\n});\nconst vappEntity = new vsphere.VappEntity(\"vapp_entity\", {\n targetId: vm.moid,\n containerId: vappContainer.id,\n startAction: \"none\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nconfig = pulumi.Config()\ndatacenter = config.get(\"datacenter\")\nif datacenter is None:\n datacenter = \"dc-01\"\ncluster = config.get(\"cluster\")\nif cluster is None:\n cluster = \"cluster-01\"\ndatacenter_get_datacenter = vsphere.get_datacenter(name=datacenter)\ncompute_cluster = vsphere.get_compute_cluster(name=cluster,\n datacenter_id=datacenter_get_datacenter.id)\nnetwork = vsphere.get_network(name=\"network1\",\n datacenter_id=datacenter_get_datacenter.id)\ndatastore = vsphere.get_datastore(name=\"datastore1\",\n datacenter_id=datacenter_get_datacenter.id)\nvapp_container = vsphere.VappContainer(\"vapp_container\",\n name=\"vapp-container-test\",\n parent_resource_pool_id=compute_cluster.id)\nvm = vsphere.VirtualMachine(\"vm\",\n name=\"virtual-machine-test\",\n resource_pool_id=vapp_container.id,\n datastore_id=datastore.id,\n num_cpus=2,\n memory=1024,\n guest_id=\"ubuntu64Guest\",\n disks=[{\n \"label\": \"disk0\",\n \"size\": 1,\n }],\n network_interfaces=[{\n \"network_id\": network.id,\n }])\nvapp_entity = vsphere.VappEntity(\"vapp_entity\",\n target_id=vm.moid,\n container_id=vapp_container.id,\n start_action=\"none\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var config = new Config();\n var datacenter = config.Get(\"datacenter\") ?? \"dc-01\";\n var cluster = config.Get(\"cluster\") ?? \"cluster-01\";\n var datacenterGetDatacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = datacenter,\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = cluster,\n DatacenterId = datacenterGetDatacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"network1\",\n DatacenterId = datacenterGetDatacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore1\",\n DatacenterId = datacenterGetDatacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vappContainer = new VSphere.VappContainer(\"vapp_container\", new()\n {\n Name = \"vapp-container-test\",\n ParentResourcePoolId = computeCluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n });\n\n var vm = new VSphere.VirtualMachine(\"vm\", new()\n {\n Name = \"virtual-machine-test\",\n ResourcePoolId = vappContainer.Id,\n DatastoreId = datastore.Apply(getDatastoreResult =\u003e getDatastoreResult.Id),\n NumCpus = 2,\n Memory = 1024,\n GuestId = \"ubuntu64Guest\",\n Disks = new[]\n {\n new VSphere.Inputs.VirtualMachineDiskArgs\n {\n Label = \"disk0\",\n Size = 1,\n },\n },\n NetworkInterfaces = new[]\n {\n new VSphere.Inputs.VirtualMachineNetworkInterfaceArgs\n {\n NetworkId = network.Apply(getNetworkResult =\u003e getNetworkResult.Id),\n },\n },\n });\n\n var vappEntity = new VSphere.VappEntity(\"vapp_entity\", new()\n {\n TargetId = vm.Moid,\n ContainerId = vappContainer.Id,\n StartAction = \"none\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tcfg := config.New(ctx, \"\")\n\t\tdatacenter := \"dc-01\"\n\t\tif param := cfg.Get(\"datacenter\"); param != \"\" {\n\t\t\tdatacenter = param\n\t\t}\n\t\tcluster := \"cluster-01\"\n\t\tif param := cfg.Get(\"cluster\"); param != \"\" {\n\t\t\tcluster = param\n\t\t}\n\t\tdatacenterGetDatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(datacenter),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcomputeCluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: cluster,\n\t\t\tDatacenterId: pulumi.StringRef(datacenterGetDatacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tnetwork, err := vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"network1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterGetDatacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdatastore, err := vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore1\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenterGetDatacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvappContainer, err := vsphere.NewVappContainer(ctx, \"vapp_container\", \u0026vsphere.VappContainerArgs{\n\t\t\tName: pulumi.String(\"vapp-container-test\"),\n\t\t\tParentResourcePoolId: pulumi.String(computeCluster.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvm, err := vsphere.NewVirtualMachine(ctx, \"vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tName: pulumi.String(\"virtual-machine-test\"),\n\t\t\tResourcePoolId: vappContainer.ID(),\n\t\t\tDatastoreId: pulumi.String(datastore.Id),\n\t\t\tNumCpus: pulumi.Int(2),\n\t\t\tMemory: pulumi.Int(1024),\n\t\t\tGuestId: pulumi.String(\"ubuntu64Guest\"),\n\t\t\tDisks: vsphere.VirtualMachineDiskArray{\n\t\t\t\t\u0026vsphere.VirtualMachineDiskArgs{\n\t\t\t\t\tLabel: pulumi.String(\"disk0\"),\n\t\t\t\t\tSize: pulumi.Int(1),\n\t\t\t\t},\n\t\t\t},\n\t\t\tNetworkInterfaces: vsphere.VirtualMachineNetworkInterfaceArray{\n\t\t\t\t\u0026vsphere.VirtualMachineNetworkInterfaceArgs{\n\t\t\t\t\tNetworkId: pulumi.String(network.Id),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVappEntity(ctx, \"vapp_entity\", \u0026vsphere.VappEntityArgs{\n\t\t\tTargetId: vm.Moid,\n\t\t\tContainerId: vappContainer.ID(),\n\t\t\tStartAction: pulumi.String(\"none\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport com.pulumi.vsphere.VappContainer;\nimport com.pulumi.vsphere.VappContainerArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineDiskArgs;\nimport com.pulumi.vsphere.inputs.VirtualMachineNetworkInterfaceArgs;\nimport com.pulumi.vsphere.VappEntity;\nimport com.pulumi.vsphere.VappEntityArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var config = ctx.config();\n final var datacenter = config.get(\"datacenter\").orElse(\"dc-01\");\n final var cluster = config.get(\"cluster\").orElse(\"cluster-01\");\n final var datacenterGetDatacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(datacenter)\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(cluster)\n .datacenterId(datacenterGetDatacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"network1\")\n .datacenterId(datacenterGetDatacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore1\")\n .datacenterId(datacenterGetDatacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vappContainer = new VappContainer(\"vappContainer\", VappContainerArgs.builder()\n .name(\"vapp-container-test\")\n .parentResourcePoolId(computeCluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .build());\n\n var vm = new VirtualMachine(\"vm\", VirtualMachineArgs.builder()\n .name(\"virtual-machine-test\")\n .resourcePoolId(vappContainer.id())\n .datastoreId(datastore.applyValue(getDatastoreResult -\u003e getDatastoreResult.id()))\n .numCpus(2)\n .memory(1024)\n .guestId(\"ubuntu64Guest\")\n .disks(VirtualMachineDiskArgs.builder()\n .label(\"disk0\")\n .size(1)\n .build())\n .networkInterfaces(VirtualMachineNetworkInterfaceArgs.builder()\n .networkId(network.applyValue(getNetworkResult -\u003e getNetworkResult.id()))\n .build())\n .build());\n\n var vappEntity = new VappEntity(\"vappEntity\", VappEntityArgs.builder()\n .targetId(vm.moid())\n .containerId(vappContainer.id())\n .startAction(\"none\")\n .build());\n\n }\n}\n```\n```yaml\nconfiguration:\n datacenter:\n type: string\n default: dc-01\n cluster:\n type: string\n default: cluster-01\nresources:\n vappContainer:\n type: vsphere:VappContainer\n name: vapp_container\n properties:\n name: vapp-container-test\n parentResourcePoolId: ${computeCluster.id}\n vappEntity:\n type: vsphere:VappEntity\n name: vapp_entity\n properties:\n targetId: ${vm.moid}\n containerId: ${vappContainer.id}\n startAction: none\n vm:\n type: vsphere:VirtualMachine\n properties:\n name: virtual-machine-test\n resourcePoolId: ${vappContainer.id}\n datastoreId: ${datastore.id}\n numCpus: 2\n memory: 1024\n guestId: ubuntu64Guest\n disks:\n - label: disk0\n size: 1\n networkInterfaces:\n - networkId: ${network.id}\nvariables:\n datacenterGetDatacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: ${datacenter}\n computeCluster:\n fn::invoke:\n function: vsphere:getComputeCluster\n arguments:\n name: ${cluster}\n datacenterId: ${datacenterGetDatacenter.id}\n network:\n fn::invoke:\n function: vsphere:getNetwork\n arguments:\n name: network1\n datacenterId: ${datacenterGetDatacenter.id}\n datastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: datastore1\n datacenterId: ${datacenterGetDatacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing vApp entity can be imported into this resource via\n\nthe ID of the vApp Entity.\n\n```sh\n$ pulumi import vsphere:index/vappEntity:VappEntity vapp_entity vm-123:res-456\n```\n\nThe above would import the vApp entity that governs the behavior of the virtual\n\nmachine with a [managed object ID][docs-about-morefs] of vm-123 in the vApp\n\ncontainer with the [managed object ID][docs-about-morefs] res-456.\n\n", "properties": { "containerId": { "type": "string", @@ -9320,7 +9320,7 @@ } }, "vsphere:index/virtualDisk:VirtualDisk": { - "description": "The `vsphere.VirtualDisk` resource can be used to create virtual disks outside\nof any given `vsphere.VirtualMachine`\nresource. These disks can be attached to a virtual machine by creating a disk\nblock with the `attach` parameter.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = vsphere.getDatacenter({\n name: \"datastore-01\",\n});\nconst virtualDisk = new vsphere.VirtualDisk(\"virtual_disk\", {\n size: 40,\n type: \"thin\",\n vmdkPath: \"/foo/foo.vmdk\",\n createDirectories: true,\n datacenter: datacenter.then(datacenter =\u003e datacenter.name),\n datastore: datastoreVsphereDatastore.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datacenter(name=\"datastore-01\")\nvirtual_disk = vsphere.VirtualDisk(\"virtual_disk\",\n size=40,\n type=\"thin\",\n vmdk_path=\"/foo/foo.vmdk\",\n create_directories=True,\n datacenter=datacenter.name,\n datastore=datastore_vsphere_datastore[\"name\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"datastore-01\",\n });\n\n var virtualDisk = new VSphere.VirtualDisk(\"virtual_disk\", new()\n {\n Size = 40,\n Type = \"thin\",\n VmdkPath = \"/foo/foo.vmdk\",\n CreateDirectories = true,\n Datacenter = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Name),\n Datastore = datastoreVsphereDatastore.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"datastore-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualDisk(ctx, \"virtual_disk\", \u0026vsphere.VirtualDiskArgs{\n\t\t\tSize: pulumi.Int(40),\n\t\t\tType: pulumi.String(\"thin\"),\n\t\t\tVmdkPath: pulumi.String(\"/foo/foo.vmdk\"),\n\t\t\tCreateDirectories: pulumi.Bool(true),\n\t\t\tDatacenter: pulumi.String(datacenter.Name),\n\t\t\tDatastore: pulumi.Any(datastoreVsphereDatastore.Name),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.VirtualDisk;\nimport com.pulumi.vsphere.VirtualDiskArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"datastore-01\")\n .build());\n\n var virtualDisk = new VirtualDisk(\"virtualDisk\", VirtualDiskArgs.builder()\n .size(40)\n .type(\"thin\")\n .vmdkPath(\"/foo/foo.vmdk\")\n .createDirectories(true)\n .datacenter(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.name()))\n .datastore(datastoreVsphereDatastore.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n virtualDisk:\n type: vsphere:VirtualDisk\n name: virtual_disk\n properties:\n size: 40\n type: thin\n vmdkPath: /foo/foo.vmdk\n createDirectories: true\n datacenter: ${datacenter.name}\n datastore: ${datastoreVsphereDatastore.name}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n datastore:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: datastore-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing virtual disk can be imported into this resource\n\nvia supplying the full datastore path to the virtual disk. An example is below:\n\n```sh\n$ pulumi import vsphere:index/virtualDisk:VirtualDisk virtual_disk \\\n```\n\n '{\"virtual_disk_path\": \"/dc-01/[datastore-01]foo/bar.vmdk\", \\ \"create_directories\": \"true\"}'\n\nThe above would import the virtual disk located at `foo/bar.vmdk` in the `datastore-01`\n\ndatastore of the `dc-01` datacenter with `create_directories` set as `true`.\n\n", + "description": "The `vsphere.VirtualDisk` resource can be used to create virtual disks outside\nof any given `vsphere.VirtualMachine`\nresource. These disks can be attached to a virtual machine by creating a disk\nblock with the `attach` parameter.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = vsphere.getDatacenter({\n name: \"datastore-01\",\n});\nconst virtualDisk = new vsphere.VirtualDisk(\"virtual_disk\", {\n size: 40,\n type: \"thin\",\n vmdkPath: \"/foo/foo.vmdk\",\n createDirectories: true,\n datacenter: datacenter.then(datacenter =\u003e datacenter.name),\n datastore: datastoreVsphereDatastore.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datacenter(name=\"datastore-01\")\nvirtual_disk = vsphere.VirtualDisk(\"virtual_disk\",\n size=40,\n type=\"thin\",\n vmdk_path=\"/foo/foo.vmdk\",\n create_directories=True,\n datacenter=datacenter.name,\n datastore=datastore_vsphere_datastore[\"name\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"datastore-01\",\n });\n\n var virtualDisk = new VSphere.VirtualDisk(\"virtual_disk\", new()\n {\n Size = 40,\n Type = \"thin\",\n VmdkPath = \"/foo/foo.vmdk\",\n CreateDirectories = true,\n Datacenter = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Name),\n Datastore = datastoreVsphereDatastore.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"datastore-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualDisk(ctx, \"virtual_disk\", \u0026vsphere.VirtualDiskArgs{\n\t\t\tSize: pulumi.Int(40),\n\t\t\tType: pulumi.String(\"thin\"),\n\t\t\tVmdkPath: pulumi.String(\"/foo/foo.vmdk\"),\n\t\t\tCreateDirectories: pulumi.Bool(true),\n\t\t\tDatacenter: pulumi.String(datacenter.Name),\n\t\t\tDatastore: pulumi.Any(datastoreVsphereDatastore.Name),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.VirtualDisk;\nimport com.pulumi.vsphere.VirtualDiskArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"datastore-01\")\n .build());\n\n var virtualDisk = new VirtualDisk(\"virtualDisk\", VirtualDiskArgs.builder()\n .size(40)\n .type(\"thin\")\n .vmdkPath(\"/foo/foo.vmdk\")\n .createDirectories(true)\n .datacenter(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.name()))\n .datastore(datastoreVsphereDatastore.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n virtualDisk:\n type: vsphere:VirtualDisk\n name: virtual_disk\n properties:\n size: 40\n type: thin\n vmdkPath: /foo/foo.vmdk\n createDirectories: true\n datacenter: ${datacenter.name}\n datastore: ${datastoreVsphereDatastore.name}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n datastore:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: datastore-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing virtual disk can be imported into this resource\n\nvia supplying the full datastore path to the virtual disk. An example is below:\n\n```sh\n$ pulumi import vsphere:index/virtualDisk:VirtualDisk virtual_disk \\\n```\n\n '{\"virtual_disk_path\": \"/dc-01/[datastore-01]foo/bar.vmdk\", \\ \"create_directories\": \"true\"}'\n\nThe above would import the virtual disk located at `foo/bar.vmdk` in the `datastore-01`\n\ndatastore of the `dc-01` datacenter with `create_directories` set as `true`.\n\n", "properties": { "adapterType": { "type": "string", @@ -10787,7 +10787,7 @@ } }, "vsphere:index/vmStoragePolicy:VmStoragePolicy": { - "description": "The `vsphere.VmStoragePolicy` resource can be used to create and manage storage\npolicies. Using this resource, tag based placement rules can be created to\nplace virtual machines on a datastore with matching tags. If storage requirements for the applications on the virtual machine change, you can modify the storage policy that was originally applied to the virtual machine.\n\n## Example Usage\n\nThe following example creates storage policies with `tag_rules` base on sets of environment, service level, and replication attributes.\n\nIn this example, tags are first applied to datastores.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst environment = vsphere.getTagCategory({\n name: \"environment\",\n});\nconst serviceLevel = vsphere.getTagCategory({\n name: \"service_level\",\n});\nconst replication = vsphere.getTagCategory({\n name: \"replication\",\n});\nconst production = vsphere.getTag({\n name: \"production\",\n categoryId: \"data.vsphere_tag_category.environment.id\",\n});\nconst development = vsphere.getTag({\n name: \"development\",\n categoryId: \"data.vsphere_tag_category.environment.id\",\n});\nconst platinum = vsphere.getTag({\n name: \"platinum\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst gold = vsphere.getTag({\n name: \"platinum\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst silver = vsphere.getTag({\n name: \"silver\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst bronze = vsphere.getTag({\n name: \"bronze\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst replicated = vsphere.getTag({\n name: \"replicated\",\n categoryId: \"data.vsphere_tag_category.replication.id\",\n});\nconst nonReplicated = vsphere.getTag({\n name: \"non_replicated\",\n categoryId: \"data.vsphere_tag_category.replication.id\",\n});\nconst prodDatastore = new vsphere.VmfsDatastore(\"prod_datastore\", {tags: [\n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\",\n]});\nconst devDatastore = new vsphere.NasDatastore(\"dev_datastore\", {tags: [\n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\",\n]});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nenvironment = vsphere.get_tag_category(name=\"environment\")\nservice_level = vsphere.get_tag_category(name=\"service_level\")\nreplication = vsphere.get_tag_category(name=\"replication\")\nproduction = vsphere.get_tag(name=\"production\",\n category_id=\"data.vsphere_tag_category.environment.id\")\ndevelopment = vsphere.get_tag(name=\"development\",\n category_id=\"data.vsphere_tag_category.environment.id\")\nplatinum = vsphere.get_tag(name=\"platinum\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\ngold = vsphere.get_tag(name=\"platinum\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\nsilver = vsphere.get_tag(name=\"silver\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\nbronze = vsphere.get_tag(name=\"bronze\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\nreplicated = vsphere.get_tag(name=\"replicated\",\n category_id=\"data.vsphere_tag_category.replication.id\")\nnon_replicated = vsphere.get_tag(name=\"non_replicated\",\n category_id=\"data.vsphere_tag_category.replication.id\")\nprod_datastore = vsphere.VmfsDatastore(\"prod_datastore\", tags=[\n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\",\n])\ndev_datastore = vsphere.NasDatastore(\"dev_datastore\", tags=[\n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\",\n])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var environment = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"environment\",\n });\n\n var serviceLevel = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"service_level\",\n });\n\n var replication = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"replication\",\n });\n\n var production = VSphere.GetTag.Invoke(new()\n {\n Name = \"production\",\n CategoryId = \"data.vsphere_tag_category.environment.id\",\n });\n\n var development = VSphere.GetTag.Invoke(new()\n {\n Name = \"development\",\n CategoryId = \"data.vsphere_tag_category.environment.id\",\n });\n\n var platinum = VSphere.GetTag.Invoke(new()\n {\n Name = \"platinum\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var gold = VSphere.GetTag.Invoke(new()\n {\n Name = \"platinum\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var silver = VSphere.GetTag.Invoke(new()\n {\n Name = \"silver\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var bronze = VSphere.GetTag.Invoke(new()\n {\n Name = \"bronze\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var replicated = VSphere.GetTag.Invoke(new()\n {\n Name = \"replicated\",\n CategoryId = \"data.vsphere_tag_category.replication.id\",\n });\n\n var nonReplicated = VSphere.GetTag.Invoke(new()\n {\n Name = \"non_replicated\",\n CategoryId = \"data.vsphere_tag_category.replication.id\",\n });\n\n var prodDatastore = new VSphere.VmfsDatastore(\"prod_datastore\", new()\n {\n Tags = new[]\n {\n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\",\n },\n });\n\n var devDatastore = new VSphere.NasDatastore(\"dev_datastore\", new()\n {\n Tags = new[]\n {\n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"environment\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"service_level\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"replication\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"production\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.environment.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"development\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.environment.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"platinum\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"platinum\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"silver\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"bronze\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"replicated\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.replication.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"non_replicated\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.replication.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmfsDatastore(ctx, \"prod_datastore\", \u0026vsphere.VmfsDatastoreArgs{\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"data.vsphere_tag.production.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.platinum.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.replicated.id\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewNasDatastore(ctx, \"dev_datastore\", \u0026vsphere.NasDatastoreArgs{\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"data.vsphere_tag.development.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.silver.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.non_replicated.id\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport com.pulumi.vsphere.inputs.GetTagArgs;\nimport com.pulumi.vsphere.VmfsDatastore;\nimport com.pulumi.vsphere.VmfsDatastoreArgs;\nimport com.pulumi.vsphere.NasDatastore;\nimport com.pulumi.vsphere.NasDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var environment = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"environment\")\n .build());\n\n final var serviceLevel = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"service_level\")\n .build());\n\n final var replication = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"replication\")\n .build());\n\n final var production = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"production\")\n .categoryId(\"data.vsphere_tag_category.environment.id\")\n .build());\n\n final var development = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"development\")\n .categoryId(\"data.vsphere_tag_category.environment.id\")\n .build());\n\n final var platinum = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"platinum\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var gold = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"platinum\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var silver = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"silver\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var bronze = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"bronze\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var replicated = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"replicated\")\n .categoryId(\"data.vsphere_tag_category.replication.id\")\n .build());\n\n final var nonReplicated = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"non_replicated\")\n .categoryId(\"data.vsphere_tag_category.replication.id\")\n .build());\n\n var prodDatastore = new VmfsDatastore(\"prodDatastore\", VmfsDatastoreArgs.builder()\n .tags( \n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\")\n .build());\n\n var devDatastore = new NasDatastore(\"devDatastore\", NasDatastoreArgs.builder()\n .tags( \n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n prodDatastore:\n type: vsphere:VmfsDatastore\n name: prod_datastore\n properties:\n tags: # ... other configuration ...\n - data.vsphere_tag.production.id\n - data.vsphere_tag.platinum.id\n - data.vsphere_tag.replicated.id\n devDatastore:\n type: vsphere:NasDatastore\n name: dev_datastore\n properties:\n tags: # ... other configuration ...\n - data.vsphere_tag.development.id\n - data.vsphere_tag.silver.id\n - data.vsphere_tag.non_replicated.id\nvariables:\n environment:\n fn::invoke:\n Function: vsphere:getTagCategory\n Arguments:\n name: environment\n serviceLevel:\n fn::invoke:\n Function: vsphere:getTagCategory\n Arguments:\n name: service_level\n replication:\n fn::invoke:\n Function: vsphere:getTagCategory\n Arguments:\n name: replication\n production:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: production\n categoryId: data.vsphere_tag_category.environment.id\n development:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: development\n categoryId: data.vsphere_tag_category.environment.id\n platinum:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: platinum\n categoryId: data.vsphere_tag_category.service_level.id\n gold:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: platinum\n categoryId: data.vsphere_tag_category.service_level.id\n silver:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: silver\n categoryId: data.vsphere_tag_category.service_level.id\n bronze:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: bronze\n categoryId: data.vsphere_tag_category.service_level.id\n replicated:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: replicated\n categoryId: data.vsphere_tag_category.replication.id\n nonReplicated:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: non_replicated\n categoryId: data.vsphere_tag_category.replication.id\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nNext, storage policies are created and `tag_rules` are applied.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst prodPlatinumReplicated = new vsphere.VmStoragePolicy(\"prod_platinum_replicated\", {\n name: \"prod_platinum_replicated\",\n description: \"prod_platinum_replicated\",\n tagRules: [\n {\n tagCategory: environment.name,\n tags: [production.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: serviceLevel.name,\n tags: [platinum.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: replication.name,\n tags: [replicated.name],\n includeDatastoresWithTags: true,\n },\n ],\n});\nconst devSilverNonreplicated = new vsphere.VmStoragePolicy(\"dev_silver_nonreplicated\", {\n name: \"dev_silver_nonreplicated\",\n description: \"dev_silver_nonreplicated\",\n tagRules: [\n {\n tagCategory: environment.name,\n tags: [development.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: serviceLevel.name,\n tags: [silver.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: replication.name,\n tags: [nonReplicated.name],\n includeDatastoresWithTags: true,\n },\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nprod_platinum_replicated = vsphere.VmStoragePolicy(\"prod_platinum_replicated\",\n name=\"prod_platinum_replicated\",\n description=\"prod_platinum_replicated\",\n tag_rules=[\n {\n \"tag_category\": environment[\"name\"],\n \"tags\": [production[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": service_level[\"name\"],\n \"tags\": [platinum[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": replication[\"name\"],\n \"tags\": [replicated[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n ])\ndev_silver_nonreplicated = vsphere.VmStoragePolicy(\"dev_silver_nonreplicated\",\n name=\"dev_silver_nonreplicated\",\n description=\"dev_silver_nonreplicated\",\n tag_rules=[\n {\n \"tag_category\": environment[\"name\"],\n \"tags\": [development[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": service_level[\"name\"],\n \"tags\": [silver[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": replication[\"name\"],\n \"tags\": [non_replicated[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var prodPlatinumReplicated = new VSphere.VmStoragePolicy(\"prod_platinum_replicated\", new()\n {\n Name = \"prod_platinum_replicated\",\n Description = \"prod_platinum_replicated\",\n TagRules = new[]\n {\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = environment.Name,\n Tags = new[]\n {\n production.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = serviceLevel.Name,\n Tags = new[]\n {\n platinum.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = replication.Name,\n Tags = new[]\n {\n replicated.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n },\n });\n\n var devSilverNonreplicated = new VSphere.VmStoragePolicy(\"dev_silver_nonreplicated\", new()\n {\n Name = \"dev_silver_nonreplicated\",\n Description = \"dev_silver_nonreplicated\",\n TagRules = new[]\n {\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = environment.Name,\n Tags = new[]\n {\n development.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = serviceLevel.Name,\n Tags = new[]\n {\n silver.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = replication.Name,\n Tags = new[]\n {\n nonReplicated.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.NewVmStoragePolicy(ctx, \"prod_platinum_replicated\", \u0026vsphere.VmStoragePolicyArgs{\n\t\t\tName: pulumi.String(\"prod_platinum_replicated\"),\n\t\t\tDescription: pulumi.String(\"prod_platinum_replicated\"),\n\t\t\tTagRules: vsphere.VmStoragePolicyTagRuleArray{\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(environment.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tproduction.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(serviceLevel.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tplatinum.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(replication.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\treplicated.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmStoragePolicy(ctx, \"dev_silver_nonreplicated\", \u0026vsphere.VmStoragePolicyArgs{\n\t\t\tName: pulumi.String(\"dev_silver_nonreplicated\"),\n\t\t\tDescription: pulumi.String(\"dev_silver_nonreplicated\"),\n\t\t\tTagRules: vsphere.VmStoragePolicyTagRuleArray{\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(environment.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tdevelopment.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(serviceLevel.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tsilver.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(replication.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tnonReplicated.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VmStoragePolicy;\nimport com.pulumi.vsphere.VmStoragePolicyArgs;\nimport com.pulumi.vsphere.inputs.VmStoragePolicyTagRuleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n var prodPlatinumReplicated = new VmStoragePolicy(\"prodPlatinumReplicated\", VmStoragePolicyArgs.builder()\n .name(\"prod_platinum_replicated\")\n .description(\"prod_platinum_replicated\")\n .tagRules( \n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(environment.name())\n .tags(production.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(serviceLevel.name())\n .tags(platinum.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(replication.name())\n .tags(replicated.name())\n .includeDatastoresWithTags(true)\n .build())\n .build());\n\n var devSilverNonreplicated = new VmStoragePolicy(\"devSilverNonreplicated\", VmStoragePolicyArgs.builder()\n .name(\"dev_silver_nonreplicated\")\n .description(\"dev_silver_nonreplicated\")\n .tagRules( \n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(environment.name())\n .tags(development.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(serviceLevel.name())\n .tags(silver.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(replication.name())\n .tags(nonReplicated.name())\n .includeDatastoresWithTags(true)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n prodPlatinumReplicated:\n type: vsphere:VmStoragePolicy\n name: prod_platinum_replicated\n properties:\n name: prod_platinum_replicated\n description: prod_platinum_replicated\n tagRules:\n - tagCategory: ${environment.name}\n tags:\n - ${production.name}\n includeDatastoresWithTags: true\n - tagCategory: ${serviceLevel.name}\n tags:\n - ${platinum.name}\n includeDatastoresWithTags: true\n - tagCategory: ${replication.name}\n tags:\n - ${replicated.name}\n includeDatastoresWithTags: true\n devSilverNonreplicated:\n type: vsphere:VmStoragePolicy\n name: dev_silver_nonreplicated\n properties:\n name: dev_silver_nonreplicated\n description: dev_silver_nonreplicated\n tagRules:\n - tagCategory: ${environment.name}\n tags:\n - ${development.name}\n includeDatastoresWithTags: true\n - tagCategory: ${serviceLevel.name}\n tags:\n - ${silver.name}\n includeDatastoresWithTags: true\n - tagCategory: ${replication.name}\n tags:\n - ${nonReplicated.name}\n includeDatastoresWithTags: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nLastly, when creating a virtual machine resource, a storage policy can be specified to direct virtual machine placement to a datastore which matches the policy's `tags_rules`.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst prodPlatinumReplicated = vsphere.getPolicy({\n name: \"prod_platinum_replicated\",\n});\nconst devSilverNonreplicated = vsphere.getPolicy({\n name: \"dev_silver_nonreplicated\",\n});\nconst prodVm = new vsphere.VirtualMachine(\"prod_vm\", {storagePolicyId: storagePolicy.prodPlatinumReplicated.id});\nconst devVm = new vsphere.VirtualMachine(\"dev_vm\", {storagePolicyId: storagePolicy.devSilverNonreplicated.id});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nprod_platinum_replicated = vsphere.get_policy(name=\"prod_platinum_replicated\")\ndev_silver_nonreplicated = vsphere.get_policy(name=\"dev_silver_nonreplicated\")\nprod_vm = vsphere.VirtualMachine(\"prod_vm\", storage_policy_id=storage_policy[\"prodPlatinumReplicated\"][\"id\"])\ndev_vm = vsphere.VirtualMachine(\"dev_vm\", storage_policy_id=storage_policy[\"devSilverNonreplicated\"][\"id\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var prodPlatinumReplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"prod_platinum_replicated\",\n });\n\n var devSilverNonreplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"dev_silver_nonreplicated\",\n });\n\n var prodVm = new VSphere.VirtualMachine(\"prod_vm\", new()\n {\n StoragePolicyId = storagePolicy.ProdPlatinumReplicated.Id,\n });\n\n var devVm = new VSphere.VirtualMachine(\"dev_vm\", new()\n {\n StoragePolicyId = storagePolicy.DevSilverNonreplicated.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"prod_platinum_replicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"dev_silver_nonreplicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualMachine(ctx, \"prod_vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tStoragePolicyId: pulumi.Any(storagePolicy.ProdPlatinumReplicated.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualMachine(ctx, \"dev_vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tStoragePolicyId: pulumi.Any(storagePolicy.DevSilverNonreplicated.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetPolicyArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var prodPlatinumReplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"prod_platinum_replicated\")\n .build());\n\n final var devSilverNonreplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"dev_silver_nonreplicated\")\n .build());\n\n var prodVm = new VirtualMachine(\"prodVm\", VirtualMachineArgs.builder()\n .storagePolicyId(storagePolicy.prodPlatinumReplicated().id())\n .build());\n\n var devVm = new VirtualMachine(\"devVm\", VirtualMachineArgs.builder()\n .storagePolicyId(storagePolicy.devSilverNonreplicated().id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n prodVm:\n type: vsphere:VirtualMachine\n name: prod_vm\n properties:\n storagePolicyId: ${storagePolicy.prodPlatinumReplicated.id}\n devVm:\n type: vsphere:VirtualMachine\n name: dev_vm\n properties:\n storagePolicyId: ${storagePolicy.devSilverNonreplicated.id}\nvariables:\n prodPlatinumReplicated:\n fn::invoke:\n Function: vsphere:getPolicy\n Arguments:\n name: prod_platinum_replicated\n devSilverNonreplicated:\n fn::invoke:\n Function: vsphere:getPolicy\n Arguments:\n name: dev_silver_nonreplicated\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.VmStoragePolicy` resource can be used to create and manage storage\npolicies. Using this resource, tag based placement rules can be created to\nplace virtual machines on a datastore with matching tags. If storage requirements for the applications on the virtual machine change, you can modify the storage policy that was originally applied to the virtual machine.\n\n## Example Usage\n\nThe following example creates storage policies with `tag_rules` base on sets of environment, service level, and replication attributes.\n\nIn this example, tags are first applied to datastores.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst environment = vsphere.getTagCategory({\n name: \"environment\",\n});\nconst serviceLevel = vsphere.getTagCategory({\n name: \"service_level\",\n});\nconst replication = vsphere.getTagCategory({\n name: \"replication\",\n});\nconst production = vsphere.getTag({\n name: \"production\",\n categoryId: \"data.vsphere_tag_category.environment.id\",\n});\nconst development = vsphere.getTag({\n name: \"development\",\n categoryId: \"data.vsphere_tag_category.environment.id\",\n});\nconst platinum = vsphere.getTag({\n name: \"platinum\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst gold = vsphere.getTag({\n name: \"platinum\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst silver = vsphere.getTag({\n name: \"silver\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst bronze = vsphere.getTag({\n name: \"bronze\",\n categoryId: \"data.vsphere_tag_category.service_level.id\",\n});\nconst replicated = vsphere.getTag({\n name: \"replicated\",\n categoryId: \"data.vsphere_tag_category.replication.id\",\n});\nconst nonReplicated = vsphere.getTag({\n name: \"non_replicated\",\n categoryId: \"data.vsphere_tag_category.replication.id\",\n});\nconst prodDatastore = new vsphere.VmfsDatastore(\"prod_datastore\", {tags: [\n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\",\n]});\nconst devDatastore = new vsphere.NasDatastore(\"dev_datastore\", {tags: [\n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\",\n]});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nenvironment = vsphere.get_tag_category(name=\"environment\")\nservice_level = vsphere.get_tag_category(name=\"service_level\")\nreplication = vsphere.get_tag_category(name=\"replication\")\nproduction = vsphere.get_tag(name=\"production\",\n category_id=\"data.vsphere_tag_category.environment.id\")\ndevelopment = vsphere.get_tag(name=\"development\",\n category_id=\"data.vsphere_tag_category.environment.id\")\nplatinum = vsphere.get_tag(name=\"platinum\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\ngold = vsphere.get_tag(name=\"platinum\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\nsilver = vsphere.get_tag(name=\"silver\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\nbronze = vsphere.get_tag(name=\"bronze\",\n category_id=\"data.vsphere_tag_category.service_level.id\")\nreplicated = vsphere.get_tag(name=\"replicated\",\n category_id=\"data.vsphere_tag_category.replication.id\")\nnon_replicated = vsphere.get_tag(name=\"non_replicated\",\n category_id=\"data.vsphere_tag_category.replication.id\")\nprod_datastore = vsphere.VmfsDatastore(\"prod_datastore\", tags=[\n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\",\n])\ndev_datastore = vsphere.NasDatastore(\"dev_datastore\", tags=[\n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\",\n])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var environment = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"environment\",\n });\n\n var serviceLevel = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"service_level\",\n });\n\n var replication = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"replication\",\n });\n\n var production = VSphere.GetTag.Invoke(new()\n {\n Name = \"production\",\n CategoryId = \"data.vsphere_tag_category.environment.id\",\n });\n\n var development = VSphere.GetTag.Invoke(new()\n {\n Name = \"development\",\n CategoryId = \"data.vsphere_tag_category.environment.id\",\n });\n\n var platinum = VSphere.GetTag.Invoke(new()\n {\n Name = \"platinum\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var gold = VSphere.GetTag.Invoke(new()\n {\n Name = \"platinum\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var silver = VSphere.GetTag.Invoke(new()\n {\n Name = \"silver\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var bronze = VSphere.GetTag.Invoke(new()\n {\n Name = \"bronze\",\n CategoryId = \"data.vsphere_tag_category.service_level.id\",\n });\n\n var replicated = VSphere.GetTag.Invoke(new()\n {\n Name = \"replicated\",\n CategoryId = \"data.vsphere_tag_category.replication.id\",\n });\n\n var nonReplicated = VSphere.GetTag.Invoke(new()\n {\n Name = \"non_replicated\",\n CategoryId = \"data.vsphere_tag_category.replication.id\",\n });\n\n var prodDatastore = new VSphere.VmfsDatastore(\"prod_datastore\", new()\n {\n Tags = new[]\n {\n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\",\n },\n });\n\n var devDatastore = new VSphere.NasDatastore(\"dev_datastore\", new()\n {\n Tags = new[]\n {\n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"environment\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"service_level\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"replication\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"production\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.environment.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"development\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.environment.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"platinum\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"platinum\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"silver\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"bronze\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.service_level.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"replicated\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.replication.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"non_replicated\",\n\t\t\tCategoryId: \"data.vsphere_tag_category.replication.id\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmfsDatastore(ctx, \"prod_datastore\", \u0026vsphere.VmfsDatastoreArgs{\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"data.vsphere_tag.production.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.platinum.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.replicated.id\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewNasDatastore(ctx, \"dev_datastore\", \u0026vsphere.NasDatastoreArgs{\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"data.vsphere_tag.development.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.silver.id\"),\n\t\t\t\tpulumi.String(\"data.vsphere_tag.non_replicated.id\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport com.pulumi.vsphere.inputs.GetTagArgs;\nimport com.pulumi.vsphere.VmfsDatastore;\nimport com.pulumi.vsphere.VmfsDatastoreArgs;\nimport com.pulumi.vsphere.NasDatastore;\nimport com.pulumi.vsphere.NasDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var environment = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"environment\")\n .build());\n\n final var serviceLevel = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"service_level\")\n .build());\n\n final var replication = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"replication\")\n .build());\n\n final var production = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"production\")\n .categoryId(\"data.vsphere_tag_category.environment.id\")\n .build());\n\n final var development = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"development\")\n .categoryId(\"data.vsphere_tag_category.environment.id\")\n .build());\n\n final var platinum = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"platinum\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var gold = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"platinum\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var silver = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"silver\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var bronze = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"bronze\")\n .categoryId(\"data.vsphere_tag_category.service_level.id\")\n .build());\n\n final var replicated = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"replicated\")\n .categoryId(\"data.vsphere_tag_category.replication.id\")\n .build());\n\n final var nonReplicated = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"non_replicated\")\n .categoryId(\"data.vsphere_tag_category.replication.id\")\n .build());\n\n var prodDatastore = new VmfsDatastore(\"prodDatastore\", VmfsDatastoreArgs.builder()\n .tags( \n \"data.vsphere_tag.production.id\",\n \"data.vsphere_tag.platinum.id\",\n \"data.vsphere_tag.replicated.id\")\n .build());\n\n var devDatastore = new NasDatastore(\"devDatastore\", NasDatastoreArgs.builder()\n .tags( \n \"data.vsphere_tag.development.id\",\n \"data.vsphere_tag.silver.id\",\n \"data.vsphere_tag.non_replicated.id\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n prodDatastore:\n type: vsphere:VmfsDatastore\n name: prod_datastore\n properties:\n tags: # ... other configuration ...\n - data.vsphere_tag.production.id\n - data.vsphere_tag.platinum.id\n - data.vsphere_tag.replicated.id\n devDatastore:\n type: vsphere:NasDatastore\n name: dev_datastore\n properties:\n tags: # ... other configuration ...\n - data.vsphere_tag.development.id\n - data.vsphere_tag.silver.id\n - data.vsphere_tag.non_replicated.id\nvariables:\n environment:\n fn::invoke:\n function: vsphere:getTagCategory\n arguments:\n name: environment\n serviceLevel:\n fn::invoke:\n function: vsphere:getTagCategory\n arguments:\n name: service_level\n replication:\n fn::invoke:\n function: vsphere:getTagCategory\n arguments:\n name: replication\n production:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: production\n categoryId: data.vsphere_tag_category.environment.id\n development:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: development\n categoryId: data.vsphere_tag_category.environment.id\n platinum:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: platinum\n categoryId: data.vsphere_tag_category.service_level.id\n gold:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: platinum\n categoryId: data.vsphere_tag_category.service_level.id\n silver:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: silver\n categoryId: data.vsphere_tag_category.service_level.id\n bronze:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: bronze\n categoryId: data.vsphere_tag_category.service_level.id\n replicated:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: replicated\n categoryId: data.vsphere_tag_category.replication.id\n nonReplicated:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: non_replicated\n categoryId: data.vsphere_tag_category.replication.id\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nNext, storage policies are created and `tag_rules` are applied.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst prodPlatinumReplicated = new vsphere.VmStoragePolicy(\"prod_platinum_replicated\", {\n name: \"prod_platinum_replicated\",\n description: \"prod_platinum_replicated\",\n tagRules: [\n {\n tagCategory: environment.name,\n tags: [production.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: serviceLevel.name,\n tags: [platinum.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: replication.name,\n tags: [replicated.name],\n includeDatastoresWithTags: true,\n },\n ],\n});\nconst devSilverNonreplicated = new vsphere.VmStoragePolicy(\"dev_silver_nonreplicated\", {\n name: \"dev_silver_nonreplicated\",\n description: \"dev_silver_nonreplicated\",\n tagRules: [\n {\n tagCategory: environment.name,\n tags: [development.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: serviceLevel.name,\n tags: [silver.name],\n includeDatastoresWithTags: true,\n },\n {\n tagCategory: replication.name,\n tags: [nonReplicated.name],\n includeDatastoresWithTags: true,\n },\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nprod_platinum_replicated = vsphere.VmStoragePolicy(\"prod_platinum_replicated\",\n name=\"prod_platinum_replicated\",\n description=\"prod_platinum_replicated\",\n tag_rules=[\n {\n \"tag_category\": environment[\"name\"],\n \"tags\": [production[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": service_level[\"name\"],\n \"tags\": [platinum[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": replication[\"name\"],\n \"tags\": [replicated[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n ])\ndev_silver_nonreplicated = vsphere.VmStoragePolicy(\"dev_silver_nonreplicated\",\n name=\"dev_silver_nonreplicated\",\n description=\"dev_silver_nonreplicated\",\n tag_rules=[\n {\n \"tag_category\": environment[\"name\"],\n \"tags\": [development[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": service_level[\"name\"],\n \"tags\": [silver[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n {\n \"tag_category\": replication[\"name\"],\n \"tags\": [non_replicated[\"name\"]],\n \"include_datastores_with_tags\": True,\n },\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var prodPlatinumReplicated = new VSphere.VmStoragePolicy(\"prod_platinum_replicated\", new()\n {\n Name = \"prod_platinum_replicated\",\n Description = \"prod_platinum_replicated\",\n TagRules = new[]\n {\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = environment.Name,\n Tags = new[]\n {\n production.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = serviceLevel.Name,\n Tags = new[]\n {\n platinum.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = replication.Name,\n Tags = new[]\n {\n replicated.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n },\n });\n\n var devSilverNonreplicated = new VSphere.VmStoragePolicy(\"dev_silver_nonreplicated\", new()\n {\n Name = \"dev_silver_nonreplicated\",\n Description = \"dev_silver_nonreplicated\",\n TagRules = new[]\n {\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = environment.Name,\n Tags = new[]\n {\n development.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = serviceLevel.Name,\n Tags = new[]\n {\n silver.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n new VSphere.Inputs.VmStoragePolicyTagRuleArgs\n {\n TagCategory = replication.Name,\n Tags = new[]\n {\n nonReplicated.Name,\n },\n IncludeDatastoresWithTags = true,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.NewVmStoragePolicy(ctx, \"prod_platinum_replicated\", \u0026vsphere.VmStoragePolicyArgs{\n\t\t\tName: pulumi.String(\"prod_platinum_replicated\"),\n\t\t\tDescription: pulumi.String(\"prod_platinum_replicated\"),\n\t\t\tTagRules: vsphere.VmStoragePolicyTagRuleArray{\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(environment.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tproduction.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(serviceLevel.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tplatinum.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(replication.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\treplicated.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmStoragePolicy(ctx, \"dev_silver_nonreplicated\", \u0026vsphere.VmStoragePolicyArgs{\n\t\t\tName: pulumi.String(\"dev_silver_nonreplicated\"),\n\t\t\tDescription: pulumi.String(\"dev_silver_nonreplicated\"),\n\t\t\tTagRules: vsphere.VmStoragePolicyTagRuleArray{\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(environment.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tdevelopment.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(serviceLevel.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tsilver.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t\t\u0026vsphere.VmStoragePolicyTagRuleArgs{\n\t\t\t\t\tTagCategory: pulumi.Any(replication.Name),\n\t\t\t\t\tTags: pulumi.StringArray{\n\t\t\t\t\t\tnonReplicated.Name,\n\t\t\t\t\t},\n\t\t\t\t\tIncludeDatastoresWithTags: pulumi.Bool(true),\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VmStoragePolicy;\nimport com.pulumi.vsphere.VmStoragePolicyArgs;\nimport com.pulumi.vsphere.inputs.VmStoragePolicyTagRuleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n var prodPlatinumReplicated = new VmStoragePolicy(\"prodPlatinumReplicated\", VmStoragePolicyArgs.builder()\n .name(\"prod_platinum_replicated\")\n .description(\"prod_platinum_replicated\")\n .tagRules( \n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(environment.name())\n .tags(production.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(serviceLevel.name())\n .tags(platinum.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(replication.name())\n .tags(replicated.name())\n .includeDatastoresWithTags(true)\n .build())\n .build());\n\n var devSilverNonreplicated = new VmStoragePolicy(\"devSilverNonreplicated\", VmStoragePolicyArgs.builder()\n .name(\"dev_silver_nonreplicated\")\n .description(\"dev_silver_nonreplicated\")\n .tagRules( \n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(environment.name())\n .tags(development.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(serviceLevel.name())\n .tags(silver.name())\n .includeDatastoresWithTags(true)\n .build(),\n VmStoragePolicyTagRuleArgs.builder()\n .tagCategory(replication.name())\n .tags(nonReplicated.name())\n .includeDatastoresWithTags(true)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n prodPlatinumReplicated:\n type: vsphere:VmStoragePolicy\n name: prod_platinum_replicated\n properties:\n name: prod_platinum_replicated\n description: prod_platinum_replicated\n tagRules:\n - tagCategory: ${environment.name}\n tags:\n - ${production.name}\n includeDatastoresWithTags: true\n - tagCategory: ${serviceLevel.name}\n tags:\n - ${platinum.name}\n includeDatastoresWithTags: true\n - tagCategory: ${replication.name}\n tags:\n - ${replicated.name}\n includeDatastoresWithTags: true\n devSilverNonreplicated:\n type: vsphere:VmStoragePolicy\n name: dev_silver_nonreplicated\n properties:\n name: dev_silver_nonreplicated\n description: dev_silver_nonreplicated\n tagRules:\n - tagCategory: ${environment.name}\n tags:\n - ${development.name}\n includeDatastoresWithTags: true\n - tagCategory: ${serviceLevel.name}\n tags:\n - ${silver.name}\n includeDatastoresWithTags: true\n - tagCategory: ${replication.name}\n tags:\n - ${nonReplicated.name}\n includeDatastoresWithTags: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nLastly, when creating a virtual machine resource, a storage policy can be specified to direct virtual machine placement to a datastore which matches the policy's `tags_rules`.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst prodPlatinumReplicated = vsphere.getPolicy({\n name: \"prod_platinum_replicated\",\n});\nconst devSilverNonreplicated = vsphere.getPolicy({\n name: \"dev_silver_nonreplicated\",\n});\nconst prodVm = new vsphere.VirtualMachine(\"prod_vm\", {storagePolicyId: storagePolicy.prodPlatinumReplicated.id});\nconst devVm = new vsphere.VirtualMachine(\"dev_vm\", {storagePolicyId: storagePolicy.devSilverNonreplicated.id});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nprod_platinum_replicated = vsphere.get_policy(name=\"prod_platinum_replicated\")\ndev_silver_nonreplicated = vsphere.get_policy(name=\"dev_silver_nonreplicated\")\nprod_vm = vsphere.VirtualMachine(\"prod_vm\", storage_policy_id=storage_policy[\"prodPlatinumReplicated\"][\"id\"])\ndev_vm = vsphere.VirtualMachine(\"dev_vm\", storage_policy_id=storage_policy[\"devSilverNonreplicated\"][\"id\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var prodPlatinumReplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"prod_platinum_replicated\",\n });\n\n var devSilverNonreplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"dev_silver_nonreplicated\",\n });\n\n var prodVm = new VSphere.VirtualMachine(\"prod_vm\", new()\n {\n StoragePolicyId = storagePolicy.ProdPlatinumReplicated.Id,\n });\n\n var devVm = new VSphere.VirtualMachine(\"dev_vm\", new()\n {\n StoragePolicyId = storagePolicy.DevSilverNonreplicated.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"prod_platinum_replicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"dev_silver_nonreplicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualMachine(ctx, \"prod_vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tStoragePolicyId: pulumi.Any(storagePolicy.ProdPlatinumReplicated.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVirtualMachine(ctx, \"dev_vm\", \u0026vsphere.VirtualMachineArgs{\n\t\t\tStoragePolicyId: pulumi.Any(storagePolicy.DevSilverNonreplicated.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetPolicyArgs;\nimport com.pulumi.vsphere.VirtualMachine;\nimport com.pulumi.vsphere.VirtualMachineArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var prodPlatinumReplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"prod_platinum_replicated\")\n .build());\n\n final var devSilverNonreplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"dev_silver_nonreplicated\")\n .build());\n\n var prodVm = new VirtualMachine(\"prodVm\", VirtualMachineArgs.builder()\n .storagePolicyId(storagePolicy.prodPlatinumReplicated().id())\n .build());\n\n var devVm = new VirtualMachine(\"devVm\", VirtualMachineArgs.builder()\n .storagePolicyId(storagePolicy.devSilverNonreplicated().id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n prodVm:\n type: vsphere:VirtualMachine\n name: prod_vm\n properties:\n storagePolicyId: ${storagePolicy.prodPlatinumReplicated.id}\n devVm:\n type: vsphere:VirtualMachine\n name: dev_vm\n properties:\n storagePolicyId: ${storagePolicy.devSilverNonreplicated.id}\nvariables:\n prodPlatinumReplicated:\n fn::invoke:\n function: vsphere:getPolicy\n arguments:\n name: prod_platinum_replicated\n devSilverNonreplicated:\n fn::invoke:\n function: vsphere:getPolicy\n arguments:\n name: dev_silver_nonreplicated\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "properties": { "description": { "type": "string", @@ -10852,7 +10852,7 @@ } }, "vsphere:index/vmfsDatastore:VmfsDatastore": { - "description": "The `vsphere.VmfsDatastore` resource can be used to create and manage VMFS\ndatastores on an ESXi host or a set of hosts. The resource supports using any\nSCSI device that can generally be used in a datastore, such as local disks, or\ndisks presented to a host or multiple hosts over Fibre Channel or iSCSI.\nDevices can be specified manually, or discovered using the\n[`vsphere.getVmfsDisks`][data-source-vmfs-disks] data source.\n\n[data-source-vmfs-disks]: /docs/providers/vsphere/d/vmfs_disks.html\n\n## Auto-Mounting of Datastores Within vCenter\n\nNote that the current behavior of this resource will auto-mount any created\ndatastores to any other host within vCenter that has access to the same disk.\n\nExample: You want to create a datastore with a iSCSI LUN that is visible on 3\nhosts in a single vSphere cluster (`esxi1`, `esxi2` and `esxi3`). When you\ncreate the datastore on `esxi1`, the datastore will be automatically mounted on\n`esxi2` and `esxi3`, without the need to configure the resource on either of\nthose two hosts.\n\nFuture versions of this resource may allow you to control the hosts that a\ndatastore is mounted to, but currently, this automatic behavior cannot be\nchanged, so keep this in mind when writing your configurations and deploying\nyour disks.\n\n## Increasing Datastore Size\n\nTo increase the size of a datastore, you must add additional disks to the\n`disks` attribute. Expanding the size of a datastore by increasing the size of\nan already provisioned disk is currently not supported (but may be in future\nversions of this resource).\n\n\u003e **NOTE:** You cannot decrease the size of a datastore. If the resource\ndetects disks removed from the configuration, the provider will give an error. \n\n[cmd-taint]: /docs/commands/taint.html\n\n## Example Usage\n\n### Addition of local disks on a single host\n\nThe following example uses the default datacenter and default host to add a\ndatastore with local disks to a single ESXi server.\n\n\u003e **NOTE:** There are some situations where datastore creation will not work\nwhen working through vCenter (usually when trying to create a datastore on a\nsingle host with local disks). If you experience trouble creating the datastore\nyou need through vCenter, break the datastore off into a different configuration\nand deploy it using the ESXi server as the provider endpoint, using a similar\nconfiguration to what is below.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n datacenterId: datacenter.id,\n}));\nconst datastore = new vsphere.VmfsDatastore(\"datastore\", {\n name: \"test\",\n hostSystemId: esxiHost.id,\n disks: [\n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter()\nhost = vsphere.get_host(datacenter_id=datacenter.id)\ndatastore = vsphere.VmfsDatastore(\"datastore\",\n name=\"test\",\n host_system_id=esxi_host[\"id\"],\n disks=[\n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke();\n\n var host = VSphere.GetHost.Invoke(new()\n {\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var datastore = new VSphere.VmfsDatastore(\"datastore\", new()\n {\n Name = \"test\",\n HostSystemId = esxiHost.Id,\n Disks = new[]\n {\n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmfsDatastore(ctx, \"datastore\", \u0026vsphere.VmfsDatastoreArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tHostSystemId: pulumi.Any(esxiHost.Id),\n\t\t\tDisks: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"mpx.vmhba1:C0:T1:L0\"),\n\t\t\t\tpulumi.String(\"mpx.vmhba1:C0:T2:L0\"),\n\t\t\t\tpulumi.String(\"mpx.vmhba1:C0:T2:L0\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.VmfsDatastore;\nimport com.pulumi.vsphere.VmfsDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter();\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var datastore = new VmfsDatastore(\"datastore\", VmfsDatastoreArgs.builder()\n .name(\"test\")\n .hostSystemId(esxiHost.id())\n .disks( \n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n datastore:\n type: vsphere:VmfsDatastore\n properties:\n name: test\n hostSystemId: ${esxiHost.id}\n disks:\n - mpx.vmhba1:C0:T1:L0\n - mpx.vmhba1:C0:T2:L0\n - mpx.vmhba1:C0:T2:L0\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments: {}\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Auto-detection of disks via `vsphere.getVmfsDisks`\n\nThe following example makes use of the\n`vsphere.getVmfsDisks` data source to auto-detect\nexported iSCSI LUNS matching a certain NAA vendor ID (in this case, LUNs\nexported from a [NetApp][ext-netapp]). These discovered disks are then loaded\ninto `vsphere.VmfsDatastore`. The datastore is also placed in the\n`datastore-folder` folder afterwards.\n\n[ext-netapp]: https://kb.netapp.com/support/s/article/ka31A0000000rLRQAY/how-to-match-a-lun-s-naa-number-to-its-serial-number?language=en_US\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst available = host.then(host =\u003e vsphere.getVmfsDisks({\n hostSystemId: host.id,\n rescan: true,\n filter: \"naa.60a98000\",\n}));\nconst datastore = new vsphere.VmfsDatastore(\"datastore\", {\n name: \"test\",\n hostSystemId: esxiHost.id,\n folder: \"datastore-folder\",\n disks: [available.then(available =\u003e available.disks)],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\navailable = vsphere.get_vmfs_disks(host_system_id=host.id,\n rescan=True,\n filter=\"naa.60a98000\")\ndatastore = vsphere.VmfsDatastore(\"datastore\",\n name=\"test\",\n host_system_id=esxi_host[\"id\"],\n folder=\"datastore-folder\",\n disks=[available.disks])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var available = VSphere.GetVmfsDisks.Invoke(new()\n {\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n Rescan = true,\n Filter = \"naa.60a98000\",\n });\n\n var datastore = new VSphere.VmfsDatastore(\"datastore\", new()\n {\n Name = \"test\",\n HostSystemId = esxiHost.Id,\n Folder = \"datastore-folder\",\n Disks = new[]\n {\n available.Apply(getVmfsDisksResult =\u003e getVmfsDisksResult.Disks),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tavailable, err := vsphere.GetVmfsDisks(ctx, \u0026vsphere.GetVmfsDisksArgs{\n\t\t\tHostSystemId: host.Id,\n\t\t\tRescan: pulumi.BoolRef(true),\n\t\t\tFilter: pulumi.StringRef(\"naa.60a98000\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmfsDatastore(ctx, \"datastore\", \u0026vsphere.VmfsDatastoreArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tHostSystemId: pulumi.Any(esxiHost.Id),\n\t\t\tFolder: pulumi.String(\"datastore-folder\"),\n\t\t\tDisks: pulumi.StringArray{\n\t\t\t\tinterface{}(available.Disks),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetVmfsDisksArgs;\nimport com.pulumi.vsphere.VmfsDatastore;\nimport com.pulumi.vsphere.VmfsDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var available = VsphereFunctions.getVmfsDisks(GetVmfsDisksArgs.builder()\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .rescan(true)\n .filter(\"naa.60a98000\")\n .build());\n\n var datastore = new VmfsDatastore(\"datastore\", VmfsDatastoreArgs.builder()\n .name(\"test\")\n .hostSystemId(esxiHost.id())\n .folder(\"datastore-folder\")\n .disks(available.applyValue(getVmfsDisksResult -\u003e getVmfsDisksResult.disks()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n datastore:\n type: vsphere:VmfsDatastore\n properties:\n name: test\n hostSystemId: ${esxiHost.id}\n folder: datastore-folder\n disks:\n - ${available.disks}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n available:\n fn::invoke:\n Function: vsphere:getVmfsDisks\n Arguments:\n hostSystemId: ${host.id}\n rescan: true\n filter: naa.60a98000\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing VMFS datastore can be imported into this resource\n\nvia its managed object ID, via the command below. You also need the host system\n\nID.\n\n```sh\n$ pulumi import vsphere:index/vmfsDatastore:VmfsDatastore datastore datastore-123:host-10\n```\n\nYou need a tool like [`govc`][ext-govc] that can display managed object IDs.\n\n[ext-govc]: https://github.com/vmware/govmomi/tree/master/govc\n\nIn the case of govc, you can locate a managed object ID from an inventory path\n\nby doing the following:\n\n$ govc ls -i /dc/datastore/terraform-test\n\nDatastore:datastore-123\n\nTo locate host IDs, it might be a good idea to supply the `-l` flag as well so\n\nthat you can line up the names with the IDs:\n\n$ govc ls -l -i /dc/host/cluster1\n\nResourcePool:resgroup-10 /dc/host/cluster1/Resources\n\nHostSystem:host-10 /dc/host/cluster1/esxi1\n\nHostSystem:host-11 /dc/host/cluster1/esxi2\n\nHostSystem:host-12 /dc/host/cluster1/esxi3\n\n", + "description": "The `vsphere.VmfsDatastore` resource can be used to create and manage VMFS\ndatastores on an ESXi host or a set of hosts. The resource supports using any\nSCSI device that can generally be used in a datastore, such as local disks, or\ndisks presented to a host or multiple hosts over Fibre Channel or iSCSI.\nDevices can be specified manually, or discovered using the\n[`vsphere.getVmfsDisks`][data-source-vmfs-disks] data source.\n\n[data-source-vmfs-disks]: /docs/providers/vsphere/d/vmfs_disks.html\n\n## Auto-Mounting of Datastores Within vCenter\n\nNote that the current behavior of this resource will auto-mount any created\ndatastores to any other host within vCenter that has access to the same disk.\n\nExample: You want to create a datastore with a iSCSI LUN that is visible on 3\nhosts in a single vSphere cluster (`esxi1`, `esxi2` and `esxi3`). When you\ncreate the datastore on `esxi1`, the datastore will be automatically mounted on\n`esxi2` and `esxi3`, without the need to configure the resource on either of\nthose two hosts.\n\nFuture versions of this resource may allow you to control the hosts that a\ndatastore is mounted to, but currently, this automatic behavior cannot be\nchanged, so keep this in mind when writing your configurations and deploying\nyour disks.\n\n## Increasing Datastore Size\n\nTo increase the size of a datastore, you must add additional disks to the\n`disks` attribute. Expanding the size of a datastore by increasing the size of\nan already provisioned disk is currently not supported (but may be in future\nversions of this resource).\n\n\u003e **NOTE:** You cannot decrease the size of a datastore. If the resource\ndetects disks removed from the configuration, the provider will give an error. \n\n[cmd-taint]: /docs/commands/taint.html\n\n## Example Usage\n\n### Addition of local disks on a single host\n\nThe following example uses the default datacenter and default host to add a\ndatastore with local disks to a single ESXi server.\n\n\u003e **NOTE:** There are some situations where datastore creation will not work\nwhen working through vCenter (usually when trying to create a datastore on a\nsingle host with local disks). If you experience trouble creating the datastore\nyou need through vCenter, break the datastore off into a different configuration\nand deploy it using the ESXi server as the provider endpoint, using a similar\nconfiguration to what is below.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n datacenterId: datacenter.id,\n}));\nconst datastore = new vsphere.VmfsDatastore(\"datastore\", {\n name: \"test\",\n hostSystemId: esxiHost.id,\n disks: [\n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter()\nhost = vsphere.get_host(datacenter_id=datacenter.id)\ndatastore = vsphere.VmfsDatastore(\"datastore\",\n name=\"test\",\n host_system_id=esxi_host[\"id\"],\n disks=[\n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke();\n\n var host = VSphere.GetHost.Invoke(new()\n {\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var datastore = new VSphere.VmfsDatastore(\"datastore\", new()\n {\n Name = \"test\",\n HostSystemId = esxiHost.Id,\n Disks = new[]\n {\n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmfsDatastore(ctx, \"datastore\", \u0026vsphere.VmfsDatastoreArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tHostSystemId: pulumi.Any(esxiHost.Id),\n\t\t\tDisks: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"mpx.vmhba1:C0:T1:L0\"),\n\t\t\t\tpulumi.String(\"mpx.vmhba1:C0:T2:L0\"),\n\t\t\t\tpulumi.String(\"mpx.vmhba1:C0:T2:L0\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.VmfsDatastore;\nimport com.pulumi.vsphere.VmfsDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter();\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var datastore = new VmfsDatastore(\"datastore\", VmfsDatastoreArgs.builder()\n .name(\"test\")\n .hostSystemId(esxiHost.id())\n .disks( \n \"mpx.vmhba1:C0:T1:L0\",\n \"mpx.vmhba1:C0:T2:L0\",\n \"mpx.vmhba1:C0:T2:L0\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n datastore:\n type: vsphere:VmfsDatastore\n properties:\n name: test\n hostSystemId: ${esxiHost.id}\n disks:\n - mpx.vmhba1:C0:T1:L0\n - mpx.vmhba1:C0:T2:L0\n - mpx.vmhba1:C0:T2:L0\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments: {}\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Auto-detection of disks via `vsphere.getVmfsDisks`\n\nThe following example makes use of the\n`vsphere.getVmfsDisks` data source to auto-detect\nexported iSCSI LUNS matching a certain NAA vendor ID (in this case, LUNs\nexported from a [NetApp][ext-netapp]). These discovered disks are then loaded\ninto `vsphere.VmfsDatastore`. The datastore is also placed in the\n`datastore-folder` folder afterwards.\n\n[ext-netapp]: https://kb.netapp.com/support/s/article/ka31A0000000rLRQAY/how-to-match-a-lun-s-naa-number-to-its-serial-number?language=en_US\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst available = host.then(host =\u003e vsphere.getVmfsDisks({\n hostSystemId: host.id,\n rescan: true,\n filter: \"naa.60a98000\",\n}));\nconst datastore = new vsphere.VmfsDatastore(\"datastore\", {\n name: \"test\",\n hostSystemId: esxiHost.id,\n folder: \"datastore-folder\",\n disks: [available.then(available =\u003e available.disks)],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\navailable = vsphere.get_vmfs_disks(host_system_id=host.id,\n rescan=True,\n filter=\"naa.60a98000\")\ndatastore = vsphere.VmfsDatastore(\"datastore\",\n name=\"test\",\n host_system_id=esxi_host[\"id\"],\n folder=\"datastore-folder\",\n disks=[available.disks])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var available = VSphere.GetVmfsDisks.Invoke(new()\n {\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n Rescan = true,\n Filter = \"naa.60a98000\",\n });\n\n var datastore = new VSphere.VmfsDatastore(\"datastore\", new()\n {\n Name = \"test\",\n HostSystemId = esxiHost.Id,\n Folder = \"datastore-folder\",\n Disks = new[]\n {\n available.Apply(getVmfsDisksResult =\u003e getVmfsDisksResult.Disks),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tavailable, err := vsphere.GetVmfsDisks(ctx, \u0026vsphere.GetVmfsDisksArgs{\n\t\t\tHostSystemId: host.Id,\n\t\t\tRescan: pulumi.BoolRef(true),\n\t\t\tFilter: pulumi.StringRef(\"naa.60a98000\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVmfsDatastore(ctx, \"datastore\", \u0026vsphere.VmfsDatastoreArgs{\n\t\t\tName: pulumi.String(\"test\"),\n\t\t\tHostSystemId: pulumi.Any(esxiHost.Id),\n\t\t\tFolder: pulumi.String(\"datastore-folder\"),\n\t\t\tDisks: pulumi.StringArray{\n\t\t\t\tinterface{}(available.Disks),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetVmfsDisksArgs;\nimport com.pulumi.vsphere.VmfsDatastore;\nimport com.pulumi.vsphere.VmfsDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var available = VsphereFunctions.getVmfsDisks(GetVmfsDisksArgs.builder()\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .rescan(true)\n .filter(\"naa.60a98000\")\n .build());\n\n var datastore = new VmfsDatastore(\"datastore\", VmfsDatastoreArgs.builder()\n .name(\"test\")\n .hostSystemId(esxiHost.id())\n .folder(\"datastore-folder\")\n .disks(available.applyValue(getVmfsDisksResult -\u003e getVmfsDisksResult.disks()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n datastore:\n type: vsphere:VmfsDatastore\n properties:\n name: test\n hostSystemId: ${esxiHost.id}\n folder: datastore-folder\n disks:\n - ${available.disks}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n available:\n fn::invoke:\n function: vsphere:getVmfsDisks\n arguments:\n hostSystemId: ${host.id}\n rescan: true\n filter: naa.60a98000\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing VMFS datastore can be imported into this resource\n\nvia its managed object ID, via the command below. You also need the host system\n\nID.\n\n```sh\n$ pulumi import vsphere:index/vmfsDatastore:VmfsDatastore datastore datastore-123:host-10\n```\n\nYou need a tool like [`govc`][ext-govc] that can display managed object IDs.\n\n[ext-govc]: https://github.com/vmware/govmomi/tree/master/govc\n\nIn the case of govc, you can locate a managed object ID from an inventory path\n\nby doing the following:\n\n$ govc ls -i /dc/datastore/terraform-test\n\nDatastore:datastore-123\n\nTo locate host IDs, it might be a good idea to supply the `-l` flag as well so\n\nthat you can line up the names with the IDs:\n\n$ govc ls -l -i /dc/host/cluster1\n\nResourcePool:resgroup-10 /dc/host/cluster1/Resources\n\nHostSystem:host-10 /dc/host/cluster1/esxi1\n\nHostSystem:host-11 /dc/host/cluster1/esxi2\n\nHostSystem:host-12 /dc/host/cluster1/esxi3\n\n", "properties": { "accessible": { "type": "boolean", @@ -11050,7 +11050,7 @@ } }, "vsphere:index/vnic:Vnic": { - "description": "Provides a VMware vSphere vnic resource.\n\n## Example Usage\n\n### Create a vnic attached to a distributed virtual switch using the vmotion TCP/IP stack\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vds = new vsphere.DistributedVirtualSwitch(\"vds\", {\n name: \"vds-01\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n hosts: [{\n hostSystemId: host.then(host =\u003e host.id),\n devices: [\"vnic3\"],\n }],\n});\nconst pg = new vsphere.DistributedPortGroup(\"pg\", {\n name: \"pg-01\",\n vlanId: 1234,\n distributedVirtualSwitchUuid: vds.id,\n});\nconst vnic = new vsphere.Vnic(\"vnic\", {\n host: host.then(host =\u003e host.id),\n distributedSwitchPort: vds.id,\n distributedPortGroup: pg.id,\n ipv4: {\n dhcp: true,\n },\n netstack: \"vmotion\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvds = vsphere.DistributedVirtualSwitch(\"vds\",\n name=\"vds-01\",\n datacenter_id=datacenter.id,\n hosts=[{\n \"host_system_id\": host.id,\n \"devices\": [\"vnic3\"],\n }])\npg = vsphere.DistributedPortGroup(\"pg\",\n name=\"pg-01\",\n vlan_id=1234,\n distributed_virtual_switch_uuid=vds.id)\nvnic = vsphere.Vnic(\"vnic\",\n host=host.id,\n distributed_switch_port=vds.id,\n distributed_port_group=pg.id,\n ipv4={\n \"dhcp\": True,\n },\n netstack=\"vmotion\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vds = new VSphere.DistributedVirtualSwitch(\"vds\", new()\n {\n Name = \"vds-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n Hosts = new[]\n {\n new VSphere.Inputs.DistributedVirtualSwitchHostArgs\n {\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n Devices = new[]\n {\n \"vnic3\",\n },\n },\n },\n });\n\n var pg = new VSphere.DistributedPortGroup(\"pg\", new()\n {\n Name = \"pg-01\",\n VlanId = 1234,\n DistributedVirtualSwitchUuid = vds.Id,\n });\n\n var vnic = new VSphere.Vnic(\"vnic\", new()\n {\n Host = host.Apply(getHostResult =\u003e getHostResult.Id),\n DistributedSwitchPort = vds.Id,\n DistributedPortGroup = pg.Id,\n Ipv4 = new VSphere.Inputs.VnicIpv4Args\n {\n Dhcp = true,\n },\n Netstack = \"vmotion\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvds, err := vsphere.NewDistributedVirtualSwitch(ctx, \"vds\", \u0026vsphere.DistributedVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"vds-01\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t\tHosts: vsphere.DistributedVirtualSwitchHostArray{\n\t\t\t\t\u0026vsphere.DistributedVirtualSwitchHostArgs{\n\t\t\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\t\t\tDevices: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"vnic3\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpg, err := vsphere.NewDistributedPortGroup(ctx, \"pg\", \u0026vsphere.DistributedPortGroupArgs{\n\t\t\tName: pulumi.String(\"pg-01\"),\n\t\t\tVlanId: pulumi.Int(1234),\n\t\t\tDistributedVirtualSwitchUuid: vds.ID(),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVnic(ctx, \"vnic\", \u0026vsphere.VnicArgs{\n\t\t\tHost: pulumi.String(host.Id),\n\t\t\tDistributedSwitchPort: vds.ID(),\n\t\t\tDistributedPortGroup: pg.ID(),\n\t\t\tIpv4: \u0026vsphere.VnicIpv4Args{\n\t\t\t\tDhcp: pulumi.Bool(true),\n\t\t\t},\n\t\t\tNetstack: pulumi.String(\"vmotion\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.DistributedVirtualSwitch;\nimport com.pulumi.vsphere.DistributedVirtualSwitchArgs;\nimport com.pulumi.vsphere.inputs.DistributedVirtualSwitchHostArgs;\nimport com.pulumi.vsphere.DistributedPortGroup;\nimport com.pulumi.vsphere.DistributedPortGroupArgs;\nimport com.pulumi.vsphere.Vnic;\nimport com.pulumi.vsphere.VnicArgs;\nimport com.pulumi.vsphere.inputs.VnicIpv4Args;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vds = new DistributedVirtualSwitch(\"vds\", DistributedVirtualSwitchArgs.builder()\n .name(\"vds-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .hosts(DistributedVirtualSwitchHostArgs.builder()\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .devices(\"vnic3\")\n .build())\n .build());\n\n var pg = new DistributedPortGroup(\"pg\", DistributedPortGroupArgs.builder()\n .name(\"pg-01\")\n .vlanId(1234)\n .distributedVirtualSwitchUuid(vds.id())\n .build());\n\n var vnic = new Vnic(\"vnic\", VnicArgs.builder()\n .host(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .distributedSwitchPort(vds.id())\n .distributedPortGroup(pg.id())\n .ipv4(VnicIpv4Args.builder()\n .dhcp(true)\n .build())\n .netstack(\"vmotion\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vds:\n type: vsphere:DistributedVirtualSwitch\n properties:\n name: vds-01\n datacenterId: ${datacenter.id}\n hosts:\n - hostSystemId: ${host.id}\n devices:\n - vnic3\n pg:\n type: vsphere:DistributedPortGroup\n properties:\n name: pg-01\n vlanId: 1234\n distributedVirtualSwitchUuid: ${vds.id}\n vnic:\n type: vsphere:Vnic\n properties:\n host: ${host.id}\n distributedSwitchPort: ${vds.id}\n distributedPortGroup: ${pg.id}\n ipv4:\n dhcp: true\n netstack: vmotion\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a vnic attached to a portgroup using the default TCP/IP stack\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst hvs = new vsphere.HostVirtualSwitch(\"hvs\", {\n name: \"hvs-01\",\n hostSystemId: host.then(host =\u003e host.id),\n networkAdapters: [\n \"vmnic3\",\n \"vmnic4\",\n ],\n activeNics: [\"vmnic3\"],\n standbyNics: [\"vmnic4\"],\n});\nconst pg = new vsphere.HostPortGroup(\"pg\", {\n name: \"pg-01\",\n virtualSwitchName: hvs.name,\n hostSystemId: host.then(host =\u003e host.id),\n});\nconst vnic = new vsphere.Vnic(\"vnic\", {\n host: host.then(host =\u003e host.id),\n portgroup: pg.name,\n ipv4: {\n dhcp: true,\n },\n services: [\n \"vsan\",\n \"management\",\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nhvs = vsphere.HostVirtualSwitch(\"hvs\",\n name=\"hvs-01\",\n host_system_id=host.id,\n network_adapters=[\n \"vmnic3\",\n \"vmnic4\",\n ],\n active_nics=[\"vmnic3\"],\n standby_nics=[\"vmnic4\"])\npg = vsphere.HostPortGroup(\"pg\",\n name=\"pg-01\",\n virtual_switch_name=hvs.name,\n host_system_id=host.id)\nvnic = vsphere.Vnic(\"vnic\",\n host=host.id,\n portgroup=pg.name,\n ipv4={\n \"dhcp\": True,\n },\n services=[\n \"vsan\",\n \"management\",\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hvs = new VSphere.HostVirtualSwitch(\"hvs\", new()\n {\n Name = \"hvs-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NetworkAdapters = new[]\n {\n \"vmnic3\",\n \"vmnic4\",\n },\n ActiveNics = new[]\n {\n \"vmnic3\",\n },\n StandbyNics = new[]\n {\n \"vmnic4\",\n },\n });\n\n var pg = new VSphere.HostPortGroup(\"pg\", new()\n {\n Name = \"pg-01\",\n VirtualSwitchName = hvs.Name,\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n });\n\n var vnic = new VSphere.Vnic(\"vnic\", new()\n {\n Host = host.Apply(getHostResult =\u003e getHostResult.Id),\n Portgroup = pg.Name,\n Ipv4 = new VSphere.Inputs.VnicIpv4Args\n {\n Dhcp = true,\n },\n Services = new[]\n {\n \"vsan\",\n \"management\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thvs, err := vsphere.NewHostVirtualSwitch(ctx, \"hvs\", \u0026vsphere.HostVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"hvs-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tNetworkAdapters: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic3\"),\n\t\t\t\tpulumi.String(\"vmnic4\"),\n\t\t\t},\n\t\t\tActiveNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic3\"),\n\t\t\t},\n\t\t\tStandbyNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic4\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpg, err := vsphere.NewHostPortGroup(ctx, \"pg\", \u0026vsphere.HostPortGroupArgs{\n\t\t\tName: pulumi.String(\"pg-01\"),\n\t\t\tVirtualSwitchName: hvs.Name,\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVnic(ctx, \"vnic\", \u0026vsphere.VnicArgs{\n\t\t\tHost: pulumi.String(host.Id),\n\t\t\tPortgroup: pg.Name,\n\t\t\tIpv4: \u0026vsphere.VnicIpv4Args{\n\t\t\t\tDhcp: pulumi.Bool(true),\n\t\t\t},\n\t\t\tServices: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vsan\"),\n\t\t\t\tpulumi.String(\"management\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.HostVirtualSwitch;\nimport com.pulumi.vsphere.HostVirtualSwitchArgs;\nimport com.pulumi.vsphere.HostPortGroup;\nimport com.pulumi.vsphere.HostPortGroupArgs;\nimport com.pulumi.vsphere.Vnic;\nimport com.pulumi.vsphere.VnicArgs;\nimport com.pulumi.vsphere.inputs.VnicIpv4Args;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var hvs = new HostVirtualSwitch(\"hvs\", HostVirtualSwitchArgs.builder()\n .name(\"hvs-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .networkAdapters( \n \"vmnic3\",\n \"vmnic4\")\n .activeNics(\"vmnic3\")\n .standbyNics(\"vmnic4\")\n .build());\n\n var pg = new HostPortGroup(\"pg\", HostPortGroupArgs.builder()\n .name(\"pg-01\")\n .virtualSwitchName(hvs.name())\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .build());\n\n var vnic = new Vnic(\"vnic\", VnicArgs.builder()\n .host(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .portgroup(pg.name())\n .ipv4(VnicIpv4Args.builder()\n .dhcp(true)\n .build())\n .services( \n \"vsan\",\n \"management\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hvs:\n type: vsphere:HostVirtualSwitch\n properties:\n name: hvs-01\n hostSystemId: ${host.id}\n networkAdapters:\n - vmnic3\n - vmnic4\n activeNics:\n - vmnic3\n standbyNics:\n - vmnic4\n pg:\n type: vsphere:HostPortGroup\n properties:\n name: pg-01\n virtualSwitchName: ${hvs.name}\n hostSystemId: ${host.id}\n vnic:\n type: vsphere:Vnic\n properties:\n host: ${host.id}\n portgroup: ${pg.name}\n ipv4:\n dhcp: true\n services:\n - vsan\n - management\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing vNic can be imported into this resource\n\nvia supplying the vNic's ID. An example is below:\n\n[docs-import]: /docs/import/index.html\n\n```sh\n$ pulumi import vsphere:index/vnic:Vnic vnic host-123_vmk2\n```\n\nThe above would import the vnic `vmk2` from host with ID `host-123`.\n\n", + "description": "Provides a VMware vSphere vnic resource.\n\n## Example Usage\n\n### Create a vnic attached to a distributed virtual switch using the vmotion TCP/IP stack\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vds = new vsphere.DistributedVirtualSwitch(\"vds\", {\n name: \"vds-01\",\n datacenterId: datacenter.then(datacenter =\u003e datacenter.id),\n hosts: [{\n hostSystemId: host.then(host =\u003e host.id),\n devices: [\"vnic3\"],\n }],\n});\nconst pg = new vsphere.DistributedPortGroup(\"pg\", {\n name: \"pg-01\",\n vlanId: 1234,\n distributedVirtualSwitchUuid: vds.id,\n});\nconst vnic = new vsphere.Vnic(\"vnic\", {\n host: host.then(host =\u003e host.id),\n distributedSwitchPort: vds.id,\n distributedPortGroup: pg.id,\n ipv4: {\n dhcp: true,\n },\n netstack: \"vmotion\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvds = vsphere.DistributedVirtualSwitch(\"vds\",\n name=\"vds-01\",\n datacenter_id=datacenter.id,\n hosts=[{\n \"host_system_id\": host.id,\n \"devices\": [\"vnic3\"],\n }])\npg = vsphere.DistributedPortGroup(\"pg\",\n name=\"pg-01\",\n vlan_id=1234,\n distributed_virtual_switch_uuid=vds.id)\nvnic = vsphere.Vnic(\"vnic\",\n host=host.id,\n distributed_switch_port=vds.id,\n distributed_port_group=pg.id,\n ipv4={\n \"dhcp\": True,\n },\n netstack=\"vmotion\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vds = new VSphere.DistributedVirtualSwitch(\"vds\", new()\n {\n Name = \"vds-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n Hosts = new[]\n {\n new VSphere.Inputs.DistributedVirtualSwitchHostArgs\n {\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n Devices = new[]\n {\n \"vnic3\",\n },\n },\n },\n });\n\n var pg = new VSphere.DistributedPortGroup(\"pg\", new()\n {\n Name = \"pg-01\",\n VlanId = 1234,\n DistributedVirtualSwitchUuid = vds.Id,\n });\n\n var vnic = new VSphere.Vnic(\"vnic\", new()\n {\n Host = host.Apply(getHostResult =\u003e getHostResult.Id),\n DistributedSwitchPort = vds.Id,\n DistributedPortGroup = pg.Id,\n Ipv4 = new VSphere.Inputs.VnicIpv4Args\n {\n Dhcp = true,\n },\n Netstack = \"vmotion\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvds, err := vsphere.NewDistributedVirtualSwitch(ctx, \"vds\", \u0026vsphere.DistributedVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"vds-01\"),\n\t\t\tDatacenterId: pulumi.String(datacenter.Id),\n\t\t\tHosts: vsphere.DistributedVirtualSwitchHostArray{\n\t\t\t\t\u0026vsphere.DistributedVirtualSwitchHostArgs{\n\t\t\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\t\t\tDevices: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"vnic3\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpg, err := vsphere.NewDistributedPortGroup(ctx, \"pg\", \u0026vsphere.DistributedPortGroupArgs{\n\t\t\tName: pulumi.String(\"pg-01\"),\n\t\t\tVlanId: pulumi.Int(1234),\n\t\t\tDistributedVirtualSwitchUuid: vds.ID(),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVnic(ctx, \"vnic\", \u0026vsphere.VnicArgs{\n\t\t\tHost: pulumi.String(host.Id),\n\t\t\tDistributedSwitchPort: vds.ID(),\n\t\t\tDistributedPortGroup: pg.ID(),\n\t\t\tIpv4: \u0026vsphere.VnicIpv4Args{\n\t\t\t\tDhcp: pulumi.Bool(true),\n\t\t\t},\n\t\t\tNetstack: pulumi.String(\"vmotion\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.DistributedVirtualSwitch;\nimport com.pulumi.vsphere.DistributedVirtualSwitchArgs;\nimport com.pulumi.vsphere.inputs.DistributedVirtualSwitchHostArgs;\nimport com.pulumi.vsphere.DistributedPortGroup;\nimport com.pulumi.vsphere.DistributedPortGroupArgs;\nimport com.pulumi.vsphere.Vnic;\nimport com.pulumi.vsphere.VnicArgs;\nimport com.pulumi.vsphere.inputs.VnicIpv4Args;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var vds = new DistributedVirtualSwitch(\"vds\", DistributedVirtualSwitchArgs.builder()\n .name(\"vds-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .hosts(DistributedVirtualSwitchHostArgs.builder()\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .devices(\"vnic3\")\n .build())\n .build());\n\n var pg = new DistributedPortGroup(\"pg\", DistributedPortGroupArgs.builder()\n .name(\"pg-01\")\n .vlanId(1234)\n .distributedVirtualSwitchUuid(vds.id())\n .build());\n\n var vnic = new Vnic(\"vnic\", VnicArgs.builder()\n .host(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .distributedSwitchPort(vds.id())\n .distributedPortGroup(pg.id())\n .ipv4(VnicIpv4Args.builder()\n .dhcp(true)\n .build())\n .netstack(\"vmotion\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n vds:\n type: vsphere:DistributedVirtualSwitch\n properties:\n name: vds-01\n datacenterId: ${datacenter.id}\n hosts:\n - hostSystemId: ${host.id}\n devices:\n - vnic3\n pg:\n type: vsphere:DistributedPortGroup\n properties:\n name: pg-01\n vlanId: 1234\n distributedVirtualSwitchUuid: ${vds.id}\n vnic:\n type: vsphere:Vnic\n properties:\n host: ${host.id}\n distributedSwitchPort: ${vds.id}\n distributedPortGroup: ${pg.id}\n ipv4:\n dhcp: true\n netstack: vmotion\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a vnic attached to a portgroup using the default TCP/IP stack\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst hvs = new vsphere.HostVirtualSwitch(\"hvs\", {\n name: \"hvs-01\",\n hostSystemId: host.then(host =\u003e host.id),\n networkAdapters: [\n \"vmnic3\",\n \"vmnic4\",\n ],\n activeNics: [\"vmnic3\"],\n standbyNics: [\"vmnic4\"],\n});\nconst pg = new vsphere.HostPortGroup(\"pg\", {\n name: \"pg-01\",\n virtualSwitchName: hvs.name,\n hostSystemId: host.then(host =\u003e host.id),\n});\nconst vnic = new vsphere.Vnic(\"vnic\", {\n host: host.then(host =\u003e host.id),\n portgroup: pg.name,\n ipv4: {\n dhcp: true,\n },\n services: [\n \"vsan\",\n \"management\",\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nhvs = vsphere.HostVirtualSwitch(\"hvs\",\n name=\"hvs-01\",\n host_system_id=host.id,\n network_adapters=[\n \"vmnic3\",\n \"vmnic4\",\n ],\n active_nics=[\"vmnic3\"],\n standby_nics=[\"vmnic4\"])\npg = vsphere.HostPortGroup(\"pg\",\n name=\"pg-01\",\n virtual_switch_name=hvs.name,\n host_system_id=host.id)\nvnic = vsphere.Vnic(\"vnic\",\n host=host.id,\n portgroup=pg.name,\n ipv4={\n \"dhcp\": True,\n },\n services=[\n \"vsan\",\n \"management\",\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hvs = new VSphere.HostVirtualSwitch(\"hvs\", new()\n {\n Name = \"hvs-01\",\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NetworkAdapters = new[]\n {\n \"vmnic3\",\n \"vmnic4\",\n },\n ActiveNics = new[]\n {\n \"vmnic3\",\n },\n StandbyNics = new[]\n {\n \"vmnic4\",\n },\n });\n\n var pg = new VSphere.HostPortGroup(\"pg\", new()\n {\n Name = \"pg-01\",\n VirtualSwitchName = hvs.Name,\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n });\n\n var vnic = new VSphere.Vnic(\"vnic\", new()\n {\n Host = host.Apply(getHostResult =\u003e getHostResult.Id),\n Portgroup = pg.Name,\n Ipv4 = new VSphere.Inputs.VnicIpv4Args\n {\n Dhcp = true,\n },\n Services = new[]\n {\n \"vsan\",\n \"management\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thvs, err := vsphere.NewHostVirtualSwitch(ctx, \"hvs\", \u0026vsphere.HostVirtualSwitchArgs{\n\t\t\tName: pulumi.String(\"hvs-01\"),\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t\tNetworkAdapters: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic3\"),\n\t\t\t\tpulumi.String(\"vmnic4\"),\n\t\t\t},\n\t\t\tActiveNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic3\"),\n\t\t\t},\n\t\t\tStandbyNics: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vmnic4\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tpg, err := vsphere.NewHostPortGroup(ctx, \"pg\", \u0026vsphere.HostPortGroupArgs{\n\t\t\tName: pulumi.String(\"pg-01\"),\n\t\t\tVirtualSwitchName: hvs.Name,\n\t\t\tHostSystemId: pulumi.String(host.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewVnic(ctx, \"vnic\", \u0026vsphere.VnicArgs{\n\t\t\tHost: pulumi.String(host.Id),\n\t\t\tPortgroup: pg.Name,\n\t\t\tIpv4: \u0026vsphere.VnicIpv4Args{\n\t\t\t\tDhcp: pulumi.Bool(true),\n\t\t\t},\n\t\t\tServices: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"vsan\"),\n\t\t\t\tpulumi.String(\"management\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.HostVirtualSwitch;\nimport com.pulumi.vsphere.HostVirtualSwitchArgs;\nimport com.pulumi.vsphere.HostPortGroup;\nimport com.pulumi.vsphere.HostPortGroupArgs;\nimport com.pulumi.vsphere.Vnic;\nimport com.pulumi.vsphere.VnicArgs;\nimport com.pulumi.vsphere.inputs.VnicIpv4Args;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var hvs = new HostVirtualSwitch(\"hvs\", HostVirtualSwitchArgs.builder()\n .name(\"hvs-01\")\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .networkAdapters( \n \"vmnic3\",\n \"vmnic4\")\n .activeNics(\"vmnic3\")\n .standbyNics(\"vmnic4\")\n .build());\n\n var pg = new HostPortGroup(\"pg\", HostPortGroupArgs.builder()\n .name(\"pg-01\")\n .virtualSwitchName(hvs.name())\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .build());\n\n var vnic = new Vnic(\"vnic\", VnicArgs.builder()\n .host(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .portgroup(pg.name())\n .ipv4(VnicIpv4Args.builder()\n .dhcp(true)\n .build())\n .services( \n \"vsan\",\n \"management\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hvs:\n type: vsphere:HostVirtualSwitch\n properties:\n name: hvs-01\n hostSystemId: ${host.id}\n networkAdapters:\n - vmnic3\n - vmnic4\n activeNics:\n - vmnic3\n standbyNics:\n - vmnic4\n pg:\n type: vsphere:HostPortGroup\n properties:\n name: pg-01\n virtualSwitchName: ${hvs.name}\n hostSystemId: ${host.id}\n vnic:\n type: vsphere:Vnic\n properties:\n host: ${host.id}\n portgroup: ${pg.name}\n ipv4:\n dhcp: true\n services:\n - vsan\n - management\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn existing vNic can be imported into this resource\n\nvia supplying the vNic's ID. An example is below:\n\n[docs-import]: /docs/import/index.html\n\n```sh\n$ pulumi import vsphere:index/vnic:Vnic vnic host-123_vmk2\n```\n\nThe above would import the vnic `vmk2` from host with ID `host-123`.\n\n", "properties": { "distributedPortGroup": { "type": "string", @@ -11206,7 +11206,7 @@ }, "functions": { "vsphere:index/getComputeCluster:getComputeCluster": { - "description": "The `vsphere.ComputeCluster` data source can be used to discover the ID of a\ncluster in vSphere. This is useful to fetch the ID of a cluster that you want\nto use for virtual machine placement via the `vsphere.VirtualMachine` resource, allowing to specify the cluster's root resource pool directly versus\nusing the alias available through the `vsphere.ResourcePool`\ndata source.\n\n\u003e You may also wish to see the `vsphere.ComputeCluster`\n resource for more information about clusters and how to managed the resource\n in this provider.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst computeCluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncompute_cluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n computeCluster:\n fn::invoke:\n Function: vsphere:getComputeCluster\n Arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.ComputeCluster` data source can be used to discover the ID of a\ncluster in vSphere. This is useful to fetch the ID of a cluster that you want\nto use for virtual machine placement via the `vsphere.VirtualMachine` resource, allowing to specify the cluster's root resource pool directly versus\nusing the alias available through the `vsphere.ResourcePool`\ndata source.\n\n\u003e You may also wish to see the `vsphere.ComputeCluster`\n resource for more information about clusters and how to managed the resource\n in this provider.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst computeCluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncompute_cluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var computeCluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var computeCluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n computeCluster:\n fn::invoke:\n function: vsphere:getComputeCluster\n arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getComputeCluster.\n", "properties": { @@ -11251,7 +11251,7 @@ } }, "vsphere:index/getComputeClusterHostGroup:getComputeClusterHostGroup": { - "description": "The `vsphere.ComputeClusterHostGroup` data source can be used to discover\nthe IDs ESXi hosts in a host group and return host group attributes to other\nresources.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst cluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst hostGroup = cluster.then(cluster =\u003e vsphere.getComputeClusterHostGroup({\n name: \"hostgroup-01\",\n computeClusterId: cluster.id,\n}));\nconst hostRule = new vsphere.ComputeClusterVmHostRule(\"host_rule\", {\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n name: \"pulumi-host-rule1\",\n vmGroupName: \"vmgroup-01\",\n affinityHostGroupName: hostGroup.then(hostGroup =\u003e hostGroup.name),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nhost_group = vsphere.get_compute_cluster_host_group(name=\"hostgroup-01\",\n compute_cluster_id=cluster.id)\nhost_rule = vsphere.ComputeClusterVmHostRule(\"host_rule\",\n compute_cluster_id=cluster.id,\n name=\"pulumi-host-rule1\",\n vm_group_name=\"vmgroup-01\",\n affinity_host_group_name=host_group.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var cluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hostGroup = VSphere.GetComputeClusterHostGroup.Invoke(new()\n {\n Name = \"hostgroup-01\",\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n });\n\n var hostRule = new VSphere.ComputeClusterVmHostRule(\"host_rule\", new()\n {\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n Name = \"pulumi-host-rule1\",\n VmGroupName = \"vmgroup-01\",\n AffinityHostGroupName = hostGroup.Apply(getComputeClusterHostGroupResult =\u003e getComputeClusterHostGroupResult.Name),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thostGroup, err := vsphere.LookupComputeClusterHostGroup(ctx, \u0026vsphere.LookupComputeClusterHostGroupArgs{\n\t\t\tName: \"hostgroup-01\",\n\t\t\tComputeClusterId: cluster.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewComputeClusterVmHostRule(ctx, \"host_rule\", \u0026vsphere.ComputeClusterVmHostRuleArgs{\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tName: pulumi.String(\"pulumi-host-rule1\"),\n\t\t\tVmGroupName: pulumi.String(\"vmgroup-01\"),\n\t\t\tAffinityHostGroupName: pulumi.String(hostGroup.Name),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterHostGroupArgs;\nimport com.pulumi.vsphere.ComputeClusterVmHostRule;\nimport com.pulumi.vsphere.ComputeClusterVmHostRuleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var cluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var hostGroup = VsphereFunctions.getComputeClusterHostGroup(GetComputeClusterHostGroupArgs.builder()\n .name(\"hostgroup-01\")\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .build());\n\n var hostRule = new ComputeClusterVmHostRule(\"hostRule\", ComputeClusterVmHostRuleArgs.builder()\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .name(\"pulumi-host-rule1\")\n .vmGroupName(\"vmgroup-01\")\n .affinityHostGroupName(hostGroup.applyValue(getComputeClusterHostGroupResult -\u003e getComputeClusterHostGroupResult.name()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hostRule:\n type: vsphere:ComputeClusterVmHostRule\n name: host_rule\n properties:\n computeClusterId: ${cluster.id}\n name: pulumi-host-rule1\n vmGroupName: vmgroup-01\n affinityHostGroupName: ${hostGroup.name}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n cluster:\n fn::invoke:\n Function: vsphere:getComputeCluster\n Arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n hostGroup:\n fn::invoke:\n Function: vsphere:getComputeClusterHostGroup\n Arguments:\n name: hostgroup-01\n computeClusterId: ${cluster.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.ComputeClusterHostGroup` data source can be used to discover\nthe IDs ESXi hosts in a host group and return host group attributes to other\nresources.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst cluster = datacenter.then(datacenter =\u003e vsphere.getComputeCluster({\n name: \"cluster-01\",\n datacenterId: datacenter.id,\n}));\nconst hostGroup = cluster.then(cluster =\u003e vsphere.getComputeClusterHostGroup({\n name: \"hostgroup-01\",\n computeClusterId: cluster.id,\n}));\nconst hostRule = new vsphere.ComputeClusterVmHostRule(\"host_rule\", {\n computeClusterId: cluster.then(cluster =\u003e cluster.id),\n name: \"pulumi-host-rule1\",\n vmGroupName: \"vmgroup-01\",\n affinityHostGroupName: hostGroup.then(hostGroup =\u003e hostGroup.name),\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ncluster = vsphere.get_compute_cluster(name=\"cluster-01\",\n datacenter_id=datacenter.id)\nhost_group = vsphere.get_compute_cluster_host_group(name=\"hostgroup-01\",\n compute_cluster_id=cluster.id)\nhost_rule = vsphere.ComputeClusterVmHostRule(\"host_rule\",\n compute_cluster_id=cluster.id,\n name=\"pulumi-host-rule1\",\n vm_group_name=\"vmgroup-01\",\n affinity_host_group_name=host_group.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var cluster = VSphere.GetComputeCluster.Invoke(new()\n {\n Name = \"cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var hostGroup = VSphere.GetComputeClusterHostGroup.Invoke(new()\n {\n Name = \"hostgroup-01\",\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n });\n\n var hostRule = new VSphere.ComputeClusterVmHostRule(\"host_rule\", new()\n {\n ComputeClusterId = cluster.Apply(getComputeClusterResult =\u003e getComputeClusterResult.Id),\n Name = \"pulumi-host-rule1\",\n VmGroupName = \"vmgroup-01\",\n AffinityHostGroupName = hostGroup.Apply(getComputeClusterHostGroupResult =\u003e getComputeClusterHostGroupResult.Name),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tcluster, err := vsphere.LookupComputeCluster(ctx, \u0026vsphere.LookupComputeClusterArgs{\n\t\t\tName: \"cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thostGroup, err := vsphere.LookupComputeClusterHostGroup(ctx, \u0026vsphere.LookupComputeClusterHostGroupArgs{\n\t\t\tName: \"hostgroup-01\",\n\t\t\tComputeClusterId: cluster.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewComputeClusterVmHostRule(ctx, \"host_rule\", \u0026vsphere.ComputeClusterVmHostRuleArgs{\n\t\t\tComputeClusterId: pulumi.String(cluster.Id),\n\t\t\tName: pulumi.String(\"pulumi-host-rule1\"),\n\t\t\tVmGroupName: pulumi.String(\"vmgroup-01\"),\n\t\t\tAffinityHostGroupName: pulumi.String(hostGroup.Name),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterArgs;\nimport com.pulumi.vsphere.inputs.GetComputeClusterHostGroupArgs;\nimport com.pulumi.vsphere.ComputeClusterVmHostRule;\nimport com.pulumi.vsphere.ComputeClusterVmHostRuleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var cluster = VsphereFunctions.getComputeCluster(GetComputeClusterArgs.builder()\n .name(\"cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var hostGroup = VsphereFunctions.getComputeClusterHostGroup(GetComputeClusterHostGroupArgs.builder()\n .name(\"hostgroup-01\")\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .build());\n\n var hostRule = new ComputeClusterVmHostRule(\"hostRule\", ComputeClusterVmHostRuleArgs.builder()\n .computeClusterId(cluster.applyValue(getComputeClusterResult -\u003e getComputeClusterResult.id()))\n .name(\"pulumi-host-rule1\")\n .vmGroupName(\"vmgroup-01\")\n .affinityHostGroupName(hostGroup.applyValue(getComputeClusterHostGroupResult -\u003e getComputeClusterHostGroupResult.name()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n hostRule:\n type: vsphere:ComputeClusterVmHostRule\n name: host_rule\n properties:\n computeClusterId: ${cluster.id}\n name: pulumi-host-rule1\n vmGroupName: vmgroup-01\n affinityHostGroupName: ${hostGroup.name}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n cluster:\n fn::invoke:\n function: vsphere:getComputeCluster\n arguments:\n name: cluster-01\n datacenterId: ${datacenter.id}\n hostGroup:\n fn::invoke:\n function: vsphere:getComputeClusterHostGroup\n arguments:\n name: hostgroup-01\n computeClusterId: ${cluster.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getComputeClusterHostGroup.\n", "properties": { @@ -11301,7 +11301,7 @@ } }, "vsphere:index/getContentLibrary:getContentLibrary": { - "description": "The `vsphere.ContentLibrary` data source can be used to discover the ID of a\ncontent library.\n\n\u003e **NOTE:** This resource requires vCenter and is not available on direct ESXi\nhost connections.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"Content Library\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncontent_library = vsphere.get_content_library(name=\"Content Library\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"Content Library\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"Content Library\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"Content Library\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n contentLibrary:\n fn::invoke:\n Function: vsphere:getContentLibrary\n Arguments:\n name: Content Library\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.ContentLibrary` data source can be used to discover the ID of a\ncontent library.\n\n\u003e **NOTE:** This resource requires vCenter and is not available on direct ESXi\nhost connections.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst contentLibrary = vsphere.getContentLibrary({\n name: \"Content Library\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncontent_library = vsphere.get_content_library(name=\"Content Library\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var contentLibrary = VSphere.GetContentLibrary.Invoke(new()\n {\n Name = \"Content Library\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupContentLibrary(ctx, \u0026vsphere.LookupContentLibraryArgs{\n\t\t\tName: \"Content Library\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetContentLibraryArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var contentLibrary = VsphereFunctions.getContentLibrary(GetContentLibraryArgs.builder()\n .name(\"Content Library\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n contentLibrary:\n fn::invoke:\n function: vsphere:getContentLibrary\n arguments:\n name: Content Library\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getContentLibrary.\n", "properties": { @@ -11388,7 +11388,7 @@ } }, "vsphere:index/getCustomAttribute:getCustomAttribute": { - "description": "The `vsphere.CustomAttribute` data source can be used to reference custom\nattributes that are not managed by this provider. Its attributes are exactly the\nsame as the `vsphere.CustomAttribute` resource,\nand, like importing, the data source takes a name argument for the search. The\n`id` and other attributes are then populated with the data found by the search.\n\n\u003e **NOTE:** Custom attributes are unsupported on direct ESXi host connections\nand require vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst attribute = vsphere.getCustomAttribute({\n name: \"test-attribute\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nattribute = vsphere.get_custom_attribute(name=\"test-attribute\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var attribute = VSphere.GetCustomAttribute.Invoke(new()\n {\n Name = \"test-attribute\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupCustomAttribute(ctx, \u0026vsphere.LookupCustomAttributeArgs{\n\t\t\tName: \"test-attribute\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetCustomAttributeArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var attribute = VsphereFunctions.getCustomAttribute(GetCustomAttributeArgs.builder()\n .name(\"test-attribute\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n attribute:\n fn::invoke:\n Function: vsphere:getCustomAttribute\n Arguments:\n name: test-attribute\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.CustomAttribute` data source can be used to reference custom\nattributes that are not managed by this provider. Its attributes are exactly the\nsame as the `vsphere.CustomAttribute` resource,\nand, like importing, the data source takes a name argument for the search. The\n`id` and other attributes are then populated with the data found by the search.\n\n\u003e **NOTE:** Custom attributes are unsupported on direct ESXi host connections\nand require vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst attribute = vsphere.getCustomAttribute({\n name: \"test-attribute\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nattribute = vsphere.get_custom_attribute(name=\"test-attribute\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var attribute = VSphere.GetCustomAttribute.Invoke(new()\n {\n Name = \"test-attribute\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupCustomAttribute(ctx, \u0026vsphere.LookupCustomAttributeArgs{\n\t\t\tName: \"test-attribute\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetCustomAttributeArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var attribute = VsphereFunctions.getCustomAttribute(GetCustomAttributeArgs.builder()\n .name(\"test-attribute\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n attribute:\n fn::invoke:\n function: vsphere:getCustomAttribute\n arguments:\n name: test-attribute\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getCustomAttribute.\n", "properties": { @@ -11425,7 +11425,7 @@ } }, "vsphere:index/getDatacenter:getDatacenter": { - "description": "The `vsphere.Datacenter` data source can be used to discover the ID of a\nvSphere datacenter object. This can then be used with resources or data sources\nthat require a datacenter, such as the `vsphere.Host`\ndata source.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.Datacenter` data source can be used to discover the ID of a\nvSphere datacenter object. This can then be used with resources or data sources\nthat require a datacenter, such as the `vsphere.Host`\ndata source.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDatacenter.\n", "properties": { @@ -11462,7 +11462,7 @@ } }, "vsphere:index/getDatastore:getDatastore": { - "description": "The `vsphere.getDatastore` data source can be used to discover the ID of a\nvSphere datastore object. This can then be used with resources or data sources\nthat require a datastore. For example, to create virtual machines in using the\n`vsphere.VirtualMachine` resource.\n\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datastore(name=\"datastore-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n datastore:\n fn::invoke:\n Function: vsphere:getDatastore\n Arguments:\n name: datastore-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.getDatastore` data source can be used to discover the ID of a\nvSphere datastore object. This can then be used with resources or data sources\nthat require a datastore. For example, to create virtual machines in using the\n`vsphere.VirtualMachine` resource.\n\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastore = datacenter.then(datacenter =\u003e vsphere.getDatastore({\n name: \"datastore-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore = vsphere.get_datastore(name=\"datastore-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastore = VSphere.GetDatastore.Invoke(new()\n {\n Name = \"datastore-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetDatastore(ctx, \u0026vsphere.GetDatastoreArgs{\n\t\t\tName: \"datastore-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastore = VsphereFunctions.getDatastore(GetDatastoreArgs.builder()\n .name(\"datastore-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n datastore:\n fn::invoke:\n function: vsphere:getDatastore\n arguments:\n name: datastore-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDatastore.\n", "properties": { @@ -11516,7 +11516,7 @@ } }, "vsphere:index/getDatastoreCluster:getDatastoreCluster": { - "description": "The `vsphere.DatastoreCluster` data source can be used to discover the ID of a\nvSphere datastore cluster object. This can then be used with resources or data sources\nthat require a datastore. For example, to assign datastores using the\n`vsphere.NasDatastore` or `vsphere.VmfsDatastore` resources, or to create virtual machines in using the `vsphere.VirtualMachine` resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastoreCluster = datacenter.then(datacenter =\u003e vsphere.getDatastoreCluster({\n name: \"datastore-cluster-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore_cluster = vsphere.get_datastore_cluster(name=\"datastore-cluster-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastoreCluster = VSphere.GetDatastoreCluster.Invoke(new()\n {\n Name = \"datastore-cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupDatastoreCluster(ctx, \u0026vsphere.LookupDatastoreClusterArgs{\n\t\t\tName: \"datastore-cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreClusterArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastoreCluster = VsphereFunctions.getDatastoreCluster(GetDatastoreClusterArgs.builder()\n .name(\"datastore-cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n datastoreCluster:\n fn::invoke:\n Function: vsphere:getDatastoreCluster\n Arguments:\n name: datastore-cluster-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.DatastoreCluster` data source can be used to discover the ID of a\nvSphere datastore cluster object. This can then be used with resources or data sources\nthat require a datastore. For example, to assign datastores using the\n`vsphere.NasDatastore` or `vsphere.VmfsDatastore` resources, or to create virtual machines in using the `vsphere.VirtualMachine` resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastoreCluster = datacenter.then(datacenter =\u003e vsphere.getDatastoreCluster({\n name: \"datastore-cluster-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore_cluster = vsphere.get_datastore_cluster(name=\"datastore-cluster-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastoreCluster = VSphere.GetDatastoreCluster.Invoke(new()\n {\n Name = \"datastore-cluster-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupDatastoreCluster(ctx, \u0026vsphere.LookupDatastoreClusterArgs{\n\t\t\tName: \"datastore-cluster-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreClusterArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastoreCluster = VsphereFunctions.getDatastoreCluster(GetDatastoreClusterArgs.builder()\n .name(\"datastore-cluster-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n datastoreCluster:\n fn::invoke:\n function: vsphere:getDatastoreCluster\n arguments:\n name: datastore-cluster-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDatastoreCluster.\n", "properties": { @@ -11564,7 +11564,7 @@ } }, "vsphere:index/getDatastoreStats:getDatastoreStats": { - "description": "The `vsphere.getDatastoreStats` data source can be used to retrieve the usage\nstats of all vSphere datastore objects in a datacenter. This can then be used as\na standalone data source to get information required as input to other data\nsources.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastoreStats = datacenter.then(datacenter =\u003e vsphere.getDatastoreStats({\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore_stats = vsphere.get_datastore_stats(datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastoreStats = VSphere.GetDatastoreStats.Invoke(new()\n {\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetDatastoreStats(ctx, \u0026vsphere.GetDatastoreStatsArgs{\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreStatsArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastoreStats = VsphereFunctions.getDatastoreStats(GetDatastoreStatsArgs.builder()\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n datastoreStats:\n fn::invoke:\n Function: vsphere:getDatastoreStats\n Arguments:\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nA useful example of this data source would be to determine the datastore with\nthe most free space. For example, in addition to the above:\n\nCreate an `outputs.tf` like that:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\n\nexport const maxFreeSpaceName = theirMaxFreeSpaceName;\nexport const maxFreeSpace = theirMaxFreeSpace;\n```\n```python\nimport pulumi\n\npulumi.export(\"maxFreeSpaceName\", their_max_free_space_name)\npulumi.export(\"maxFreeSpace\", their_max_free_space)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"maxFreeSpaceName\"] = theirMaxFreeSpaceName,\n [\"maxFreeSpace\"] = theirMaxFreeSpace,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tctx.Export(\"maxFreeSpaceName\", theirMaxFreeSpaceName)\n\t\tctx.Export(\"maxFreeSpace\", theirMaxFreeSpace)\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n ctx.export(\"maxFreeSpaceName\", theirMaxFreeSpaceName);\n ctx.export(\"maxFreeSpace\", theirMaxFreeSpace);\n }\n}\n```\n```yaml\noutputs:\n maxFreeSpaceName: ${theirMaxFreeSpaceName}\n maxFreeSpace: ${theirMaxFreeSpace}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nand a `locals.tf` like that:\n\n", + "description": "The `vsphere.getDatastoreStats` data source can be used to retrieve the usage\nstats of all vSphere datastore objects in a datacenter. This can then be used as\na standalone data source to get information required as input to other data\nsources.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst datastoreStats = datacenter.then(datacenter =\u003e vsphere.getDatastoreStats({\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ndatastore_stats = vsphere.get_datastore_stats(datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var datastoreStats = VSphere.GetDatastoreStats.Invoke(new()\n {\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetDatastoreStats(ctx, \u0026vsphere.GetDatastoreStatsArgs{\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDatastoreStatsArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var datastoreStats = VsphereFunctions.getDatastoreStats(GetDatastoreStatsArgs.builder()\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n datastoreStats:\n fn::invoke:\n function: vsphere:getDatastoreStats\n arguments:\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nA useful example of this data source would be to determine the datastore with\nthe most free space. For example, in addition to the above:\n\nCreate an `outputs.tf` like that:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\n\nexport const maxFreeSpaceName = theirMaxFreeSpaceName;\nexport const maxFreeSpace = theirMaxFreeSpace;\n```\n```python\nimport pulumi\n\npulumi.export(\"maxFreeSpaceName\", their_max_free_space_name)\npulumi.export(\"maxFreeSpace\", their_max_free_space)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"maxFreeSpaceName\"] = theirMaxFreeSpaceName,\n [\"maxFreeSpace\"] = theirMaxFreeSpace,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tctx.Export(\"maxFreeSpaceName\", theirMaxFreeSpaceName)\n\t\tctx.Export(\"maxFreeSpace\", theirMaxFreeSpace)\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n ctx.export(\"maxFreeSpaceName\", theirMaxFreeSpaceName);\n ctx.export(\"maxFreeSpace\", theirMaxFreeSpace);\n }\n}\n```\n```yaml\noutputs:\n maxFreeSpaceName: ${theirMaxFreeSpaceName}\n maxFreeSpace: ${theirMaxFreeSpace}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nand a `locals.tf` like that:\n\n", "inputs": { "description": "A collection of arguments for invoking getDatastoreStats.\n", "properties": { @@ -11626,7 +11626,7 @@ } }, "vsphere:index/getDistributedVirtualSwitch:getDistributedVirtualSwitch": { - "description": "The `vsphere.DistributedVirtualSwitch` data source can be used to discover\nthe ID and uplink data of a of a vSphere distributed switch (VDS). This\ncan then be used with resources or data sources that require a VDS, such as the\n`vsphere.DistributedPortGroup` resource, for which\nan example is shown below.\n\n\u003e **NOTE:** This data source requires vCenter Server and is not available on\ndirect ESXi host connections.\n\n## Example Usage\n\nThe following example locates a distributed switch named `vds-01`, in the\ndatacenter `dc-01`. It then uses this distributed switch to set up a\n`vsphere.DistributedPortGroup` resource that uses the first uplink as a\nprimary uplink and the second uplink as a secondary.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst vds = datacenter.then(datacenter =\u003e vsphere.getDistributedVirtualSwitch({\n name: \"vds-01\",\n datacenterId: datacenter.id,\n}));\nconst dvpg = new vsphere.DistributedPortGroup(\"dvpg\", {\n name: \"dvpg-01\",\n distributedVirtualSwitchUuid: vds.then(vds =\u003e vds.id),\n activeUplinks: [vds.then(vds =\u003e vds.uplinks?.[0])],\n standbyUplinks: [vds.then(vds =\u003e vds.uplinks?.[1])],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nvds = vsphere.get_distributed_virtual_switch(name=\"vds-01\",\n datacenter_id=datacenter.id)\ndvpg = vsphere.DistributedPortGroup(\"dvpg\",\n name=\"dvpg-01\",\n distributed_virtual_switch_uuid=vds.id,\n active_uplinks=[vds.uplinks[0]],\n standby_uplinks=[vds.uplinks[1]])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var vds = VSphere.GetDistributedVirtualSwitch.Invoke(new()\n {\n Name = \"vds-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var dvpg = new VSphere.DistributedPortGroup(\"dvpg\", new()\n {\n Name = \"dvpg-01\",\n DistributedVirtualSwitchUuid = vds.Apply(getDistributedVirtualSwitchResult =\u003e getDistributedVirtualSwitchResult.Id),\n ActiveUplinks = new[]\n {\n vds.Apply(getDistributedVirtualSwitchResult =\u003e getDistributedVirtualSwitchResult.Uplinks[0]),\n },\n StandbyUplinks = new[]\n {\n vds.Apply(getDistributedVirtualSwitchResult =\u003e getDistributedVirtualSwitchResult.Uplinks[1]),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvds, err := vsphere.LookupDistributedVirtualSwitch(ctx, \u0026vsphere.LookupDistributedVirtualSwitchArgs{\n\t\t\tName: \"vds-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewDistributedPortGroup(ctx, \"dvpg\", \u0026vsphere.DistributedPortGroupArgs{\n\t\t\tName: pulumi.String(\"dvpg-01\"),\n\t\t\tDistributedVirtualSwitchUuid: pulumi.String(vds.Id),\n\t\t\tActiveUplinks: pulumi.StringArray{\n\t\t\t\tpulumi.String(vds.Uplinks[0]),\n\t\t\t},\n\t\t\tStandbyUplinks: pulumi.StringArray{\n\t\t\t\tpulumi.String(vds.Uplinks[1]),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDistributedVirtualSwitchArgs;\nimport com.pulumi.vsphere.DistributedPortGroup;\nimport com.pulumi.vsphere.DistributedPortGroupArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var vds = VsphereFunctions.getDistributedVirtualSwitch(GetDistributedVirtualSwitchArgs.builder()\n .name(\"vds-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var dvpg = new DistributedPortGroup(\"dvpg\", DistributedPortGroupArgs.builder()\n .name(\"dvpg-01\")\n .distributedVirtualSwitchUuid(vds.applyValue(getDistributedVirtualSwitchResult -\u003e getDistributedVirtualSwitchResult.id()))\n .activeUplinks(vds.applyValue(getDistributedVirtualSwitchResult -\u003e getDistributedVirtualSwitchResult.uplinks()[0]))\n .standbyUplinks(vds.applyValue(getDistributedVirtualSwitchResult -\u003e getDistributedVirtualSwitchResult.uplinks()[1]))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n dvpg:\n type: vsphere:DistributedPortGroup\n properties:\n name: dvpg-01\n distributedVirtualSwitchUuid: ${vds.id}\n activeUplinks:\n - ${vds.uplinks[0]}\n standbyUplinks:\n - ${vds.uplinks[1]}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n vds:\n fn::invoke:\n Function: vsphere:getDistributedVirtualSwitch\n Arguments:\n name: vds-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.DistributedVirtualSwitch` data source can be used to discover\nthe ID and uplink data of a of a vSphere distributed switch (VDS). This\ncan then be used with resources or data sources that require a VDS, such as the\n`vsphere.DistributedPortGroup` resource, for which\nan example is shown below.\n\n\u003e **NOTE:** This data source requires vCenter Server and is not available on\ndirect ESXi host connections.\n\n## Example Usage\n\nThe following example locates a distributed switch named `vds-01`, in the\ndatacenter `dc-01`. It then uses this distributed switch to set up a\n`vsphere.DistributedPortGroup` resource that uses the first uplink as a\nprimary uplink and the second uplink as a secondary.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst vds = datacenter.then(datacenter =\u003e vsphere.getDistributedVirtualSwitch({\n name: \"vds-01\",\n datacenterId: datacenter.id,\n}));\nconst dvpg = new vsphere.DistributedPortGroup(\"dvpg\", {\n name: \"dvpg-01\",\n distributedVirtualSwitchUuid: vds.then(vds =\u003e vds.id),\n activeUplinks: [vds.then(vds =\u003e vds.uplinks?.[0])],\n standbyUplinks: [vds.then(vds =\u003e vds.uplinks?.[1])],\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nvds = vsphere.get_distributed_virtual_switch(name=\"vds-01\",\n datacenter_id=datacenter.id)\ndvpg = vsphere.DistributedPortGroup(\"dvpg\",\n name=\"dvpg-01\",\n distributed_virtual_switch_uuid=vds.id,\n active_uplinks=[vds.uplinks[0]],\n standby_uplinks=[vds.uplinks[1]])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var vds = VSphere.GetDistributedVirtualSwitch.Invoke(new()\n {\n Name = \"vds-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var dvpg = new VSphere.DistributedPortGroup(\"dvpg\", new()\n {\n Name = \"dvpg-01\",\n DistributedVirtualSwitchUuid = vds.Apply(getDistributedVirtualSwitchResult =\u003e getDistributedVirtualSwitchResult.Id),\n ActiveUplinks = new[]\n {\n vds.Apply(getDistributedVirtualSwitchResult =\u003e getDistributedVirtualSwitchResult.Uplinks[0]),\n },\n StandbyUplinks = new[]\n {\n vds.Apply(getDistributedVirtualSwitchResult =\u003e getDistributedVirtualSwitchResult.Uplinks[1]),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tvds, err := vsphere.LookupDistributedVirtualSwitch(ctx, \u0026vsphere.LookupDistributedVirtualSwitchArgs{\n\t\t\tName: \"vds-01\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.NewDistributedPortGroup(ctx, \"dvpg\", \u0026vsphere.DistributedPortGroupArgs{\n\t\t\tName: pulumi.String(\"dvpg-01\"),\n\t\t\tDistributedVirtualSwitchUuid: pulumi.String(vds.Id),\n\t\t\tActiveUplinks: pulumi.StringArray{\n\t\t\t\tpulumi.String(vds.Uplinks[0]),\n\t\t\t},\n\t\t\tStandbyUplinks: pulumi.StringArray{\n\t\t\t\tpulumi.String(vds.Uplinks[1]),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetDistributedVirtualSwitchArgs;\nimport com.pulumi.vsphere.DistributedPortGroup;\nimport com.pulumi.vsphere.DistributedPortGroupArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var vds = VsphereFunctions.getDistributedVirtualSwitch(GetDistributedVirtualSwitchArgs.builder()\n .name(\"vds-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n var dvpg = new DistributedPortGroup(\"dvpg\", DistributedPortGroupArgs.builder()\n .name(\"dvpg-01\")\n .distributedVirtualSwitchUuid(vds.applyValue(getDistributedVirtualSwitchResult -\u003e getDistributedVirtualSwitchResult.id()))\n .activeUplinks(vds.applyValue(getDistributedVirtualSwitchResult -\u003e getDistributedVirtualSwitchResult.uplinks()[0]))\n .standbyUplinks(vds.applyValue(getDistributedVirtualSwitchResult -\u003e getDistributedVirtualSwitchResult.uplinks()[1]))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n dvpg:\n type: vsphere:DistributedPortGroup\n properties:\n name: dvpg-01\n distributedVirtualSwitchUuid: ${vds.id}\n activeUplinks:\n - ${vds.uplinks[0]}\n standbyUplinks:\n - ${vds.uplinks[1]}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n vds:\n fn::invoke:\n function: vsphere:getDistributedVirtualSwitch\n arguments:\n name: vds-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDistributedVirtualSwitch.\n", "properties": { @@ -11674,7 +11674,7 @@ } }, "vsphere:index/getDynamic:getDynamic": { - "description": "[docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider\n\nThe `vsphere.getDynamic` data source can be used to get the\n[managed object reference ID][docs-about-morefs] of any tagged managed object in\nvCenter Server by providing a list of tag IDs and an optional regular expression\nto filter objects by name.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst category = vsphere.getTagCategory({\n name: \"SomeCategory\",\n});\nconst tag1 = vsphere.getTag({\n name: \"FirstTag\",\n categoryId: cat.id,\n});\nconst tag2 = vsphere.getTag({\n name: \"SecondTag\",\n categoryId: cat.id,\n});\nconst dyn = Promise.all([tag1, tag1]).then(([tag1, tag11]) =\u003e vsphere.getDynamic({\n filters: [\n tag1.id,\n tag11.id,\n ],\n nameRegex: \"ubuntu\",\n type: \"Datacenter\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncategory = vsphere.get_tag_category(name=\"SomeCategory\")\ntag1 = vsphere.get_tag(name=\"FirstTag\",\n category_id=cat[\"id\"])\ntag2 = vsphere.get_tag(name=\"SecondTag\",\n category_id=cat[\"id\"])\ndyn = vsphere.get_dynamic(filters=[\n tag1.id,\n tag1.id,\n ],\n name_regex=\"ubuntu\",\n type=\"Datacenter\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var category = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"SomeCategory\",\n });\n\n var tag1 = VSphere.GetTag.Invoke(new()\n {\n Name = \"FirstTag\",\n CategoryId = cat.Id,\n });\n\n var tag2 = VSphere.GetTag.Invoke(new()\n {\n Name = \"SecondTag\",\n CategoryId = cat.Id,\n });\n\n var dyn = VSphere.GetDynamic.Invoke(new()\n {\n Filters = new[]\n {\n tag1.Apply(getTagResult =\u003e getTagResult.Id),\n tag1.Apply(getTagResult =\u003e getTagResult.Id),\n },\n NameRegex = \"ubuntu\",\n Type = \"Datacenter\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\nfunc main() {\npulumi.Run(func(ctx *pulumi.Context) error {\n_, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\nName: \"SomeCategory\",\n}, nil);\nif err != nil {\nreturn err\n}\ntag1, err := vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\nName: \"FirstTag\",\nCategoryId: cat.Id,\n}, nil);\nif err != nil {\nreturn err\n}\n_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\nName: \"SecondTag\",\nCategoryId: cat.Id,\n}, nil);\nif err != nil {\nreturn err\n}\n_, err = vsphere.GetDynamic(ctx, \u0026vsphere.GetDynamicArgs{\nFilters: interface{}{\ntag1.Id,\ntag1.Id,\n},\nNameRegex: pulumi.StringRef(\"ubuntu\"),\nType: pulumi.StringRef(\"Datacenter\"),\n}, nil);\nif err != nil {\nreturn err\n}\nreturn nil\n})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport com.pulumi.vsphere.inputs.GetTagArgs;\nimport com.pulumi.vsphere.inputs.GetDynamicArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var category = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"SomeCategory\")\n .build());\n\n final var tag1 = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"FirstTag\")\n .categoryId(cat.id())\n .build());\n\n final var tag2 = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"SecondTag\")\n .categoryId(cat.id())\n .build());\n\n final var dyn = VsphereFunctions.getDynamic(GetDynamicArgs.builder()\n .filters( \n tag1.applyValue(getTagResult -\u003e getTagResult.id()),\n tag1.applyValue(getTagResult -\u003e getTagResult.id()))\n .nameRegex(\"ubuntu\")\n .type(\"Datacenter\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n category:\n fn::invoke:\n Function: vsphere:getTagCategory\n Arguments:\n name: SomeCategory\n tag1:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: FirstTag\n categoryId: ${cat.id}\n tag2:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: SecondTag\n categoryId: ${cat.id}\n dyn:\n fn::invoke:\n Function: vsphere:getDynamic\n Arguments:\n filters:\n - ${tag1.id}\n - ${tag1.id}\n nameRegex: ubuntu\n type: Datacenter\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "[docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider\n\nThe `vsphere.getDynamic` data source can be used to get the\n[managed object reference ID][docs-about-morefs] of any tagged managed object in\nvCenter Server by providing a list of tag IDs and an optional regular expression\nto filter objects by name.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst category = vsphere.getTagCategory({\n name: \"SomeCategory\",\n});\nconst tag1 = vsphere.getTag({\n name: \"FirstTag\",\n categoryId: cat.id,\n});\nconst tag2 = vsphere.getTag({\n name: \"SecondTag\",\n categoryId: cat.id,\n});\nconst dyn = Promise.all([tag1, tag1]).then(([tag1, tag11]) =\u003e vsphere.getDynamic({\n filters: [\n tag1.id,\n tag11.id,\n ],\n nameRegex: \"ubuntu\",\n type: \"Datacenter\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncategory = vsphere.get_tag_category(name=\"SomeCategory\")\ntag1 = vsphere.get_tag(name=\"FirstTag\",\n category_id=cat[\"id\"])\ntag2 = vsphere.get_tag(name=\"SecondTag\",\n category_id=cat[\"id\"])\ndyn = vsphere.get_dynamic(filters=[\n tag1.id,\n tag1.id,\n ],\n name_regex=\"ubuntu\",\n type=\"Datacenter\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var category = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"SomeCategory\",\n });\n\n var tag1 = VSphere.GetTag.Invoke(new()\n {\n Name = \"FirstTag\",\n CategoryId = cat.Id,\n });\n\n var tag2 = VSphere.GetTag.Invoke(new()\n {\n Name = \"SecondTag\",\n CategoryId = cat.Id,\n });\n\n var dyn = VSphere.GetDynamic.Invoke(new()\n {\n Filters = new[]\n {\n tag1.Apply(getTagResult =\u003e getTagResult.Id),\n tag1.Apply(getTagResult =\u003e getTagResult.Id),\n },\n NameRegex = \"ubuntu\",\n Type = \"Datacenter\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\nfunc main() {\npulumi.Run(func(ctx *pulumi.Context) error {\n_, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\nName: \"SomeCategory\",\n}, nil);\nif err != nil {\nreturn err\n}\ntag1, err := vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\nName: \"FirstTag\",\nCategoryId: cat.Id,\n}, nil);\nif err != nil {\nreturn err\n}\n_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\nName: \"SecondTag\",\nCategoryId: cat.Id,\n}, nil);\nif err != nil {\nreturn err\n}\n_, err = vsphere.GetDynamic(ctx, \u0026vsphere.GetDynamicArgs{\nFilters: interface{}{\ntag1.Id,\ntag1.Id,\n},\nNameRegex: pulumi.StringRef(\"ubuntu\"),\nType: pulumi.StringRef(\"Datacenter\"),\n}, nil);\nif err != nil {\nreturn err\n}\nreturn nil\n})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport com.pulumi.vsphere.inputs.GetTagArgs;\nimport com.pulumi.vsphere.inputs.GetDynamicArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var category = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"SomeCategory\")\n .build());\n\n final var tag1 = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"FirstTag\")\n .categoryId(cat.id())\n .build());\n\n final var tag2 = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"SecondTag\")\n .categoryId(cat.id())\n .build());\n\n final var dyn = VsphereFunctions.getDynamic(GetDynamicArgs.builder()\n .filters( \n tag1.applyValue(getTagResult -\u003e getTagResult.id()),\n tag1.applyValue(getTagResult -\u003e getTagResult.id()))\n .nameRegex(\"ubuntu\")\n .type(\"Datacenter\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n category:\n fn::invoke:\n function: vsphere:getTagCategory\n arguments:\n name: SomeCategory\n tag1:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: FirstTag\n categoryId: ${cat.id}\n tag2:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: SecondTag\n categoryId: ${cat.id}\n dyn:\n fn::invoke:\n function: vsphere:getDynamic\n arguments:\n filters:\n - ${tag1.id}\n - ${tag1.id}\n nameRegex: ubuntu\n type: Datacenter\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDynamic.\n", "properties": { @@ -11727,7 +11727,7 @@ } }, "vsphere:index/getFolder:getFolder": { - "description": "The `vsphere.Folder` data source can be used to get the general attributes of a\nvSphere inventory folder. The data source supports creating folders of the 5\nmajor types - datacenter folders, host and cluster folders, virtual machine\nfolders, storage folders, and network folders.\n\nPaths are absolute and must include the datacenter.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst folder = vsphere.getFolder({\n path: \"/dc-01/datastore-01/folder-01\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nfolder = vsphere.get_folder(path=\"/dc-01/datastore-01/folder-01\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var folder = VSphere.GetFolder.Invoke(new()\n {\n Path = \"/dc-01/datastore-01/folder-01\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupFolder(ctx, \u0026vsphere.LookupFolderArgs{\n\t\t\tPath: \"/dc-01/datastore-01/folder-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetFolderArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var folder = VsphereFunctions.getFolder(GetFolderArgs.builder()\n .path(\"/dc-01/datastore-01/folder-01\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n folder:\n fn::invoke:\n Function: vsphere:getFolder\n Arguments:\n path: /dc-01/datastore-01/folder-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.Folder` data source can be used to get the general attributes of a\nvSphere inventory folder. The data source supports creating folders of the 5\nmajor types - datacenter folders, host and cluster folders, virtual machine\nfolders, storage folders, and network folders.\n\nPaths are absolute and must include the datacenter.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst folder = vsphere.getFolder({\n path: \"/dc-01/datastore-01/folder-01\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nfolder = vsphere.get_folder(path=\"/dc-01/datastore-01/folder-01\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var folder = VSphere.GetFolder.Invoke(new()\n {\n Path = \"/dc-01/datastore-01/folder-01\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupFolder(ctx, \u0026vsphere.LookupFolderArgs{\n\t\t\tPath: \"/dc-01/datastore-01/folder-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetFolderArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var folder = VsphereFunctions.getFolder(GetFolderArgs.builder()\n .path(\"/dc-01/datastore-01/folder-01\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n folder:\n fn::invoke:\n function: vsphere:getFolder\n arguments:\n path: /dc-01/datastore-01/folder-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getFolder.\n", "properties": { @@ -11760,7 +11760,7 @@ } }, "vsphere:index/getGuestOsCustomization:getGuestOsCustomization": { - "description": "The `vsphere.GuestOsCustomization` data source can be used to discover the\ndetails about a customization specification for a guest operating system.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```yaml\nresources:\n vm:\n type: vsphere:VirtualMachine\n properties:\n templateUuid: ${template.id}\n customizationSpec:\n - id: ${windows.id}\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n template:\n fn::invoke:\n Function: vsphere:getVirtualMachine\n Arguments:\n name: windows-template\n datacenterId: ${datacenter.id}\n windows:\n fn::invoke:\n Function: vsphere:getGuestOsCustomization\n Arguments:\n name: windows\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.GuestOsCustomization` data source can be used to discover the\ndetails about a customization specification for a guest operating system.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```yaml\nresources:\n vm:\n type: vsphere:VirtualMachine\n properties:\n templateUuid: ${template.id}\n customizationSpec:\n - id: ${windows.id}\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n template:\n fn::invoke:\n function: vsphere:getVirtualMachine\n arguments:\n name: windows-template\n datacenterId: ${datacenter.id}\n windows:\n fn::invoke:\n function: vsphere:getGuestOsCustomization\n arguments:\n name: windows\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getGuestOsCustomization.\n", "properties": { @@ -11816,7 +11816,7 @@ } }, "vsphere:index/getHost:getHost": { - "description": "The `vsphere.Host` data source can be used to discover the ID of an ESXi host.\nThis can then be used with resources or data sources that require an ESX\nhost's managed object reference ID.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.Host` data source can be used to discover the ID of an ESXi host.\nThis can then be used with resources or data sources that require an ESX\nhost's managed object reference ID.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getHost.\n", "properties": { @@ -11861,7 +11861,7 @@ } }, "vsphere:index/getHostBaseImages:getHostBaseImages": { - "description": "The `vsphere.getHostBaseImages` data source can be used to get the list of ESXi\nbase images available for cluster software management.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst baseImages = vsphere.getHostBaseImages({});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nbase_images = vsphere.get_host_base_images()\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var baseImages = VSphere.GetHostBaseImages.Invoke();\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetHostBaseImages(ctx, map[string]interface{}{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var baseImages = VsphereFunctions.getHostBaseImages();\n\n }\n}\n```\n```yaml\nvariables:\n baseImages:\n fn::invoke:\n Function: vsphere:getHostBaseImages\n Arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.getHostBaseImages` data source can be used to get the list of ESXi\nbase images available for cluster software management.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst baseImages = vsphere.getHostBaseImages({});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nbase_images = vsphere.get_host_base_images()\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var baseImages = VSphere.GetHostBaseImages.Invoke();\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetHostBaseImages(ctx, map[string]interface{}{}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var baseImages = VsphereFunctions.getHostBaseImages();\n\n }\n}\n```\n```yaml\nvariables:\n baseImages:\n fn::invoke:\n function: vsphere:getHostBaseImages\n arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "outputs": { "description": "A collection of values returned by getHostBaseImages.\n", "properties": { @@ -11885,7 +11885,7 @@ } }, "vsphere:index/getHostPciDevice:getHostPciDevice": { - "description": "The `vsphere.getHostPciDevice` data source can be used to discover the device ID\nof a vSphere host's PCI device. This can then be used with\n`vsphere.VirtualMachine`'s `pci_device_id`.\n\n## Example Usage\n\n### With Vendor ID And Class ID\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst dev = host.then(host =\u003e vsphere.getHostPciDevice({\n hostId: host.id,\n classId: \"123\",\n vendorId: \"456\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\ndev = vsphere.get_host_pci_device(host_id=host.id,\n class_id=\"123\",\n vendor_id=\"456\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var dev = VSphere.GetHostPciDevice.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n ClassId = \"123\",\n VendorId = \"456\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostPciDevice(ctx, \u0026vsphere.GetHostPciDeviceArgs{\n\t\t\tHostId: host.Id,\n\t\t\tClassId: pulumi.StringRef(\"123\"),\n\t\t\tVendorId: pulumi.StringRef(\"456\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostPciDeviceArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var dev = VsphereFunctions.getHostPciDevice(GetHostPciDeviceArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .classId(123)\n .vendorId(456)\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n dev:\n fn::invoke:\n Function: vsphere:getHostPciDevice\n Arguments:\n hostId: ${host.id}\n classId: 123\n vendorId: 456\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n\n### With Name Regular Expression\n\n \u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst dev = host.then(host =\u003e vsphere.getHostPciDevice({\n hostId: host.id,\n nameRegex: \"MMC\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\ndev = vsphere.get_host_pci_device(host_id=host.id,\n name_regex=\"MMC\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var dev = VSphere.GetHostPciDevice.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NameRegex = \"MMC\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostPciDevice(ctx, \u0026vsphere.GetHostPciDeviceArgs{\n\t\t\tHostId: host.Id,\n\t\t\tNameRegex: pulumi.StringRef(\"MMC\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostPciDeviceArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var dev = VsphereFunctions.getHostPciDevice(GetHostPciDeviceArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .nameRegex(\"MMC\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n dev:\n fn::invoke:\n Function: vsphere:getHostPciDevice\n Arguments:\n hostId: ${host.id}\n nameRegex: MMC\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.getHostPciDevice` data source can be used to discover the device ID\nof a vSphere host's PCI device. This can then be used with\n`vsphere.VirtualMachine`'s `pci_device_id`.\n\n## Example Usage\n\n### With Vendor ID And Class ID\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst dev = host.then(host =\u003e vsphere.getHostPciDevice({\n hostId: host.id,\n classId: \"123\",\n vendorId: \"456\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\ndev = vsphere.get_host_pci_device(host_id=host.id,\n class_id=\"123\",\n vendor_id=\"456\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var dev = VSphere.GetHostPciDevice.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n ClassId = \"123\",\n VendorId = \"456\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostPciDevice(ctx, \u0026vsphere.GetHostPciDeviceArgs{\n\t\t\tHostId: host.Id,\n\t\t\tClassId: pulumi.StringRef(\"123\"),\n\t\t\tVendorId: pulumi.StringRef(\"456\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostPciDeviceArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var dev = VsphereFunctions.getHostPciDevice(GetHostPciDeviceArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .classId(123)\n .vendorId(456)\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n dev:\n fn::invoke:\n function: vsphere:getHostPciDevice\n arguments:\n hostId: ${host.id}\n classId: 123\n vendorId: 456\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n\n### With Name Regular Expression\n\n \u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst dev = host.then(host =\u003e vsphere.getHostPciDevice({\n hostId: host.id,\n nameRegex: \"MMC\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\ndev = vsphere.get_host_pci_device(host_id=host.id,\n name_regex=\"MMC\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var dev = VSphere.GetHostPciDevice.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NameRegex = \"MMC\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostPciDevice(ctx, \u0026vsphere.GetHostPciDeviceArgs{\n\t\t\tHostId: host.Id,\n\t\t\tNameRegex: pulumi.StringRef(\"MMC\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostPciDeviceArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var dev = VsphereFunctions.getHostPciDevice(GetHostPciDeviceArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .nameRegex(\"MMC\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n dev:\n fn::invoke:\n function: vsphere:getHostPciDevice\n arguments:\n hostId: ${host.id}\n nameRegex: MMC\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getHostPciDevice.\n", "properties": { @@ -11944,7 +11944,7 @@ } }, "vsphere:index/getHostThumbprint:getHostThumbprint": { - "description": "The `vsphere_thumbprint` data source can be used to discover the host thumbprint\nof an ESXi host. This can be used when adding the `vsphere.Host` resource to a\ncluster or a vCenter Server instance.\n\n* If the ESXi host is using a certificate chain, the first one returned will be\nused to generate the thumbprint.\n\n* If the ESXi host has a certificate issued by a certificate authority, ensure\nthat the the certificate authority is trusted on the system running the plan.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst thumbprint = vsphere.getHostThumbprint({\n address: \"esxi-01.example.com\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nthumbprint = vsphere.get_host_thumbprint(address=\"esxi-01.example.com\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var thumbprint = VSphere.GetHostThumbprint.Invoke(new()\n {\n Address = \"esxi-01.example.com\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetHostThumbprint(ctx, \u0026vsphere.GetHostThumbprintArgs{\n\t\t\tAddress: \"esxi-01.example.com\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetHostThumbprintArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var thumbprint = VsphereFunctions.getHostThumbprint(GetHostThumbprintArgs.builder()\n .address(\"esxi-01.example.com\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n thumbprint:\n fn::invoke:\n Function: vsphere:getHostThumbprint\n Arguments:\n address: esxi-01.example.com\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere_thumbprint` data source can be used to discover the host thumbprint\nof an ESXi host. This can be used when adding the `vsphere.Host` resource to a\ncluster or a vCenter Server instance.\n\n* If the ESXi host is using a certificate chain, the first one returned will be\nused to generate the thumbprint.\n\n* If the ESXi host has a certificate issued by a certificate authority, ensure\nthat the the certificate authority is trusted on the system running the plan.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst thumbprint = vsphere.getHostThumbprint({\n address: \"esxi-01.example.com\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nthumbprint = vsphere.get_host_thumbprint(address=\"esxi-01.example.com\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var thumbprint = VSphere.GetHostThumbprint.Invoke(new()\n {\n Address = \"esxi-01.example.com\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetHostThumbprint(ctx, \u0026vsphere.GetHostThumbprintArgs{\n\t\t\tAddress: \"esxi-01.example.com\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetHostThumbprintArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var thumbprint = VsphereFunctions.getHostThumbprint(GetHostThumbprintArgs.builder()\n .address(\"esxi-01.example.com\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n thumbprint:\n fn::invoke:\n function: vsphere:getHostThumbprint\n arguments:\n address: esxi-01.example.com\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getHostThumbprint.\n", "properties": { @@ -11991,7 +11991,7 @@ } }, "vsphere:index/getHostVgpuProfile:getHostVgpuProfile": { - "description": "The `vsphere.getHostVgpuProfile` data source can be used to discover the\navailable vGPU profiles of a vSphere host.\n\n## Example Usage\n\n### To Return All VGPU Profiles\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vgpuProfile = host.then(host =\u003e vsphere.getHostVgpuProfile({\n hostId: host.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vgpuProfile = VSphere.GetHostVgpuProfile.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostVgpuProfile(ctx, \u0026vsphere.GetHostVgpuProfileArgs{\n\t\t\tHostId: host.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostVgpuProfileArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var vgpuProfile = VsphereFunctions.getHostVgpuProfile(GetHostVgpuProfileArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n vgpuProfile:\n fn::invoke:\n Function: vsphere:getHostVgpuProfile\n Arguments:\n hostId: ${host.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n\n### With VGPU Profile Name_regex\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vgpuProfile = host.then(host =\u003e vsphere.getHostVgpuProfile({\n hostId: host.id,\n nameRegex: \"a100\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id,\n name_regex=\"a100\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vgpuProfile = VSphere.GetHostVgpuProfile.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NameRegex = \"a100\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostVgpuProfile(ctx, \u0026vsphere.GetHostVgpuProfileArgs{\n\t\t\tHostId: host.Id,\n\t\t\tNameRegex: pulumi.StringRef(\"a100\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostVgpuProfileArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var vgpuProfile = VsphereFunctions.getHostVgpuProfile(GetHostVgpuProfileArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .nameRegex(\"a100\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n vgpuProfile:\n fn::invoke:\n Function: vsphere:getHostVgpuProfile\n Arguments:\n hostId: ${host.id}\n nameRegex: a100\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.getHostVgpuProfile` data source can be used to discover the\navailable vGPU profiles of a vSphere host.\n\n## Example Usage\n\n### To Return All VGPU Profiles\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vgpuProfile = host.then(host =\u003e vsphere.getHostVgpuProfile({\n hostId: host.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vgpuProfile = VSphere.GetHostVgpuProfile.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostVgpuProfile(ctx, \u0026vsphere.GetHostVgpuProfileArgs{\n\t\t\tHostId: host.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostVgpuProfileArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var vgpuProfile = VsphereFunctions.getHostVgpuProfile(GetHostVgpuProfileArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n vgpuProfile:\n fn::invoke:\n function: vsphere:getHostVgpuProfile\n arguments:\n hostId: ${host.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n\n### With VGPU Profile Name_regex\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vgpuProfile = host.then(host =\u003e vsphere.getHostVgpuProfile({\n hostId: host.id,\n nameRegex: \"a100\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvgpu_profile = vsphere.get_host_vgpu_profile(host_id=host.id,\n name_regex=\"a100\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vgpuProfile = VSphere.GetHostVgpuProfile.Invoke(new()\n {\n HostId = host.Apply(getHostResult =\u003e getHostResult.Id),\n NameRegex = \"a100\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetHostVgpuProfile(ctx, \u0026vsphere.GetHostVgpuProfileArgs{\n\t\t\tHostId: host.Id,\n\t\t\tNameRegex: pulumi.StringRef(\"a100\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetHostVgpuProfileArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var vgpuProfile = VsphereFunctions.getHostVgpuProfile(GetHostVgpuProfileArgs.builder()\n .hostId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .nameRegex(\"a100\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n vgpuProfile:\n fn::invoke:\n function: vsphere:getHostVgpuProfile\n arguments:\n hostId: ${host.id}\n nameRegex: a100\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getHostVgpuProfile.\n", "properties": { @@ -12041,7 +12041,7 @@ } }, "vsphere:index/getLicense:getLicense": { - "description": "The `vsphere.License` data source can be used to get the general attributes of\na license keys from a vCenter Server instance.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst license = vsphere.getLicense({\n licenseKey: \"00000-00000-00000-00000-00000\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nlicense = vsphere.get_license(license_key=\"00000-00000-00000-00000-00000\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var license = VSphere.GetLicense.Invoke(new()\n {\n LicenseKey = \"00000-00000-00000-00000-00000\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupLicense(ctx, \u0026vsphere.LookupLicenseArgs{\n\t\t\tLicenseKey: \"00000-00000-00000-00000-00000\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetLicenseArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var license = VsphereFunctions.getLicense(GetLicenseArgs.builder()\n .licenseKey(\"00000-00000-00000-00000-00000\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n license:\n fn::invoke:\n Function: vsphere:getLicense\n Arguments:\n licenseKey: 00000-00000-00000-00000-00000\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.License` data source can be used to get the general attributes of\na license keys from a vCenter Server instance.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst license = vsphere.getLicense({\n licenseKey: \"00000-00000-00000-00000-00000\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nlicense = vsphere.get_license(license_key=\"00000-00000-00000-00000-00000\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var license = VSphere.GetLicense.Invoke(new()\n {\n LicenseKey = \"00000-00000-00000-00000-00000\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupLicense(ctx, \u0026vsphere.LookupLicenseArgs{\n\t\t\tLicenseKey: \"00000-00000-00000-00000-00000\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetLicenseArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var license = VsphereFunctions.getLicense(GetLicenseArgs.builder()\n .licenseKey(\"00000-00000-00000-00000-00000\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n license:\n fn::invoke:\n function: vsphere:getLicense\n arguments:\n licenseKey: 00000-00000-00000-00000-00000\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getLicense.\n", "properties": { @@ -12101,7 +12101,7 @@ } }, "vsphere:index/getNetwork:getNetwork": { - "description": "The `vsphere.getNetwork` data source can be used to discover the ID of a network in\nvSphere. This can be any network that can be used as the backing for a network\ninterface for `vsphere.VirtualMachine` or any other vSphere resource that\nrequires a network. This includes standard (host-based) port groups, distributed\nport groups, or opaque networks such as those managed by NSX.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"VM Network\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nnetwork = vsphere.get_network(name=\"VM Network\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"VM Network\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"VM Network\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"VM Network\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n network:\n fn::invoke:\n Function: vsphere:getNetwork\n Arguments:\n name: VM Network\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n\n### Additional Examples\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst myPortGroup = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n datacenterId: datacenter.id,\n name: \"VM Network\",\n filters: [{\n networkType: \"Network\",\n }],\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nmy_port_group = vsphere.get_network(datacenter_id=datacenter.id,\n name=\"VM Network\",\n filters=[{\n \"network_type\": \"Network\",\n }])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var myPortGroup = VSphere.GetNetwork.Invoke(new()\n {\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n Name = \"VM Network\",\n Filters = new[]\n {\n new VSphere.Inputs.GetNetworkFilterInputArgs\n {\n NetworkType = \"Network\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t\tName: \"VM Network\",\n\t\t\tFilters: []vsphere.GetNetworkFilter{\n\t\t\t\t{\n\t\t\t\t\tNetworkType: pulumi.StringRef(\"Network\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var myPortGroup = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .name(\"VM Network\")\n .filters(GetNetworkFilterArgs.builder()\n .networkType(\"Network\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n myPortGroup:\n fn::invoke:\n Function: vsphere:getNetwork\n Arguments:\n datacenterId: ${datacenter.id}\n name: VM Network\n filters:\n - networkType: Network\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.getNetwork` data source can be used to discover the ID of a network in\nvSphere. This can be any network that can be used as the backing for a network\ninterface for `vsphere.VirtualMachine` or any other vSphere resource that\nrequires a network. This includes standard (host-based) port groups, distributed\nport groups, or opaque networks such as those managed by NSX.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst network = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n name: \"VM Network\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nnetwork = vsphere.get_network(name=\"VM Network\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var network = VSphere.GetNetwork.Invoke(new()\n {\n Name = \"VM Network\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tName: \"VM Network\",\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var network = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .name(\"VM Network\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n network:\n fn::invoke:\n function: vsphere:getNetwork\n arguments:\n name: VM Network\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n\n### Additional Examples\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst myPortGroup = datacenter.then(datacenter =\u003e vsphere.getNetwork({\n datacenterId: datacenter.id,\n name: \"VM Network\",\n filters: [{\n networkType: \"Network\",\n }],\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nmy_port_group = vsphere.get_network(datacenter_id=datacenter.id,\n name=\"VM Network\",\n filters=[{\n \"network_type\": \"Network\",\n }])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var myPortGroup = VSphere.GetNetwork.Invoke(new()\n {\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n Name = \"VM Network\",\n Filters = new[]\n {\n new VSphere.Inputs.GetNetworkFilterInputArgs\n {\n NetworkType = \"Network\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetNetwork(ctx, \u0026vsphere.GetNetworkArgs{\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t\tName: \"VM Network\",\n\t\t\tFilters: []vsphere.GetNetworkFilter{\n\t\t\t\t{\n\t\t\t\t\tNetworkType: pulumi.StringRef(\"Network\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetNetworkArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var myPortGroup = VsphereFunctions.getNetwork(GetNetworkArgs.builder()\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .name(\"VM Network\")\n .filters(GetNetworkFilterArgs.builder()\n .networkType(\"Network\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n myPortGroup:\n fn::invoke:\n function: vsphere:getNetwork\n arguments:\n datacenterId: ${datacenter.id}\n name: VM Network\n filters:\n - networkType: Network\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getNetwork.\n", "properties": { @@ -12388,7 +12388,7 @@ } }, "vsphere:index/getPolicy:getPolicy": { - "description": "The `vsphere.getPolicy` data source can be used to discover the UUID of a\nstorage policy. This can then be used with other resources or data sources that\nuse a storage policy.\n\n\u003e **NOTE:** Storage policies are not supported on direct ESXi hosts and\nrequires vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst prodPlatinumReplicated = vsphere.getPolicy({\n name: \"prod_platinum_replicated\",\n});\nconst devSilverNonreplicated = vsphere.getPolicy({\n name: \"dev_silver_nonreplicated\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nprod_platinum_replicated = vsphere.get_policy(name=\"prod_platinum_replicated\")\ndev_silver_nonreplicated = vsphere.get_policy(name=\"dev_silver_nonreplicated\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var prodPlatinumReplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"prod_platinum_replicated\",\n });\n\n var devSilverNonreplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"dev_silver_nonreplicated\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"prod_platinum_replicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"dev_silver_nonreplicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetPolicyArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var prodPlatinumReplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"prod_platinum_replicated\")\n .build());\n\n final var devSilverNonreplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"dev_silver_nonreplicated\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n prodPlatinumReplicated:\n fn::invoke:\n Function: vsphere:getPolicy\n Arguments:\n name: prod_platinum_replicated\n devSilverNonreplicated:\n fn::invoke:\n Function: vsphere:getPolicy\n Arguments:\n name: dev_silver_nonreplicated\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.getPolicy` data source can be used to discover the UUID of a\nstorage policy. This can then be used with other resources or data sources that\nuse a storage policy.\n\n\u003e **NOTE:** Storage policies are not supported on direct ESXi hosts and\nrequires vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst prodPlatinumReplicated = vsphere.getPolicy({\n name: \"prod_platinum_replicated\",\n});\nconst devSilverNonreplicated = vsphere.getPolicy({\n name: \"dev_silver_nonreplicated\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nprod_platinum_replicated = vsphere.get_policy(name=\"prod_platinum_replicated\")\ndev_silver_nonreplicated = vsphere.get_policy(name=\"dev_silver_nonreplicated\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var prodPlatinumReplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"prod_platinum_replicated\",\n });\n\n var devSilverNonreplicated = VSphere.GetPolicy.Invoke(new()\n {\n Name = \"dev_silver_nonreplicated\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"prod_platinum_replicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetPolicy(ctx, \u0026vsphere.GetPolicyArgs{\n\t\t\tName: \"dev_silver_nonreplicated\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetPolicyArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var prodPlatinumReplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"prod_platinum_replicated\")\n .build());\n\n final var devSilverNonreplicated = VsphereFunctions.getPolicy(GetPolicyArgs.builder()\n .name(\"dev_silver_nonreplicated\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n prodPlatinumReplicated:\n fn::invoke:\n function: vsphere:getPolicy\n arguments:\n name: prod_platinum_replicated\n devSilverNonreplicated:\n fn::invoke:\n function: vsphere:getPolicy\n arguments:\n name: dev_silver_nonreplicated\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getPolicy.\n", "properties": { @@ -12421,7 +12421,7 @@ } }, "vsphere:index/getResourcePool:getResourcePool": { - "description": "The `vsphere.ResourcePool` data source can be used to discover the ID of a\nresource pool in vSphere. This is useful to return the ID of a resource pool\nthat you want to use to create virtual machines in using the\n`vsphere.VirtualMachine` resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst pool = datacenter.then(datacenter =\u003e vsphere.getResourcePool({\n name: \"resource-pool-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\npool = vsphere.get_resource_pool(name=\"resource-pool-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var pool = VSphere.GetResourcePool.Invoke(new()\n {\n Name = \"resource-pool-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupResourcePool(ctx, \u0026vsphere.LookupResourcePoolArgs{\n\t\t\tName: pulumi.StringRef(\"resource-pool-01\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetResourcePoolArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var pool = VsphereFunctions.getResourcePool(GetResourcePoolArgs.builder()\n .name(\"resource-pool-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n pool:\n fn::invoke:\n Function: vsphere:getResourcePool\n Arguments:\n name: resource-pool-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Specifying the Root Resource Pool for a Standalone ESXi Host\n\n\u003e **NOTE:** Returning the root resource pool for a cluster can be done\ndirectly via the `vsphere.ComputeCluster`\ndata source.\n\nAll compute resources in vSphere have a resource pool, even if one has not been\nexplicitly created. This resource pool is referred to as the _root resource\npool_ and can be looked up by specifying the path.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst pool = vsphere.getResourcePool({\n name: \"esxi-01.example.com/Resources\",\n datacenterId: datacenter.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\npool = vsphere.get_resource_pool(name=\"esxi-01.example.com/Resources\",\n datacenter_id=datacenter[\"id\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var pool = VSphere.GetResourcePool.Invoke(new()\n {\n Name = \"esxi-01.example.com/Resources\",\n DatacenterId = datacenter.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupResourcePool(ctx, \u0026vsphere.LookupResourcePoolArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com/Resources\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetResourcePoolArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var pool = VsphereFunctions.getResourcePool(GetResourcePoolArgs.builder()\n .name(\"esxi-01.example.com/Resources\")\n .datacenterId(datacenter.id())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n pool:\n fn::invoke:\n Function: vsphere:getResourcePool\n Arguments:\n name: esxi-01.example.com/Resources\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nFor more information on the root resource pool, see\n[Managing Resource Pools][vmware-docs-resource-pools] in the vSphere\ndocumentation.\n\n[vmware-docs-resource-pools]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-resource-management/GUID-60077B40-66FF-4625-934A-641703ED7601.html\n", + "description": "The `vsphere.ResourcePool` data source can be used to discover the ID of a\nresource pool in vSphere. This is useful to return the ID of a resource pool\nthat you want to use to create virtual machines in using the\n`vsphere.VirtualMachine` resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst pool = datacenter.then(datacenter =\u003e vsphere.getResourcePool({\n name: \"resource-pool-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\npool = vsphere.get_resource_pool(name=\"resource-pool-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var pool = VSphere.GetResourcePool.Invoke(new()\n {\n Name = \"resource-pool-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupResourcePool(ctx, \u0026vsphere.LookupResourcePoolArgs{\n\t\t\tName: pulumi.StringRef(\"resource-pool-01\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetResourcePoolArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var pool = VsphereFunctions.getResourcePool(GetResourcePoolArgs.builder()\n .name(\"resource-pool-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n pool:\n fn::invoke:\n function: vsphere:getResourcePool\n arguments:\n name: resource-pool-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Specifying the Root Resource Pool for a Standalone ESXi Host\n\n\u003e **NOTE:** Returning the root resource pool for a cluster can be done\ndirectly via the `vsphere.ComputeCluster`\ndata source.\n\nAll compute resources in vSphere have a resource pool, even if one has not been\nexplicitly created. This resource pool is referred to as the _root resource\npool_ and can be looked up by specifying the path.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst pool = vsphere.getResourcePool({\n name: \"esxi-01.example.com/Resources\",\n datacenterId: datacenter.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\npool = vsphere.get_resource_pool(name=\"esxi-01.example.com/Resources\",\n datacenter_id=datacenter[\"id\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var pool = VSphere.GetResourcePool.Invoke(new()\n {\n Name = \"esxi-01.example.com/Resources\",\n DatacenterId = datacenter.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupResourcePool(ctx, \u0026vsphere.LookupResourcePoolArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com/Resources\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetResourcePoolArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var pool = VsphereFunctions.getResourcePool(GetResourcePoolArgs.builder()\n .name(\"esxi-01.example.com/Resources\")\n .datacenterId(datacenter.id())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n pool:\n fn::invoke:\n function: vsphere:getResourcePool\n arguments:\n name: esxi-01.example.com/Resources\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nFor more information on the root resource pool, see\n[Managing Resource Pools][vmware-docs-resource-pools] in the vSphere\ndocumentation.\n\n[vmware-docs-resource-pools]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-resource-management/GUID-60077B40-66FF-4625-934A-641703ED7601.html\n", "inputs": { "description": "A collection of arguments for invoking getResourcePool.\n", "properties": { @@ -12457,7 +12457,7 @@ } }, "vsphere:index/getRole:getRole": { - "description": "The `vsphere.Role` data source can be used to discover the `id` and privileges\nassociated with a role given its name or display label.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst terraformRole = vsphere.getRole({\n label: \"Terraform to vSphere Integration Role\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nterraform_role = vsphere.get_role(label=\"Terraform to vSphere Integration Role\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var terraformRole = VSphere.GetRole.Invoke(new()\n {\n Label = \"Terraform to vSphere Integration Role\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupRole(ctx, \u0026vsphere.LookupRoleArgs{\n\t\t\tLabel: \"Terraform to vSphere Integration Role\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetRoleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var terraformRole = VsphereFunctions.getRole(GetRoleArgs.builder()\n .label(\"Terraform to vSphere Integration Role\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n terraformRole:\n fn::invoke:\n Function: vsphere:getRole\n Arguments:\n label: Terraform to vSphere Integration Role\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.Role` data source can be used to discover the `id` and privileges\nassociated with a role given its name or display label.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst terraformRole = vsphere.getRole({\n label: \"Terraform to vSphere Integration Role\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\nterraform_role = vsphere.get_role(label=\"Terraform to vSphere Integration Role\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var terraformRole = VSphere.GetRole.Invoke(new()\n {\n Label = \"Terraform to vSphere Integration Role\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupRole(ctx, \u0026vsphere.LookupRoleArgs{\n\t\t\tLabel: \"Terraform to vSphere Integration Role\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetRoleArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var terraformRole = VsphereFunctions.getRole(GetRoleArgs.builder()\n .label(\"Terraform to vSphere Integration Role\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n terraformRole:\n fn::invoke:\n function: vsphere:getRole\n arguments:\n label: Terraform to vSphere Integration Role\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getRole.\n", "properties": { @@ -12519,7 +12519,7 @@ } }, "vsphere:index/getTag:getTag": { - "description": "The `vsphere.Tag` data source can be used to reference tags that are not\nmanaged by this provider. Its attributes are exactly the same as the `vsphere.Tag`\nresource, and, like importing, the data source takes a name and\ncategory to search on. The `id` and other attributes are then populated with\nthe data found by the search.\n\n\u003e **NOTE:** Tagging is not supported on direct ESXi hosts connections and\nrequires vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst category = vsphere.getTagCategory({\n name: \"example-category\",\n});\nconst tag = category.then(category =\u003e vsphere.getTag({\n name: \"example-tag\",\n categoryId: category.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncategory = vsphere.get_tag_category(name=\"example-category\")\ntag = vsphere.get_tag(name=\"example-tag\",\n category_id=category.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var category = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"example-category\",\n });\n\n var tag = VSphere.GetTag.Invoke(new()\n {\n Name = \"example-tag\",\n CategoryId = category.Apply(getTagCategoryResult =\u003e getTagCategoryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tcategory, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"example-category\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"example-tag\",\n\t\t\tCategoryId: category.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport com.pulumi.vsphere.inputs.GetTagArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var category = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"example-category\")\n .build());\n\n final var tag = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"example-tag\")\n .categoryId(category.applyValue(getTagCategoryResult -\u003e getTagCategoryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n category:\n fn::invoke:\n Function: vsphere:getTagCategory\n Arguments:\n name: example-category\n tag:\n fn::invoke:\n Function: vsphere:getTag\n Arguments:\n name: example-tag\n categoryId: ${category.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.Tag` data source can be used to reference tags that are not\nmanaged by this provider. Its attributes are exactly the same as the `vsphere.Tag`\nresource, and, like importing, the data source takes a name and\ncategory to search on. The `id` and other attributes are then populated with\nthe data found by the search.\n\n\u003e **NOTE:** Tagging is not supported on direct ESXi hosts connections and\nrequires vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst category = vsphere.getTagCategory({\n name: \"example-category\",\n});\nconst tag = category.then(category =\u003e vsphere.getTag({\n name: \"example-tag\",\n categoryId: category.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncategory = vsphere.get_tag_category(name=\"example-category\")\ntag = vsphere.get_tag(name=\"example-tag\",\n category_id=category.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var category = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"example-category\",\n });\n\n var tag = VSphere.GetTag.Invoke(new()\n {\n Name = \"example-tag\",\n CategoryId = category.Apply(getTagCategoryResult =\u003e getTagCategoryResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tcategory, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"example-category\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupTag(ctx, \u0026vsphere.LookupTagArgs{\n\t\t\tName: \"example-tag\",\n\t\t\tCategoryId: category.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport com.pulumi.vsphere.inputs.GetTagArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var category = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"example-category\")\n .build());\n\n final var tag = VsphereFunctions.getTag(GetTagArgs.builder()\n .name(\"example-tag\")\n .categoryId(category.applyValue(getTagCategoryResult -\u003e getTagCategoryResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n category:\n fn::invoke:\n function: vsphere:getTagCategory\n arguments:\n name: example-category\n tag:\n fn::invoke:\n function: vsphere:getTag\n arguments:\n name: example-tag\n categoryId: ${category.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getTag.\n", "properties": { @@ -12565,7 +12565,7 @@ } }, "vsphere:index/getTagCategory:getTagCategory": { - "description": "The `vsphere.TagCategory` data source can be used to reference tag categories\nthat are not managed by this provider. Its attributes are the same as the\n`vsphere.TagCategory` resource, and, like importing,\nthe data source uses a name and category as search criteria. The `id` and other\nattributes are populated with the data found by the search.\n\n\u003e **NOTE:** Tagging is not supported on direct ESXi hosts connections and\nrequires vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst category = vsphere.getTagCategory({\n name: \"example-category\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncategory = vsphere.get_tag_category(name=\"example-category\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var category = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"example-category\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"example-category\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var category = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"example-category\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n category:\n fn::invoke:\n Function: vsphere:getTagCategory\n Arguments:\n name: example-category\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.TagCategory` data source can be used to reference tag categories\nthat are not managed by this provider. Its attributes are the same as the\n`vsphere.TagCategory` resource, and, like importing,\nthe data source uses a name and category as search criteria. The `id` and other\nattributes are populated with the data found by the search.\n\n\u003e **NOTE:** Tagging is not supported on direct ESXi hosts connections and\nrequires vCenter Server.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst category = vsphere.getTagCategory({\n name: \"example-category\",\n});\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ncategory = vsphere.get_tag_category(name=\"example-category\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var category = VSphere.GetTagCategory.Invoke(new()\n {\n Name = \"example-category\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := vsphere.LookupTagCategory(ctx, \u0026vsphere.LookupTagCategoryArgs{\n\t\t\tName: \"example-category\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetTagCategoryArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var category = VsphereFunctions.getTagCategory(GetTagCategoryArgs.builder()\n .name(\"example-category\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n category:\n fn::invoke:\n function: vsphere:getTagCategory\n arguments:\n name: example-category\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getTagCategory.\n", "properties": { @@ -12613,7 +12613,7 @@ } }, "vsphere:index/getVappContainer:getVappContainer": { - "description": "The `vsphere.VappContainer` data source can be used to discover the ID of a\nvApp container in vSphere. This is useful to return the ID of a vApp container\nthat you want to use to create virtual machines in using the\n`vsphere.VirtualMachine` resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst pool = datacenter.then(datacenter =\u003e vsphere.getVappContainer({\n name: \"vapp-container-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\npool = vsphere.get_vapp_container(name=\"vapp-container-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var pool = VSphere.GetVappContainer.Invoke(new()\n {\n Name = \"vapp-container-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVappContainer(ctx, \u0026vsphere.LookupVappContainerArgs{\n\t\t\tName: \"vapp-container-01\",\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetVappContainerArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var pool = VsphereFunctions.getVappContainer(GetVappContainerArgs.builder()\n .name(\"vapp-container-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n pool:\n fn::invoke:\n Function: vsphere:getVappContainer\n Arguments:\n name: vapp-container-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.VappContainer` data source can be used to discover the ID of a\nvApp container in vSphere. This is useful to return the ID of a vApp container\nthat you want to use to create virtual machines in using the\n`vsphere.VirtualMachine` resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst pool = datacenter.then(datacenter =\u003e vsphere.getVappContainer({\n name: \"vapp-container-01\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\npool = vsphere.get_vapp_container(name=\"vapp-container-01\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var pool = VSphere.GetVappContainer.Invoke(new()\n {\n Name = \"vapp-container-01\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVappContainer(ctx, \u0026vsphere.LookupVappContainerArgs{\n\t\t\tName: \"vapp-container-01\",\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetVappContainerArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var pool = VsphereFunctions.getVappContainer(GetVappContainerArgs.builder()\n .name(\"vapp-container-01\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n pool:\n fn::invoke:\n function: vsphere:getVappContainer\n arguments:\n name: vapp-container-01\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getVappContainer.\n", "properties": { @@ -12655,7 +12655,7 @@ } }, "vsphere:index/getVirtualMachine:getVirtualMachine": { - "description": "The `vsphere.VirtualMachine` data source can be used to find the UUID of an\nexisting virtual machine or template. The most common purpose is for finding\nthe UUID of a template to be used as the source for cloning to a new\n`vsphere.VirtualMachine` resource. It also\nreads the guest ID so that can be supplied as well.\n\n## Example Usage\n\nIn the following example, a virtual machine template is returned by its unique\nname within the `vsphere.Datacenter`.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst template = datacenter.then(datacenter =\u003e vsphere.getVirtualMachine({\n name: \"ubuntu-server-template\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ntemplate = vsphere.get_virtual_machine(name=\"ubuntu-server-template\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var template = VSphere.GetVirtualMachine.Invoke(new()\n {\n Name = \"ubuntu-server-template\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVirtualMachine(ctx, \u0026vsphere.LookupVirtualMachineArgs{\n\t\t\tName: pulumi.StringRef(\"ubuntu-server-template\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetVirtualMachineArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var template = VsphereFunctions.getVirtualMachine(GetVirtualMachineArgs.builder()\n .name(\"ubuntu-server-template\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n template:\n fn::invoke:\n Function: vsphere:getVirtualMachine\n Arguments:\n name: ubuntu-server-template\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nIn the following example, each virtual machine template is returned by its\nunique full path within the `vsphere.Datacenter`.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst productionTemplate = datacenter.then(datacenter =\u003e vsphere.getVirtualMachine({\n name: \"production/templates/ubuntu-server-template\",\n datacenterId: datacenter.id,\n}));\nconst developmentTemplate = datacenter.then(datacenter =\u003e vsphere.getVirtualMachine({\n name: \"development/templates/ubuntu-server-template\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nproduction_template = vsphere.get_virtual_machine(name=\"production/templates/ubuntu-server-template\",\n datacenter_id=datacenter.id)\ndevelopment_template = vsphere.get_virtual_machine(name=\"development/templates/ubuntu-server-template\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var productionTemplate = VSphere.GetVirtualMachine.Invoke(new()\n {\n Name = \"production/templates/ubuntu-server-template\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var developmentTemplate = VSphere.GetVirtualMachine.Invoke(new()\n {\n Name = \"development/templates/ubuntu-server-template\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVirtualMachine(ctx, \u0026vsphere.LookupVirtualMachineArgs{\n\t\t\tName: pulumi.StringRef(\"production/templates/ubuntu-server-template\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVirtualMachine(ctx, \u0026vsphere.LookupVirtualMachineArgs{\n\t\t\tName: pulumi.StringRef(\"development/templates/ubuntu-server-template\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetVirtualMachineArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var productionTemplate = VsphereFunctions.getVirtualMachine(GetVirtualMachineArgs.builder()\n .name(\"production/templates/ubuntu-server-template\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var developmentTemplate = VsphereFunctions.getVirtualMachine(GetVirtualMachineArgs.builder()\n .name(\"development/templates/ubuntu-server-template\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n productionTemplate:\n fn::invoke:\n Function: vsphere:getVirtualMachine\n Arguments:\n name: production/templates/ubuntu-server-template\n datacenterId: ${datacenter.id}\n developmentTemplate:\n fn::invoke:\n Function: vsphere:getVirtualMachine\n Arguments:\n name: development/templates/ubuntu-server-template\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.VirtualMachine` data source can be used to find the UUID of an\nexisting virtual machine or template. The most common purpose is for finding\nthe UUID of a template to be used as the source for cloning to a new\n`vsphere.VirtualMachine` resource. It also\nreads the guest ID so that can be supplied as well.\n\n## Example Usage\n\nIn the following example, a virtual machine template is returned by its unique\nname within the `vsphere.Datacenter`.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst template = datacenter.then(datacenter =\u003e vsphere.getVirtualMachine({\n name: \"ubuntu-server-template\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\ntemplate = vsphere.get_virtual_machine(name=\"ubuntu-server-template\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var template = VSphere.GetVirtualMachine.Invoke(new()\n {\n Name = \"ubuntu-server-template\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVirtualMachine(ctx, \u0026vsphere.LookupVirtualMachineArgs{\n\t\t\tName: pulumi.StringRef(\"ubuntu-server-template\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetVirtualMachineArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var template = VsphereFunctions.getVirtualMachine(GetVirtualMachineArgs.builder()\n .name(\"ubuntu-server-template\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n template:\n fn::invoke:\n function: vsphere:getVirtualMachine\n arguments:\n name: ubuntu-server-template\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nIn the following example, each virtual machine template is returned by its\nunique full path within the `vsphere.Datacenter`.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst productionTemplate = datacenter.then(datacenter =\u003e vsphere.getVirtualMachine({\n name: \"production/templates/ubuntu-server-template\",\n datacenterId: datacenter.id,\n}));\nconst developmentTemplate = datacenter.then(datacenter =\u003e vsphere.getVirtualMachine({\n name: \"development/templates/ubuntu-server-template\",\n datacenterId: datacenter.id,\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nproduction_template = vsphere.get_virtual_machine(name=\"production/templates/ubuntu-server-template\",\n datacenter_id=datacenter.id)\ndevelopment_template = vsphere.get_virtual_machine(name=\"development/templates/ubuntu-server-template\",\n datacenter_id=datacenter.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var productionTemplate = VSphere.GetVirtualMachine.Invoke(new()\n {\n Name = \"production/templates/ubuntu-server-template\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var developmentTemplate = VSphere.GetVirtualMachine.Invoke(new()\n {\n Name = \"development/templates/ubuntu-server-template\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVirtualMachine(ctx, \u0026vsphere.LookupVirtualMachineArgs{\n\t\t\tName: pulumi.StringRef(\"production/templates/ubuntu-server-template\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.LookupVirtualMachine(ctx, \u0026vsphere.LookupVirtualMachineArgs{\n\t\t\tName: pulumi.StringRef(\"development/templates/ubuntu-server-template\"),\n\t\t\tDatacenterId: pulumi.StringRef(datacenter.Id),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetVirtualMachineArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var productionTemplate = VsphereFunctions.getVirtualMachine(GetVirtualMachineArgs.builder()\n .name(\"production/templates/ubuntu-server-template\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var developmentTemplate = VsphereFunctions.getVirtualMachine(GetVirtualMachineArgs.builder()\n .name(\"development/templates/ubuntu-server-template\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n productionTemplate:\n fn::invoke:\n function: vsphere:getVirtualMachine\n arguments:\n name: production/templates/ubuntu-server-template\n datacenterId: ${datacenter.id}\n developmentTemplate:\n fn::invoke:\n function: vsphere:getVirtualMachine\n arguments:\n name: development/templates/ubuntu-server-template\n datacenterId: ${datacenter.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getVirtualMachine.\n", "properties": { @@ -13113,7 +13113,7 @@ } }, "vsphere:index/getVmfsDisks:getVmfsDisks": { - "description": "The `vsphere.getVmfsDisks` data source can be used to discover the storage\ndevices available on an ESXi host. This data source can be combined with the\n`vsphere.VmfsDatastore` resource to create VMFS\ndatastores based off a set of discovered disks.\n\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vmfsDisks = host.then(host =\u003e vsphere.getVmfsDisks({\n hostSystemId: host.id,\n rescan: true,\n filter: \"mpx.vmhba1:C0:T[12]:L0\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvmfs_disks = vsphere.get_vmfs_disks(host_system_id=host.id,\n rescan=True,\n filter=\"mpx.vmhba1:C0:T[12]:L0\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vmfsDisks = VSphere.GetVmfsDisks.Invoke(new()\n {\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n Rescan = true,\n Filter = \"mpx.vmhba1:C0:T[12]:L0\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetVmfsDisks(ctx, \u0026vsphere.GetVmfsDisksArgs{\n\t\t\tHostSystemId: host.Id,\n\t\t\tRescan: pulumi.BoolRef(true),\n\t\t\tFilter: pulumi.StringRef(\"mpx.vmhba1:C0:T[12]:L0\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetVmfsDisksArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var vmfsDisks = VsphereFunctions.getVmfsDisks(GetVmfsDisksArgs.builder()\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .rescan(true)\n .filter(\"mpx.vmhba1:C0:T[12]:L0\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n Function: vsphere:getDatacenter\n Arguments:\n name: dc-01\n host:\n fn::invoke:\n Function: vsphere:getHost\n Arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n vmfsDisks:\n fn::invoke:\n Function: vsphere:getVmfsDisks\n Arguments:\n hostSystemId: ${host.id}\n rescan: true\n filter: mpx.vmhba1:C0:T[12]:L0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The `vsphere.getVmfsDisks` data source can be used to discover the storage\ndevices available on an ESXi host. This data source can be combined with the\n`vsphere.VmfsDatastore` resource to create VMFS\ndatastores based off a set of discovered disks.\n\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as vsphere from \"@pulumi/vsphere\";\n\nconst datacenter = vsphere.getDatacenter({\n name: \"dc-01\",\n});\nconst host = datacenter.then(datacenter =\u003e vsphere.getHost({\n name: \"esxi-01.example.com\",\n datacenterId: datacenter.id,\n}));\nconst vmfsDisks = host.then(host =\u003e vsphere.getVmfsDisks({\n hostSystemId: host.id,\n rescan: true,\n filter: \"mpx.vmhba1:C0:T[12]:L0\",\n}));\n```\n```python\nimport pulumi\nimport pulumi_vsphere as vsphere\n\ndatacenter = vsphere.get_datacenter(name=\"dc-01\")\nhost = vsphere.get_host(name=\"esxi-01.example.com\",\n datacenter_id=datacenter.id)\nvmfs_disks = vsphere.get_vmfs_disks(host_system_id=host.id,\n rescan=True,\n filter=\"mpx.vmhba1:C0:T[12]:L0\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing VSphere = Pulumi.VSphere;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var datacenter = VSphere.GetDatacenter.Invoke(new()\n {\n Name = \"dc-01\",\n });\n\n var host = VSphere.GetHost.Invoke(new()\n {\n Name = \"esxi-01.example.com\",\n DatacenterId = datacenter.Apply(getDatacenterResult =\u003e getDatacenterResult.Id),\n });\n\n var vmfsDisks = VSphere.GetVmfsDisks.Invoke(new()\n {\n HostSystemId = host.Apply(getHostResult =\u003e getHostResult.Id),\n Rescan = true,\n Filter = \"mpx.vmhba1:C0:T[12]:L0\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-vsphere/sdk/v4/go/vsphere\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdatacenter, err := vsphere.LookupDatacenter(ctx, \u0026vsphere.LookupDatacenterArgs{\n\t\t\tName: pulumi.StringRef(\"dc-01\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\thost, err := vsphere.LookupHost(ctx, \u0026vsphere.LookupHostArgs{\n\t\t\tName: pulumi.StringRef(\"esxi-01.example.com\"),\n\t\t\tDatacenterId: datacenter.Id,\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = vsphere.GetVmfsDisks(ctx, \u0026vsphere.GetVmfsDisksArgs{\n\t\t\tHostSystemId: host.Id,\n\t\t\tRescan: pulumi.BoolRef(true),\n\t\t\tFilter: pulumi.StringRef(\"mpx.vmhba1:C0:T[12]:L0\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.vsphere.VsphereFunctions;\nimport com.pulumi.vsphere.inputs.GetDatacenterArgs;\nimport com.pulumi.vsphere.inputs.GetHostArgs;\nimport com.pulumi.vsphere.inputs.GetVmfsDisksArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n final var datacenter = VsphereFunctions.getDatacenter(GetDatacenterArgs.builder()\n .name(\"dc-01\")\n .build());\n\n final var host = VsphereFunctions.getHost(GetHostArgs.builder()\n .name(\"esxi-01.example.com\")\n .datacenterId(datacenter.applyValue(getDatacenterResult -\u003e getDatacenterResult.id()))\n .build());\n\n final var vmfsDisks = VsphereFunctions.getVmfsDisks(GetVmfsDisksArgs.builder()\n .hostSystemId(host.applyValue(getHostResult -\u003e getHostResult.id()))\n .rescan(true)\n .filter(\"mpx.vmhba1:C0:T[12]:L0\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n datacenter:\n fn::invoke:\n function: vsphere:getDatacenter\n arguments:\n name: dc-01\n host:\n fn::invoke:\n function: vsphere:getHost\n arguments:\n name: esxi-01.example.com\n datacenterId: ${datacenter.id}\n vmfsDisks:\n fn::invoke:\n function: vsphere:getVmfsDisks\n arguments:\n hostSystemId: ${host.id}\n rescan: true\n filter: mpx.vmhba1:C0:T[12]:L0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getVmfsDisks.\n", "properties": { diff --git a/provider/go.mod b/provider/go.mod index c7e6cf65..f8187404 100644 --- a/provider/go.mod +++ b/provider/go.mod @@ -11,8 +11,8 @@ replace ( require ( github.com/hashicorp/terraform-provider-vsphere v2.3.1+incompatible - github.com/pulumi/pulumi-terraform-bridge/v3 v3.96.0 - github.com/pulumi/pulumi/sdk/v3 v3.140.0 + github.com/pulumi/pulumi-terraform-bridge/v3 v3.96.1-0.20241209153914-c1171a037064 + github.com/pulumi/pulumi/sdk/v3 v3.142.0 ) require ( @@ -136,9 +136,9 @@ require ( github.com/pulumi/appdash v0.0.0-20231130102222-75f619a67231 // indirect github.com/pulumi/esc v0.10.0 // indirect github.com/pulumi/inflector v0.1.1 // indirect - github.com/pulumi/pulumi-java/pkg v0.17.0 // indirect - github.com/pulumi/pulumi-yaml v1.11.2 // indirect - github.com/pulumi/pulumi/pkg/v3 v3.140.0 // indirect + github.com/pulumi/pulumi-java/pkg v0.18.0 // indirect + github.com/pulumi/pulumi-yaml v1.12.0 // indirect + github.com/pulumi/pulumi/pkg/v3 v3.142.0 // indirect github.com/pulumi/schema-tools v0.1.2 // indirect github.com/pulumi/terraform-diff-reader v0.0.2 // indirect github.com/rivo/uniseg v0.4.4 // indirect diff --git a/provider/go.sum b/provider/go.sum index 94cb1616..904c7d48 100644 --- a/provider/go.sum +++ b/provider/go.sum @@ -1895,16 +1895,16 @@ github.com/pulumi/inflector v0.1.1 h1:dvlxlWtXwOJTUUtcYDvwnl6Mpg33prhK+7mzeF+Sob github.com/pulumi/inflector v0.1.1/go.mod h1:HUFCjcPTz96YtTuUlwG3i3EZG4WlniBvR9bd+iJxCUY= github.com/pulumi/providertest v0.1.3 h1:GpNKRy/haNjRHiUA9bi4diU4Op2zf3axYXbga5AepHg= github.com/pulumi/providertest v0.1.3/go.mod h1:GcsqEGgSngwaNOD+kICJPIUQlnA911fGBU8HDlJvVL0= -github.com/pulumi/pulumi-java/pkg v0.17.0 h1:KmaVLrVmlkzShOfaJNJDlckorbFm8dM/C7L4hj6LX8U= -github.com/pulumi/pulumi-java/pkg v0.17.0/go.mod h1:ji4U4H7t81X4aaE88D9+z5CmKH/QoLwQi9N1iGl+2KQ= -github.com/pulumi/pulumi-terraform-bridge/v3 v3.96.0 h1:uJB3tM1j+9SKeXLCAx3DBVHsYk4ddXNrVoiqpgXal2Q= -github.com/pulumi/pulumi-terraform-bridge/v3 v3.96.0/go.mod h1:WnOTAfdtm5+kW3rIU0rLhxFSEHtJIMf19FdOU6NFXG0= -github.com/pulumi/pulumi-yaml v1.11.2 h1:MU7TTNbruGCSgNHhaBygjIbLWm3WSbd1q98GpMIgQzE= -github.com/pulumi/pulumi-yaml v1.11.2/go.mod h1:RdXRBupRGGAD1kbYNG1V1h6pyFnXisvQsl0AANvVjGI= -github.com/pulumi/pulumi/pkg/v3 v3.140.0 h1:/bvHa19HY/6qHWvuAOVII8qr72MDGGczBWlPYlPo3j0= -github.com/pulumi/pulumi/pkg/v3 v3.140.0/go.mod h1:rcTtSyisd7BzZTugNk/s9zlYgX9S0S10+pha3Tko6yM= -github.com/pulumi/pulumi/sdk/v3 v3.140.0 h1:+Z/RBvdYg7tBNkBwk4p/FzlV7niBT3TbLAICq/Y0LDU= -github.com/pulumi/pulumi/sdk/v3 v3.140.0/go.mod h1:PvKsX88co8XuwuPdzolMvew5lZV+4JmZfkeSjj7A6dI= +github.com/pulumi/pulumi-java/pkg v0.18.0 h1:3PApc5YegH69n6oubB63mqI97pF+oQywWr7ii4082Mw= +github.com/pulumi/pulumi-java/pkg v0.18.0/go.mod h1:YKYYFEb3Jvzf/dDJo0xOeEkIfBAMkkkdhXulauvEjmc= +github.com/pulumi/pulumi-terraform-bridge/v3 v3.96.1-0.20241209153914-c1171a037064 h1:jGeafLzVLbd4XSEgQObmLyzHlQMMryweT0CBhqKRt+s= +github.com/pulumi/pulumi-terraform-bridge/v3 v3.96.1-0.20241209153914-c1171a037064/go.mod h1:B/Auryr+yVUkLOMzgpFe7HLwKAtXc6YJwpAXfNGyLPk= +github.com/pulumi/pulumi-yaml v1.12.0 h1:ThJP+EBqeJyCnS6w6/PwcEFOT5o112qv0lObhefmFCk= +github.com/pulumi/pulumi-yaml v1.12.0/go.mod h1:EhZd1XDfuLa15O51qVVE16U6r8ldK9mLIBclqWCX27Y= +github.com/pulumi/pulumi/pkg/v3 v3.142.0 h1:UE8TFyXrlxvPrATpd3Kl3En34KrFIFWOxxNAodywPNU= +github.com/pulumi/pulumi/pkg/v3 v3.142.0/go.mod h1:3k6WwRIT7veiDnk3Yo2NtqEYX+4dgLCrMIFvEOnjQqI= +github.com/pulumi/pulumi/sdk/v3 v3.142.0 h1:SmcVddGuvwAh3g3XUVQQ5gVRQUKH1yZ6iETpDNHIHlw= +github.com/pulumi/pulumi/sdk/v3 v3.142.0/go.mod h1:PvKsX88co8XuwuPdzolMvew5lZV+4JmZfkeSjj7A6dI= github.com/pulumi/schema-tools v0.1.2 h1:Fd9xvUjgck4NA+7/jSk7InqCUT4Kj940+EcnbQKpfZo= github.com/pulumi/schema-tools v0.1.2/go.mod h1:62lgj52Tzq11eqWTIaKd+EVyYAu5dEcDJxMhTjvMO/k= github.com/pulumi/terraform-diff-reader v0.0.2 h1:kTE4nEXU3/SYXESvAIem+wyHMI3abqkI3OhJ0G04LLI= diff --git a/sdk/go.mod b/sdk/go.mod index f8447562..159f68a5 100644 --- a/sdk/go.mod +++ b/sdk/go.mod @@ -4,7 +4,7 @@ go 1.21 require ( github.com/blang/semver v3.5.1+incompatible - github.com/pulumi/pulumi/sdk/v3 v3.140.0 + github.com/pulumi/pulumi/sdk/v3 v3.142.0 ) require ( diff --git a/sdk/go.sum b/sdk/go.sum index 5d5453c0..54cd0acd 100644 --- a/sdk/go.sum +++ b/sdk/go.sum @@ -150,8 +150,8 @@ github.com/pulumi/appdash v0.0.0-20231130102222-75f619a67231 h1:vkHw5I/plNdTr435 github.com/pulumi/appdash v0.0.0-20231130102222-75f619a67231/go.mod h1:murToZ2N9hNJzewjHBgfFdXhZKjY3z5cYC1VXk+lbFE= github.com/pulumi/esc v0.9.1 h1:HH5eEv8sgyxSpY5a8yePyqFXzA8cvBvapfH8457+mIs= github.com/pulumi/esc v0.9.1/go.mod h1:oEJ6bOsjYlQUpjf70GiX+CXn3VBmpwFDxUTlmtUN84c= -github.com/pulumi/pulumi/sdk/v3 v3.140.0 h1:+Z/RBvdYg7tBNkBwk4p/FzlV7niBT3TbLAICq/Y0LDU= -github.com/pulumi/pulumi/sdk/v3 v3.140.0/go.mod h1:PvKsX88co8XuwuPdzolMvew5lZV+4JmZfkeSjj7A6dI= +github.com/pulumi/pulumi/sdk/v3 v3.142.0 h1:SmcVddGuvwAh3g3XUVQQ5gVRQUKH1yZ6iETpDNHIHlw= +github.com/pulumi/pulumi/sdk/v3 v3.142.0/go.mod h1:PvKsX88co8XuwuPdzolMvew5lZV+4JmZfkeSjj7A6dI= github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.4.4 h1:8TfxU8dW6PdqD27gjM8MVNuicgxIjxpm4K7x4jp8sis= From 7f077ebbcec53540f08fbf84ca783de2ae30b51d Mon Sep 17 00:00:00 2001 From: pulumi-bot Date: Mon, 9 Dec 2024 17:12:17 +0000 Subject: [PATCH 2/2] make build_sdks --- sdk/java/build.gradle | 4 ++-- sdk/nodejs/getComputeCluster.ts | 2 +- sdk/nodejs/getComputeClusterHostGroup.ts | 2 +- sdk/nodejs/getContentLibrary.ts | 2 +- sdk/nodejs/getContentLibraryItem.ts | 2 +- sdk/nodejs/getCustomAttribute.ts | 2 +- sdk/nodejs/getDatacenter.ts | 2 +- sdk/nodejs/getDatastore.ts | 2 +- sdk/nodejs/getDatastoreCluster.ts | 2 +- sdk/nodejs/getDatastoreStats.ts | 2 +- sdk/nodejs/getDistributedVirtualSwitch.ts | 2 +- sdk/nodejs/getDynamic.ts | 2 +- sdk/nodejs/getFolder.ts | 2 +- sdk/nodejs/getGuestOsCustomization.ts | 2 +- sdk/nodejs/getHost.ts | 2 +- sdk/nodejs/getHostBaseImages.ts | 2 +- sdk/nodejs/getHostPciDevice.ts | 2 +- sdk/nodejs/getHostThumbprint.ts | 2 +- sdk/nodejs/getHostVgpuProfile.ts | 2 +- sdk/nodejs/getLicense.ts | 2 +- sdk/nodejs/getNetwork.ts | 2 +- sdk/nodejs/getOvfVmTemplate.ts | 2 +- sdk/nodejs/getPolicy.ts | 2 +- sdk/nodejs/getResourcePool.ts | 2 +- sdk/nodejs/getRole.ts | 2 +- sdk/nodejs/getTag.ts | 2 +- sdk/nodejs/getTagCategory.ts | 2 +- sdk/nodejs/getVappContainer.ts | 2 +- sdk/nodejs/getVirtualMachine.ts | 2 +- sdk/nodejs/getVmfsDisks.ts | 2 +- sdk/python/pulumi_vsphere/get_compute_cluster.py | 4 ++-- sdk/python/pulumi_vsphere/get_compute_cluster_host_group.py | 4 ++-- sdk/python/pulumi_vsphere/get_content_library.py | 4 ++-- sdk/python/pulumi_vsphere/get_content_library_item.py | 4 ++-- sdk/python/pulumi_vsphere/get_custom_attribute.py | 4 ++-- sdk/python/pulumi_vsphere/get_datacenter.py | 4 ++-- sdk/python/pulumi_vsphere/get_datastore.py | 4 ++-- sdk/python/pulumi_vsphere/get_datastore_cluster.py | 4 ++-- sdk/python/pulumi_vsphere/get_datastore_stats.py | 4 ++-- sdk/python/pulumi_vsphere/get_distributed_virtual_switch.py | 4 ++-- sdk/python/pulumi_vsphere/get_dynamic.py | 4 ++-- sdk/python/pulumi_vsphere/get_folder.py | 4 ++-- sdk/python/pulumi_vsphere/get_guest_os_customization.py | 4 ++-- sdk/python/pulumi_vsphere/get_host.py | 4 ++-- sdk/python/pulumi_vsphere/get_host_base_images.py | 4 ++-- sdk/python/pulumi_vsphere/get_host_pci_device.py | 4 ++-- sdk/python/pulumi_vsphere/get_host_thumbprint.py | 4 ++-- sdk/python/pulumi_vsphere/get_host_vgpu_profile.py | 4 ++-- sdk/python/pulumi_vsphere/get_license.py | 4 ++-- sdk/python/pulumi_vsphere/get_network.py | 4 ++-- sdk/python/pulumi_vsphere/get_ovf_vm_template.py | 4 ++-- sdk/python/pulumi_vsphere/get_policy.py | 4 ++-- sdk/python/pulumi_vsphere/get_resource_pool.py | 4 ++-- sdk/python/pulumi_vsphere/get_role.py | 4 ++-- sdk/python/pulumi_vsphere/get_tag.py | 4 ++-- sdk/python/pulumi_vsphere/get_tag_category.py | 4 ++-- sdk/python/pulumi_vsphere/get_vapp_container.py | 4 ++-- sdk/python/pulumi_vsphere/get_virtual_machine.py | 4 ++-- sdk/python/pulumi_vsphere/get_vmfs_disks.py | 4 ++-- 59 files changed, 89 insertions(+), 89 deletions(-) diff --git a/sdk/java/build.gradle b/sdk/java/build.gradle index e028d4fe..c1364978 100644 --- a/sdk/java/build.gradle +++ b/sdk/java/build.gradle @@ -5,7 +5,7 @@ plugins { id("signing") id("java-library") id("maven-publish") - id("io.github.gradle-nexus.publish-plugin") version "1.1.0" + id("io.github.gradle-nexus.publish-plugin") version "2.0.0" } group = "com.pulumi" @@ -44,7 +44,7 @@ repositories { dependencies { implementation("com.google.code.findbugs:jsr305:3.0.2") implementation("com.google.code.gson:gson:2.8.9") - implementation("com.pulumi:pulumi:0.17.0") + implementation("com.pulumi:pulumi:0.18.0") } task sourcesJar(type: Jar) { diff --git a/sdk/nodejs/getComputeCluster.ts b/sdk/nodejs/getComputeCluster.ts index 4205a866..984bda82 100644 --- a/sdk/nodejs/getComputeCluster.ts +++ b/sdk/nodejs/getComputeCluster.ts @@ -97,7 +97,7 @@ export interface GetComputeClusterResult { * })); * ``` */ -export function getComputeClusterOutput(args: GetComputeClusterOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getComputeClusterOutput(args: GetComputeClusterOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getComputeCluster:getComputeCluster", { "datacenterId": args.datacenterId, diff --git a/sdk/nodejs/getComputeClusterHostGroup.ts b/sdk/nodejs/getComputeClusterHostGroup.ts index f5fc3357..97f71ad3 100644 --- a/sdk/nodejs/getComputeClusterHostGroup.ts +++ b/sdk/nodejs/getComputeClusterHostGroup.ts @@ -106,7 +106,7 @@ export interface GetComputeClusterHostGroupResult { * }); * ``` */ -export function getComputeClusterHostGroupOutput(args: GetComputeClusterHostGroupOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getComputeClusterHostGroupOutput(args: GetComputeClusterHostGroupOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getComputeClusterHostGroup:getComputeClusterHostGroup", { "computeClusterId": args.computeClusterId, diff --git a/sdk/nodejs/getContentLibrary.ts b/sdk/nodejs/getContentLibrary.ts index 5f4961ff..62ac903b 100644 --- a/sdk/nodejs/getContentLibrary.ts +++ b/sdk/nodejs/getContentLibrary.ts @@ -67,7 +67,7 @@ export interface GetContentLibraryResult { * }); * ``` */ -export function getContentLibraryOutput(args: GetContentLibraryOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getContentLibraryOutput(args: GetContentLibraryOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getContentLibrary:getContentLibrary", { "name": args.name, diff --git a/sdk/nodejs/getContentLibraryItem.ts b/sdk/nodejs/getContentLibraryItem.ts index 9d0c46bc..9b85cb04 100644 --- a/sdk/nodejs/getContentLibraryItem.ts +++ b/sdk/nodejs/getContentLibraryItem.ts @@ -59,7 +59,7 @@ export interface GetContentLibraryItemResult { * > **NOTE:** This resource requires vCenter and is not available on direct ESXi * host connections. */ -export function getContentLibraryItemOutput(args: GetContentLibraryItemOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getContentLibraryItemOutput(args: GetContentLibraryItemOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getContentLibraryItem:getContentLibraryItem", { "libraryId": args.libraryId, diff --git a/sdk/nodejs/getCustomAttribute.ts b/sdk/nodejs/getCustomAttribute.ts index 37a090e4..5f141c53 100644 --- a/sdk/nodejs/getCustomAttribute.ts +++ b/sdk/nodejs/getCustomAttribute.ts @@ -74,7 +74,7 @@ export interface GetCustomAttributeResult { * }); * ``` */ -export function getCustomAttributeOutput(args: GetCustomAttributeOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getCustomAttributeOutput(args: GetCustomAttributeOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getCustomAttribute:getCustomAttribute", { "name": args.name, diff --git a/sdk/nodejs/getDatacenter.ts b/sdk/nodejs/getDatacenter.ts index 09a216cc..358ef92a 100644 --- a/sdk/nodejs/getDatacenter.ts +++ b/sdk/nodejs/getDatacenter.ts @@ -76,7 +76,7 @@ export interface GetDatacenterResult { * }); * ``` */ -export function getDatacenterOutput(args?: GetDatacenterOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getDatacenterOutput(args?: GetDatacenterOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { args = args || {}; opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getDatacenter:getDatacenter", { diff --git a/sdk/nodejs/getDatastore.ts b/sdk/nodejs/getDatastore.ts index f1c1eb51..83a7f025 100644 --- a/sdk/nodejs/getDatastore.ts +++ b/sdk/nodejs/getDatastore.ts @@ -95,7 +95,7 @@ export interface GetDatastoreResult { * })); * ``` */ -export function getDatastoreOutput(args: GetDatastoreOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getDatastoreOutput(args: GetDatastoreOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getDatastore:getDatastore", { "datacenterId": args.datacenterId, diff --git a/sdk/nodejs/getDatastoreCluster.ts b/sdk/nodejs/getDatastoreCluster.ts index f5ccec59..06807258 100644 --- a/sdk/nodejs/getDatastoreCluster.ts +++ b/sdk/nodejs/getDatastoreCluster.ts @@ -88,7 +88,7 @@ export interface GetDatastoreClusterResult { * })); * ``` */ -export function getDatastoreClusterOutput(args: GetDatastoreClusterOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getDatastoreClusterOutput(args: GetDatastoreClusterOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getDatastoreCluster:getDatastoreCluster", { "datacenterId": args.datacenterId, diff --git a/sdk/nodejs/getDatastoreStats.ts b/sdk/nodejs/getDatastoreStats.ts index e3496b9b..1bbeac65 100644 --- a/sdk/nodejs/getDatastoreStats.ts +++ b/sdk/nodejs/getDatastoreStats.ts @@ -132,7 +132,7 @@ export interface GetDatastoreStatsResult { * * and a `locals.tf` like that: */ -export function getDatastoreStatsOutput(args: GetDatastoreStatsOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getDatastoreStatsOutput(args: GetDatastoreStatsOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getDatastoreStats:getDatastoreStats", { "capacity": args.capacity, diff --git a/sdk/nodejs/getDistributedVirtualSwitch.ts b/sdk/nodejs/getDistributedVirtualSwitch.ts index 383af38e..dcd72e7f 100644 --- a/sdk/nodejs/getDistributedVirtualSwitch.ts +++ b/sdk/nodejs/getDistributedVirtualSwitch.ts @@ -119,7 +119,7 @@ export interface GetDistributedVirtualSwitchResult { * }); * ``` */ -export function getDistributedVirtualSwitchOutput(args: GetDistributedVirtualSwitchOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getDistributedVirtualSwitchOutput(args: GetDistributedVirtualSwitchOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getDistributedVirtualSwitch:getDistributedVirtualSwitch", { "datacenterId": args.datacenterId, diff --git a/sdk/nodejs/getDynamic.ts b/sdk/nodejs/getDynamic.ts index 0a8ded30..a823ba86 100644 --- a/sdk/nodejs/getDynamic.ts +++ b/sdk/nodejs/getDynamic.ts @@ -117,7 +117,7 @@ export interface GetDynamicResult { * })); * ``` */ -export function getDynamicOutput(args: GetDynamicOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getDynamicOutput(args: GetDynamicOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getDynamic:getDynamic", { "filters": args.filters, diff --git a/sdk/nodejs/getFolder.ts b/sdk/nodejs/getFolder.ts index b7a8650a..4c8a6420 100644 --- a/sdk/nodejs/getFolder.ts +++ b/sdk/nodejs/getFolder.ts @@ -73,7 +73,7 @@ export interface GetFolderResult { * }); * ``` */ -export function getFolderOutput(args: GetFolderOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getFolderOutput(args: GetFolderOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getFolder:getFolder", { "path": args.path, diff --git a/sdk/nodejs/getGuestOsCustomization.ts b/sdk/nodejs/getGuestOsCustomization.ts index 46635991..5fd7a411 100644 --- a/sdk/nodejs/getGuestOsCustomization.ts +++ b/sdk/nodejs/getGuestOsCustomization.ts @@ -47,7 +47,7 @@ export interface GetGuestOsCustomizationResult { * The `vsphere.GuestOsCustomization` data source can be used to discover the * details about a customization specification for a guest operating system. */ -export function getGuestOsCustomizationOutput(args: GetGuestOsCustomizationOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getGuestOsCustomizationOutput(args: GetGuestOsCustomizationOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getGuestOsCustomization:getGuestOsCustomization", { "name": args.name, diff --git a/sdk/nodejs/getHost.ts b/sdk/nodejs/getHost.ts index d1c7f898..cd1a0455 100644 --- a/sdk/nodejs/getHost.ts +++ b/sdk/nodejs/getHost.ts @@ -87,7 +87,7 @@ export interface GetHostResult { * })); * ``` */ -export function getHostOutput(args: GetHostOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getHostOutput(args: GetHostOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getHost:getHost", { "datacenterId": args.datacenterId, diff --git a/sdk/nodejs/getHostBaseImages.ts b/sdk/nodejs/getHostBaseImages.ts index 7179cd6b..b8d3f8bf 100644 --- a/sdk/nodejs/getHostBaseImages.ts +++ b/sdk/nodejs/getHostBaseImages.ts @@ -49,7 +49,7 @@ export interface GetHostBaseImagesResult { * const baseImages = vsphere.getHostBaseImages({}); * ``` */ -export function getHostBaseImagesOutput(opts?: pulumi.InvokeOptions): pulumi.Output { +export function getHostBaseImagesOutput(opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getHostBaseImages:getHostBaseImages", { }, opts); diff --git a/sdk/nodejs/getHostPciDevice.ts b/sdk/nodejs/getHostPciDevice.ts index 3bebe77d..adcba5f6 100644 --- a/sdk/nodejs/getHostPciDevice.ts +++ b/sdk/nodejs/getHostPciDevice.ts @@ -151,7 +151,7 @@ export interface GetHostPciDeviceResult { * })); * ``` */ -export function getHostPciDeviceOutput(args: GetHostPciDeviceOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getHostPciDeviceOutput(args: GetHostPciDeviceOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getHostPciDevice:getHostPciDevice", { "classId": args.classId, diff --git a/sdk/nodejs/getHostThumbprint.ts b/sdk/nodejs/getHostThumbprint.ts index b16af7a6..1c09eaea 100644 --- a/sdk/nodejs/getHostThumbprint.ts +++ b/sdk/nodejs/getHostThumbprint.ts @@ -88,7 +88,7 @@ export interface GetHostThumbprintResult { * }); * ``` */ -export function getHostThumbprintOutput(args: GetHostThumbprintOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getHostThumbprintOutput(args: GetHostThumbprintOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getHostThumbprint:getHostThumbprint", { "address": args.address, diff --git a/sdk/nodejs/getHostVgpuProfile.ts b/sdk/nodejs/getHostVgpuProfile.ts index 7b3bb876..06a0e39c 100644 --- a/sdk/nodejs/getHostVgpuProfile.ts +++ b/sdk/nodejs/getHostVgpuProfile.ts @@ -141,7 +141,7 @@ export interface GetHostVgpuProfileResult { * })); * ``` */ -export function getHostVgpuProfileOutput(args: GetHostVgpuProfileOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getHostVgpuProfileOutput(args: GetHostVgpuProfileOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getHostVgpuProfile:getHostVgpuProfile", { "hostId": args.hostId, diff --git a/sdk/nodejs/getLicense.ts b/sdk/nodejs/getLicense.ts index b795136b..bf137e2c 100644 --- a/sdk/nodejs/getLicense.ts +++ b/sdk/nodejs/getLicense.ts @@ -79,7 +79,7 @@ export interface GetLicenseResult { * }); * ``` */ -export function getLicenseOutput(args: GetLicenseOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getLicenseOutput(args: GetLicenseOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getLicense:getLicense", { "licenseKey": args.licenseKey, diff --git a/sdk/nodejs/getNetwork.ts b/sdk/nodejs/getNetwork.ts index 695ce209..e19179e5 100644 --- a/sdk/nodejs/getNetwork.ts +++ b/sdk/nodejs/getNetwork.ts @@ -144,7 +144,7 @@ export interface GetNetworkResult { * })); * ``` */ -export function getNetworkOutput(args: GetNetworkOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getNetworkOutput(args: GetNetworkOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getNetwork:getNetwork", { "datacenterId": args.datacenterId, diff --git a/sdk/nodejs/getOvfVmTemplate.ts b/sdk/nodejs/getOvfVmTemplate.ts index 4158f182..b47d5bfd 100644 --- a/sdk/nodejs/getOvfVmTemplate.ts +++ b/sdk/nodejs/getOvfVmTemplate.ts @@ -194,7 +194,7 @@ export interface GetOvfVmTemplateResult { * vSphere and extract its hardware settings in a form that can be then used as * inputs for a `vsphere.VirtualMachine` resource. */ -export function getOvfVmTemplateOutput(args: GetOvfVmTemplateOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getOvfVmTemplateOutput(args: GetOvfVmTemplateOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getOvfVmTemplate:getOvfVmTemplate", { "allowUnverifiedSslCert": args.allowUnverifiedSslCert, diff --git a/sdk/nodejs/getPolicy.ts b/sdk/nodejs/getPolicy.ts index c9e617c0..974511d7 100644 --- a/sdk/nodejs/getPolicy.ts +++ b/sdk/nodejs/getPolicy.ts @@ -75,7 +75,7 @@ export interface GetPolicyResult { * }); * ``` */ -export function getPolicyOutput(args: GetPolicyOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getPolicyOutput(args: GetPolicyOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getPolicy:getPolicy", { "name": args.name, diff --git a/sdk/nodejs/getResourcePool.ts b/sdk/nodejs/getResourcePool.ts index 9e71c969..21c6573f 100644 --- a/sdk/nodejs/getResourcePool.ts +++ b/sdk/nodejs/getResourcePool.ts @@ -141,7 +141,7 @@ export interface GetResourcePoolResult { * * [vmware-docs-resource-pools]: https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-resource-management/GUID-60077B40-66FF-4625-934A-641703ED7601.html */ -export function getResourcePoolOutput(args?: GetResourcePoolOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getResourcePoolOutput(args?: GetResourcePoolOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { args = args || {}; opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getResourcePool:getResourcePool", { diff --git a/sdk/nodejs/getRole.ts b/sdk/nodejs/getRole.ts index 6cab3378..d775f9f8 100644 --- a/sdk/nodejs/getRole.ts +++ b/sdk/nodejs/getRole.ts @@ -85,7 +85,7 @@ export interface GetRoleResult { * }); * ``` */ -export function getRoleOutput(args: GetRoleOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getRoleOutput(args: GetRoleOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getRole:getRole", { "description": args.description, diff --git a/sdk/nodejs/getTag.ts b/sdk/nodejs/getTag.ts index 4d564436..aa3f4df8 100644 --- a/sdk/nodejs/getTag.ts +++ b/sdk/nodejs/getTag.ts @@ -89,7 +89,7 @@ export interface GetTagResult { * })); * ``` */ -export function getTagOutput(args: GetTagOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getTagOutput(args: GetTagOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getTag:getTag", { "categoryId": args.categoryId, diff --git a/sdk/nodejs/getTagCategory.ts b/sdk/nodejs/getTagCategory.ts index b878591a..7375bbf3 100644 --- a/sdk/nodejs/getTagCategory.ts +++ b/sdk/nodejs/getTagCategory.ts @@ -76,7 +76,7 @@ export interface GetTagCategoryResult { * }); * ``` */ -export function getTagCategoryOutput(args: GetTagCategoryOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getTagCategoryOutput(args: GetTagCategoryOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getTagCategory:getTagCategory", { "name": args.name, diff --git a/sdk/nodejs/getVappContainer.ts b/sdk/nodejs/getVappContainer.ts index e317eb9c..1d602946 100644 --- a/sdk/nodejs/getVappContainer.ts +++ b/sdk/nodejs/getVappContainer.ts @@ -81,7 +81,7 @@ export interface GetVappContainerResult { * })); * ``` */ -export function getVappContainerOutput(args: GetVappContainerOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getVappContainerOutput(args: GetVappContainerOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getVappContainer:getVappContainer", { "datacenterId": args.datacenterId, diff --git a/sdk/nodejs/getVirtualMachine.ts b/sdk/nodejs/getVirtualMachine.ts index 4142f9c0..4936d2b2 100644 --- a/sdk/nodejs/getVirtualMachine.ts +++ b/sdk/nodejs/getVirtualMachine.ts @@ -434,7 +434,7 @@ export interface GetVirtualMachineResult { * })); * ``` */ -export function getVirtualMachineOutput(args?: GetVirtualMachineOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getVirtualMachineOutput(args?: GetVirtualMachineOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { args = args || {}; opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getVirtualMachine:getVirtualMachine", { diff --git a/sdk/nodejs/getVmfsDisks.ts b/sdk/nodejs/getVmfsDisks.ts index 555ca627..f7d67c2d 100644 --- a/sdk/nodejs/getVmfsDisks.ts +++ b/sdk/nodejs/getVmfsDisks.ts @@ -108,7 +108,7 @@ export interface GetVmfsDisksResult { * })); * ``` */ -export function getVmfsDisksOutput(args: GetVmfsDisksOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { +export function getVmfsDisksOutput(args: GetVmfsDisksOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("vsphere:index/getVmfsDisks:getVmfsDisks", { "filter": args.filter, diff --git a/sdk/python/pulumi_vsphere/get_compute_cluster.py b/sdk/python/pulumi_vsphere/get_compute_cluster.py index 5f5df0ec..619025b2 100644 --- a/sdk/python/pulumi_vsphere/get_compute_cluster.py +++ b/sdk/python/pulumi_vsphere/get_compute_cluster.py @@ -125,7 +125,7 @@ def get_compute_cluster(datacenter_id: Optional[str] = None, resource_pool_id=pulumi.get(__ret__, 'resource_pool_id')) def get_compute_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = None, name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetComputeClusterResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetComputeClusterResult]: """ The `ComputeCluster` data source can be used to discover the ID of a cluster in vSphere. This is useful to fetch the ID of a cluster that you want @@ -158,7 +158,7 @@ def get_compute_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[str __args__ = dict() __args__['datacenterId'] = datacenter_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getComputeCluster:getComputeCluster', __args__, opts=opts, typ=GetComputeClusterResult) return __ret__.apply(lambda __response__: GetComputeClusterResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_compute_cluster_host_group.py b/sdk/python/pulumi_vsphere/get_compute_cluster_host_group.py index 07dc270d..45a7e329 100644 --- a/sdk/python/pulumi_vsphere/get_compute_cluster_host_group.py +++ b/sdk/python/pulumi_vsphere/get_compute_cluster_host_group.py @@ -127,7 +127,7 @@ def get_compute_cluster_host_group(compute_cluster_id: Optional[str] = None, name=pulumi.get(__ret__, 'name')) def get_compute_cluster_host_group_output(compute_cluster_id: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetComputeClusterHostGroupResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetComputeClusterHostGroupResult]: """ The `ComputeClusterHostGroup` data source can be used to discover the IDs ESXi hosts in a host group and return host group attributes to other @@ -162,7 +162,7 @@ def get_compute_cluster_host_group_output(compute_cluster_id: Optional[pulumi.In __args__ = dict() __args__['computeClusterId'] = compute_cluster_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getComputeClusterHostGroup:getComputeClusterHostGroup', __args__, opts=opts, typ=GetComputeClusterHostGroupResult) return __ret__.apply(lambda __response__: GetComputeClusterHostGroupResult( compute_cluster_id=pulumi.get(__response__, 'compute_cluster_id'), diff --git a/sdk/python/pulumi_vsphere/get_content_library.py b/sdk/python/pulumi_vsphere/get_content_library.py index 366ed17e..c96790d3 100644 --- a/sdk/python/pulumi_vsphere/get_content_library.py +++ b/sdk/python/pulumi_vsphere/get_content_library.py @@ -88,7 +88,7 @@ def get_content_library(name: Optional[str] = None, id=pulumi.get(__ret__, 'id'), name=pulumi.get(__ret__, 'name')) def get_content_library_output(name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetContentLibraryResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetContentLibraryResult]: """ The `ContentLibrary` data source can be used to discover the ID of a content library. @@ -110,7 +110,7 @@ def get_content_library_output(name: Optional[pulumi.Input[str]] = None, """ __args__ = dict() __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getContentLibrary:getContentLibrary', __args__, opts=opts, typ=GetContentLibraryResult) return __ret__.apply(lambda __response__: GetContentLibraryResult( id=pulumi.get(__response__, 'id'), diff --git a/sdk/python/pulumi_vsphere/get_content_library_item.py b/sdk/python/pulumi_vsphere/get_content_library_item.py index db0ac226..6b9404cb 100644 --- a/sdk/python/pulumi_vsphere/get_content_library_item.py +++ b/sdk/python/pulumi_vsphere/get_content_library_item.py @@ -109,7 +109,7 @@ def get_content_library_item(library_id: Optional[str] = None, def get_content_library_item_output(library_id: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[str]] = None, type: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetContentLibraryItemResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetContentLibraryItemResult]: """ The `ContentLibraryItem` data source can be used to discover the ID of a content library item. @@ -128,7 +128,7 @@ def get_content_library_item_output(library_id: Optional[pulumi.Input[str]] = No __args__['libraryId'] = library_id __args__['name'] = name __args__['type'] = type - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getContentLibraryItem:getContentLibraryItem', __args__, opts=opts, typ=GetContentLibraryItemResult) return __ret__.apply(lambda __response__: GetContentLibraryItemResult( id=pulumi.get(__response__, 'id'), diff --git a/sdk/python/pulumi_vsphere/get_custom_attribute.py b/sdk/python/pulumi_vsphere/get_custom_attribute.py index 89657391..128534a1 100644 --- a/sdk/python/pulumi_vsphere/get_custom_attribute.py +++ b/sdk/python/pulumi_vsphere/get_custom_attribute.py @@ -101,7 +101,7 @@ def get_custom_attribute(name: Optional[str] = None, managed_object_type=pulumi.get(__ret__, 'managed_object_type'), name=pulumi.get(__ret__, 'name')) def get_custom_attribute_output(name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetCustomAttributeResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetCustomAttributeResult]: """ The `CustomAttribute` data source can be used to reference custom attributes that are not managed by this provider. Its attributes are exactly the @@ -126,7 +126,7 @@ def get_custom_attribute_output(name: Optional[pulumi.Input[str]] = None, """ __args__ = dict() __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getCustomAttribute:getCustomAttribute', __args__, opts=opts, typ=GetCustomAttributeResult) return __ret__.apply(lambda __response__: GetCustomAttributeResult( id=pulumi.get(__response__, 'id'), diff --git a/sdk/python/pulumi_vsphere/get_datacenter.py b/sdk/python/pulumi_vsphere/get_datacenter.py index 47905427..96b05edb 100644 --- a/sdk/python/pulumi_vsphere/get_datacenter.py +++ b/sdk/python/pulumi_vsphere/get_datacenter.py @@ -106,7 +106,7 @@ def get_datacenter(name: Optional[str] = None, name=pulumi.get(__ret__, 'name'), virtual_machines=pulumi.get(__ret__, 'virtual_machines')) def get_datacenter_output(name: Optional[pulumi.Input[Optional[str]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDatacenterResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatacenterResult]: """ The `Datacenter` data source can be used to discover the ID of a vSphere datacenter object. This can then be used with resources or data sources @@ -133,7 +133,7 @@ def get_datacenter_output(name: Optional[pulumi.Input[Optional[str]]] = None, """ __args__ = dict() __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getDatacenter:getDatacenter', __args__, opts=opts, typ=GetDatacenterResult) return __ret__.apply(lambda __response__: GetDatacenterResult( id=pulumi.get(__response__, 'id'), diff --git a/sdk/python/pulumi_vsphere/get_datastore.py b/sdk/python/pulumi_vsphere/get_datastore.py index 2d1d45ca..04e00908 100644 --- a/sdk/python/pulumi_vsphere/get_datastore.py +++ b/sdk/python/pulumi_vsphere/get_datastore.py @@ -127,7 +127,7 @@ def get_datastore(datacenter_id: Optional[str] = None, def get_datastore_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = None, name: Optional[pulumi.Input[str]] = None, stats: Optional[pulumi.Input[Optional[Mapping[str, str]]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDatastoreResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatastoreResult]: """ The `get_datastore` data source can be used to discover the ID of a vSphere datastore object. This can then be used with resources or data sources @@ -159,7 +159,7 @@ def get_datastore_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = __args__['datacenterId'] = datacenter_id __args__['name'] = name __args__['stats'] = stats - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getDatastore:getDatastore', __args__, opts=opts, typ=GetDatastoreResult) return __ret__.apply(lambda __response__: GetDatastoreResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_datastore_cluster.py b/sdk/python/pulumi_vsphere/get_datastore_cluster.py index 22f35a45..e57a9f1a 100644 --- a/sdk/python/pulumi_vsphere/get_datastore_cluster.py +++ b/sdk/python/pulumi_vsphere/get_datastore_cluster.py @@ -121,7 +121,7 @@ def get_datastore_cluster(datacenter_id: Optional[str] = None, name=pulumi.get(__ret__, 'name')) def get_datastore_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = None, name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDatastoreClusterResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatastoreClusterResult]: """ The `DatastoreCluster` data source can be used to discover the ID of a vSphere datastore cluster object. This can then be used with resources or data sources @@ -150,7 +150,7 @@ def get_datastore_cluster_output(datacenter_id: Optional[pulumi.Input[Optional[s __args__ = dict() __args__['datacenterId'] = datacenter_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getDatastoreCluster:getDatastoreCluster', __args__, opts=opts, typ=GetDatastoreClusterResult) return __ret__.apply(lambda __response__: GetDatastoreClusterResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_datastore_stats.py b/sdk/python/pulumi_vsphere/get_datastore_stats.py index 20c731af..6e5ffad7 100644 --- a/sdk/python/pulumi_vsphere/get_datastore_stats.py +++ b/sdk/python/pulumi_vsphere/get_datastore_stats.py @@ -151,7 +151,7 @@ def get_datastore_stats(capacity: Optional[Mapping[str, str]] = None, def get_datastore_stats_output(capacity: Optional[pulumi.Input[Optional[Mapping[str, str]]]] = None, datacenter_id: Optional[pulumi.Input[str]] = None, free_space: Optional[pulumi.Input[Optional[Mapping[str, str]]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDatastoreStatsResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatastoreStatsResult]: """ The `get_datastore_stats` data source can be used to retrieve the usage stats of all vSphere datastore objects in a datacenter. This can then be used as @@ -199,7 +199,7 @@ def get_datastore_stats_output(capacity: Optional[pulumi.Input[Optional[Mapping[ __args__['capacity'] = capacity __args__['datacenterId'] = datacenter_id __args__['freeSpace'] = free_space - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getDatastoreStats:getDatastoreStats', __args__, opts=opts, typ=GetDatastoreStatsResult) return __ret__.apply(lambda __response__: GetDatastoreStatsResult( capacity=pulumi.get(__response__, 'capacity'), diff --git a/sdk/python/pulumi_vsphere/get_distributed_virtual_switch.py b/sdk/python/pulumi_vsphere/get_distributed_virtual_switch.py index 788732a0..ab88d9f5 100644 --- a/sdk/python/pulumi_vsphere/get_distributed_virtual_switch.py +++ b/sdk/python/pulumi_vsphere/get_distributed_virtual_switch.py @@ -136,7 +136,7 @@ def get_distributed_virtual_switch(datacenter_id: Optional[str] = None, uplinks=pulumi.get(__ret__, 'uplinks')) def get_distributed_virtual_switch_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = None, name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDistributedVirtualSwitchResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDistributedVirtualSwitchResult]: """ The `DistributedVirtualSwitch` data source can be used to discover the ID and uplink data of a of a vSphere distributed switch (VDS). This @@ -178,7 +178,7 @@ def get_distributed_virtual_switch_output(datacenter_id: Optional[pulumi.Input[O __args__ = dict() __args__['datacenterId'] = datacenter_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getDistributedVirtualSwitch:getDistributedVirtualSwitch', __args__, opts=opts, typ=GetDistributedVirtualSwitchResult) return __ret__.apply(lambda __response__: GetDistributedVirtualSwitchResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_dynamic.py b/sdk/python/pulumi_vsphere/get_dynamic.py index 64e9a0c4..153d7d4a 100644 --- a/sdk/python/pulumi_vsphere/get_dynamic.py +++ b/sdk/python/pulumi_vsphere/get_dynamic.py @@ -131,7 +131,7 @@ def get_dynamic(filters: Optional[Sequence[str]] = None, def get_dynamic_output(filters: Optional[pulumi.Input[Sequence[str]]] = None, name_regex: Optional[pulumi.Input[Optional[str]]] = None, type: Optional[pulumi.Input[Optional[str]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDynamicResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDynamicResult]: """ [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider @@ -172,7 +172,7 @@ def get_dynamic_output(filters: Optional[pulumi.Input[Sequence[str]]] = None, __args__['filters'] = filters __args__['nameRegex'] = name_regex __args__['type'] = type - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getDynamic:getDynamic', __args__, opts=opts, typ=GetDynamicResult) return __ret__.apply(lambda __response__: GetDynamicResult( filters=pulumi.get(__response__, 'filters'), diff --git a/sdk/python/pulumi_vsphere/get_folder.py b/sdk/python/pulumi_vsphere/get_folder.py index 1b6a1feb..a3886b27 100644 --- a/sdk/python/pulumi_vsphere/get_folder.py +++ b/sdk/python/pulumi_vsphere/get_folder.py @@ -93,7 +93,7 @@ def get_folder(path: Optional[str] = None, id=pulumi.get(__ret__, 'id'), path=pulumi.get(__ret__, 'path')) def get_folder_output(path: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetFolderResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetFolderResult]: """ The `Folder` data source can be used to get the general attributes of a vSphere inventory folder. The data source supports creating folders of the 5 @@ -120,7 +120,7 @@ def get_folder_output(path: Optional[pulumi.Input[str]] = None, """ __args__ = dict() __args__['path'] = path - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getFolder:getFolder', __args__, opts=opts, typ=GetFolderResult) return __ret__.apply(lambda __response__: GetFolderResult( id=pulumi.get(__response__, 'id'), diff --git a/sdk/python/pulumi_vsphere/get_guest_os_customization.py b/sdk/python/pulumi_vsphere/get_guest_os_customization.py index fa8703f2..50cb45db 100644 --- a/sdk/python/pulumi_vsphere/get_guest_os_customization.py +++ b/sdk/python/pulumi_vsphere/get_guest_os_customization.py @@ -128,7 +128,7 @@ def get_guest_os_customization(name: Optional[str] = None, specs=pulumi.get(__ret__, 'specs'), type=pulumi.get(__ret__, 'type')) def get_guest_os_customization_output(name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetGuestOsCustomizationResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetGuestOsCustomizationResult]: """ The `GuestOsCustomization` data source can be used to discover the details about a customization specification for a guest operating system. @@ -139,7 +139,7 @@ def get_guest_os_customization_output(name: Optional[pulumi.Input[str]] = None, """ __args__ = dict() __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getGuestOsCustomization:getGuestOsCustomization', __args__, opts=opts, typ=GetGuestOsCustomizationResult) return __ret__.apply(lambda __response__: GetGuestOsCustomizationResult( change_version=pulumi.get(__response__, 'change_version'), diff --git a/sdk/python/pulumi_vsphere/get_host.py b/sdk/python/pulumi_vsphere/get_host.py index e85731ef..90b1be00 100644 --- a/sdk/python/pulumi_vsphere/get_host.py +++ b/sdk/python/pulumi_vsphere/get_host.py @@ -121,7 +121,7 @@ def get_host(datacenter_id: Optional[str] = None, resource_pool_id=pulumi.get(__ret__, 'resource_pool_id')) def get_host_output(datacenter_id: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[Optional[str]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostResult]: """ The `Host` data source can be used to discover the ID of an ESXi host. This can then be used with resources or data sources that require an ESX @@ -150,7 +150,7 @@ def get_host_output(datacenter_id: Optional[pulumi.Input[str]] = None, __args__ = dict() __args__['datacenterId'] = datacenter_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getHost:getHost', __args__, opts=opts, typ=GetHostResult) return __ret__.apply(lambda __response__: GetHostResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_host_base_images.py b/sdk/python/pulumi_vsphere/get_host_base_images.py index e78e89cc..b891788d 100644 --- a/sdk/python/pulumi_vsphere/get_host_base_images.py +++ b/sdk/python/pulumi_vsphere/get_host_base_images.py @@ -82,7 +82,7 @@ def get_host_base_images(opts: Optional[pulumi.InvokeOptions] = None) -> Awaitab return AwaitableGetHostBaseImagesResult( id=pulumi.get(__ret__, 'id'), versions=pulumi.get(__ret__, 'versions')) -def get_host_base_images_output(opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostBaseImagesResult]: +def get_host_base_images_output(opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostBaseImagesResult]: """ The `get_host_base_images` data source can be used to get the list of ESXi base images available for cluster software management. @@ -97,7 +97,7 @@ def get_host_base_images_output(opts: Optional[pulumi.InvokeOptions] = None) -> ``` """ __args__ = dict() - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getHostBaseImages:getHostBaseImages', __args__, opts=opts, typ=GetHostBaseImagesResult) return __ret__.apply(lambda __response__: GetHostBaseImagesResult( id=pulumi.get(__response__, 'id'), diff --git a/sdk/python/pulumi_vsphere/get_host_pci_device.py b/sdk/python/pulumi_vsphere/get_host_pci_device.py index 7ea97539..9725efaf 100644 --- a/sdk/python/pulumi_vsphere/get_host_pci_device.py +++ b/sdk/python/pulumi_vsphere/get_host_pci_device.py @@ -167,7 +167,7 @@ def get_host_pci_device_output(class_id: Optional[pulumi.Input[Optional[str]]] = host_id: Optional[pulumi.Input[str]] = None, name_regex: Optional[pulumi.Input[Optional[str]]] = None, vendor_id: Optional[pulumi.Input[Optional[str]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostPciDeviceResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostPciDeviceResult]: """ The `get_host_pci_device` data source can be used to discover the device ID of a vSphere host's PCI device. This can then be used with @@ -219,7 +219,7 @@ def get_host_pci_device_output(class_id: Optional[pulumi.Input[Optional[str]]] = __args__['hostId'] = host_id __args__['nameRegex'] = name_regex __args__['vendorId'] = vendor_id - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getHostPciDevice:getHostPciDevice', __args__, opts=opts, typ=GetHostPciDeviceResult) return __ret__.apply(lambda __response__: GetHostPciDeviceResult( class_id=pulumi.get(__response__, 'class_id'), diff --git a/sdk/python/pulumi_vsphere/get_host_thumbprint.py b/sdk/python/pulumi_vsphere/get_host_thumbprint.py index 76266755..31d62d49 100644 --- a/sdk/python/pulumi_vsphere/get_host_thumbprint.py +++ b/sdk/python/pulumi_vsphere/get_host_thumbprint.py @@ -121,7 +121,7 @@ def get_host_thumbprint(address: Optional[str] = None, def get_host_thumbprint_output(address: Optional[pulumi.Input[str]] = None, insecure: Optional[pulumi.Input[Optional[bool]]] = None, port: Optional[pulumi.Input[Optional[str]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostThumbprintResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostThumbprintResult]: """ The `vsphere_thumbprint` data source can be used to discover the host thumbprint of an ESXi host. This can be used when adding the `Host` resource to a @@ -152,7 +152,7 @@ def get_host_thumbprint_output(address: Optional[pulumi.Input[str]] = None, __args__['address'] = address __args__['insecure'] = insecure __args__['port'] = port - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getHostThumbprint:getHostThumbprint', __args__, opts=opts, typ=GetHostThumbprintResult) return __ret__.apply(lambda __response__: GetHostThumbprintResult( address=pulumi.get(__response__, 'address'), diff --git a/sdk/python/pulumi_vsphere/get_host_vgpu_profile.py b/sdk/python/pulumi_vsphere/get_host_vgpu_profile.py index f3393390..b4cc82e2 100644 --- a/sdk/python/pulumi_vsphere/get_host_vgpu_profile.py +++ b/sdk/python/pulumi_vsphere/get_host_vgpu_profile.py @@ -143,7 +143,7 @@ def get_host_vgpu_profile(host_id: Optional[str] = None, vgpu_profiles=pulumi.get(__ret__, 'vgpu_profiles')) def get_host_vgpu_profile_output(host_id: Optional[pulumi.Input[str]] = None, name_regex: Optional[pulumi.Input[Optional[str]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetHostVgpuProfileResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetHostVgpuProfileResult]: """ The `get_host_vgpu_profile` data source can be used to discover the available vGPU profiles of a vSphere host. @@ -186,7 +186,7 @@ def get_host_vgpu_profile_output(host_id: Optional[pulumi.Input[str]] = None, __args__ = dict() __args__['hostId'] = host_id __args__['nameRegex'] = name_regex - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getHostVgpuProfile:getHostVgpuProfile', __args__, opts=opts, typ=GetHostVgpuProfileResult) return __ret__.apply(lambda __response__: GetHostVgpuProfileResult( host_id=pulumi.get(__response__, 'host_id'), diff --git a/sdk/python/pulumi_vsphere/get_license.py b/sdk/python/pulumi_vsphere/get_license.py index 86c5d84a..ed65cb10 100644 --- a/sdk/python/pulumi_vsphere/get_license.py +++ b/sdk/python/pulumi_vsphere/get_license.py @@ -148,7 +148,7 @@ def get_license(license_key: Optional[str] = None, total=pulumi.get(__ret__, 'total'), used=pulumi.get(__ret__, 'used')) def get_license_output(license_key: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetLicenseResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetLicenseResult]: """ The `License` data source can be used to get the general attributes of a license keys from a vCenter Server instance. @@ -167,7 +167,7 @@ def get_license_output(license_key: Optional[pulumi.Input[str]] = None, """ __args__ = dict() __args__['licenseKey'] = license_key - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getLicense:getLicense', __args__, opts=opts, typ=GetLicenseResult) return __ret__.apply(lambda __response__: GetLicenseResult( edition_key=pulumi.get(__response__, 'edition_key'), diff --git a/sdk/python/pulumi_vsphere/get_network.py b/sdk/python/pulumi_vsphere/get_network.py index 79d866a1..ae35553a 100644 --- a/sdk/python/pulumi_vsphere/get_network.py +++ b/sdk/python/pulumi_vsphere/get_network.py @@ -170,7 +170,7 @@ def get_network_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = No distributed_virtual_switch_uuid: Optional[pulumi.Input[Optional[str]]] = None, filters: Optional[pulumi.Input[Optional[Sequence[Union['GetNetworkFilterArgs', 'GetNetworkFilterArgsDict']]]]] = None, name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetNetworkResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetNetworkResult]: """ The `get_network` data source can be used to discover the ID of a network in vSphere. This can be any network that can be used as the backing for a network @@ -220,7 +220,7 @@ def get_network_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = No __args__['distributedVirtualSwitchUuid'] = distributed_virtual_switch_uuid __args__['filters'] = filters __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getNetwork:getNetwork', __args__, opts=opts, typ=GetNetworkResult) return __ret__.apply(lambda __response__: GetNetworkResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_ovf_vm_template.py b/sdk/python/pulumi_vsphere/get_ovf_vm_template.py index 44ee81cf..32cfe319 100644 --- a/sdk/python/pulumi_vsphere/get_ovf_vm_template.py +++ b/sdk/python/pulumi_vsphere/get_ovf_vm_template.py @@ -487,7 +487,7 @@ def get_ovf_vm_template_output(allow_unverified_ssl_cert: Optional[pulumi.Input[ ovf_network_map: Optional[pulumi.Input[Optional[Mapping[str, str]]]] = None, remote_ovf_url: Optional[pulumi.Input[Optional[str]]] = None, resource_pool_id: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetOvfVmTemplateResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetOvfVmTemplateResult]: """ The `get_ovf_vm_template` data source can be used to submit an OVF to vSphere and extract its hardware settings in a form that can be then used as @@ -540,7 +540,7 @@ def get_ovf_vm_template_output(allow_unverified_ssl_cert: Optional[pulumi.Input[ __args__['ovfNetworkMap'] = ovf_network_map __args__['remoteOvfUrl'] = remote_ovf_url __args__['resourcePoolId'] = resource_pool_id - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getOvfVmTemplate:getOvfVmTemplate', __args__, opts=opts, typ=GetOvfVmTemplateResult) return __ret__.apply(lambda __response__: GetOvfVmTemplateResult( allow_unverified_ssl_cert=pulumi.get(__response__, 'allow_unverified_ssl_cert'), diff --git a/sdk/python/pulumi_vsphere/get_policy.py b/sdk/python/pulumi_vsphere/get_policy.py index c7b9dbd9..2edea99b 100644 --- a/sdk/python/pulumi_vsphere/get_policy.py +++ b/sdk/python/pulumi_vsphere/get_policy.py @@ -90,7 +90,7 @@ def get_policy(name: Optional[str] = None, id=pulumi.get(__ret__, 'id'), name=pulumi.get(__ret__, 'name')) def get_policy_output(name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetPolicyResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetPolicyResult]: """ The `get_policy` data source can be used to discover the UUID of a storage policy. This can then be used with other resources or data sources that @@ -114,7 +114,7 @@ def get_policy_output(name: Optional[pulumi.Input[str]] = None, """ __args__ = dict() __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getPolicy:getPolicy', __args__, opts=opts, typ=GetPolicyResult) return __ret__.apply(lambda __response__: GetPolicyResult( id=pulumi.get(__response__, 'id'), diff --git a/sdk/python/pulumi_vsphere/get_resource_pool.py b/sdk/python/pulumi_vsphere/get_resource_pool.py index 14de8080..0855f1c6 100644 --- a/sdk/python/pulumi_vsphere/get_resource_pool.py +++ b/sdk/python/pulumi_vsphere/get_resource_pool.py @@ -136,7 +136,7 @@ def get_resource_pool(datacenter_id: Optional[str] = None, name=pulumi.get(__ret__, 'name')) def get_resource_pool_output(datacenter_id: Optional[pulumi.Input[Optional[str]]] = None, name: Optional[pulumi.Input[Optional[str]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetResourcePoolResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetResourcePoolResult]: """ The `ResourcePool` data source can be used to discover the ID of a resource pool in vSphere. This is useful to return the ID of a resource pool @@ -194,7 +194,7 @@ def get_resource_pool_output(datacenter_id: Optional[pulumi.Input[Optional[str]] __args__ = dict() __args__['datacenterId'] = datacenter_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getResourcePool:getResourcePool', __args__, opts=opts, typ=GetResourcePoolResult) return __ret__.apply(lambda __response__: GetResourcePoolResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_role.py b/sdk/python/pulumi_vsphere/get_role.py index 1e74a089..3a0073fb 100644 --- a/sdk/python/pulumi_vsphere/get_role.py +++ b/sdk/python/pulumi_vsphere/get_role.py @@ -135,7 +135,7 @@ def get_role_output(description: Optional[pulumi.Input[Optional[str]]] = None, label: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[Optional[str]]] = None, role_privileges: Optional[pulumi.Input[Optional[Sequence[str]]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetRoleResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetRoleResult]: """ The `Role` data source can be used to discover the `id` and privileges associated with a role given its name or display label. @@ -159,7 +159,7 @@ def get_role_output(description: Optional[pulumi.Input[Optional[str]]] = None, __args__['label'] = label __args__['name'] = name __args__['rolePrivileges'] = role_privileges - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getRole:getRole', __args__, opts=opts, typ=GetRoleResult) return __ret__.apply(lambda __response__: GetRoleResult( description=pulumi.get(__response__, 'description'), diff --git a/sdk/python/pulumi_vsphere/get_tag.py b/sdk/python/pulumi_vsphere/get_tag.py index 3f167684..f38d12d0 100644 --- a/sdk/python/pulumi_vsphere/get_tag.py +++ b/sdk/python/pulumi_vsphere/get_tag.py @@ -118,7 +118,7 @@ def get_tag(category_id: Optional[str] = None, name=pulumi.get(__ret__, 'name')) def get_tag_output(category_id: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetTagResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetTagResult]: """ The `Tag` data source can be used to reference tags that are not managed by this provider. Its attributes are exactly the same as the `Tag` @@ -148,7 +148,7 @@ def get_tag_output(category_id: Optional[pulumi.Input[str]] = None, __args__ = dict() __args__['categoryId'] = category_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getTag:getTag', __args__, opts=opts, typ=GetTagResult) return __ret__.apply(lambda __response__: GetTagResult( category_id=pulumi.get(__response__, 'category_id'), diff --git a/sdk/python/pulumi_vsphere/get_tag_category.py b/sdk/python/pulumi_vsphere/get_tag_category.py index e0b7ac62..11791181 100644 --- a/sdk/python/pulumi_vsphere/get_tag_category.py +++ b/sdk/python/pulumi_vsphere/get_tag_category.py @@ -121,7 +121,7 @@ def get_tag_category(name: Optional[str] = None, id=pulumi.get(__ret__, 'id'), name=pulumi.get(__ret__, 'name')) def get_tag_category_output(name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetTagCategoryResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetTagCategoryResult]: """ The `TagCategory` data source can be used to reference tag categories that are not managed by this provider. Its attributes are the same as the @@ -146,7 +146,7 @@ def get_tag_category_output(name: Optional[pulumi.Input[str]] = None, """ __args__ = dict() __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getTagCategory:getTagCategory', __args__, opts=opts, typ=GetTagCategoryResult) return __ret__.apply(lambda __response__: GetTagCategoryResult( associable_types=pulumi.get(__response__, 'associable_types'), diff --git a/sdk/python/pulumi_vsphere/get_vapp_container.py b/sdk/python/pulumi_vsphere/get_vapp_container.py index 7a8ddb71..d91fcdac 100644 --- a/sdk/python/pulumi_vsphere/get_vapp_container.py +++ b/sdk/python/pulumi_vsphere/get_vapp_container.py @@ -105,7 +105,7 @@ def get_vapp_container(datacenter_id: Optional[str] = None, name=pulumi.get(__ret__, 'name')) def get_vapp_container_output(datacenter_id: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[str]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetVappContainerResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetVappContainerResult]: """ The `VappContainer` data source can be used to discover the ID of a vApp container in vSphere. This is useful to return the ID of a vApp container @@ -132,7 +132,7 @@ def get_vapp_container_output(datacenter_id: Optional[pulumi.Input[str]] = None, __args__ = dict() __args__['datacenterId'] = datacenter_id __args__['name'] = name - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getVappContainer:getVappContainer', __args__, opts=opts, typ=GetVappContainerResult) return __ret__.apply(lambda __response__: GetVappContainerResult( datacenter_id=pulumi.get(__response__, 'datacenter_id'), diff --git a/sdk/python/pulumi_vsphere/get_virtual_machine.py b/sdk/python/pulumi_vsphere/get_virtual_machine.py index 26436ab0..6247d1cf 100644 --- a/sdk/python/pulumi_vsphere/get_virtual_machine.py +++ b/sdk/python/pulumi_vsphere/get_virtual_machine.py @@ -1034,7 +1034,7 @@ def get_virtual_machine_output(alternate_guest_name: Optional[pulumi.Input[Optio vapp: Optional[pulumi.Input[Optional[Union['GetVirtualMachineVappArgs', 'GetVirtualMachineVappArgsDict']]]] = None, vbs_enabled: Optional[pulumi.Input[Optional[bool]]] = None, vvtd_enabled: Optional[pulumi.Input[Optional[bool]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetVirtualMachineResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetVirtualMachineResult]: """ The `VirtualMachine` data source can be used to find the UUID of an existing virtual machine or template. The most common purpose is for finding @@ -1160,7 +1160,7 @@ def get_virtual_machine_output(alternate_guest_name: Optional[pulumi.Input[Optio __args__['vapp'] = vapp __args__['vbsEnabled'] = vbs_enabled __args__['vvtdEnabled'] = vvtd_enabled - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getVirtualMachine:getVirtualMachine', __args__, opts=opts, typ=GetVirtualMachineResult) return __ret__.apply(lambda __response__: GetVirtualMachineResult( alternate_guest_name=pulumi.get(__response__, 'alternate_guest_name'), diff --git a/sdk/python/pulumi_vsphere/get_vmfs_disks.py b/sdk/python/pulumi_vsphere/get_vmfs_disks.py index c0128be2..6ca084fe 100644 --- a/sdk/python/pulumi_vsphere/get_vmfs_disks.py +++ b/sdk/python/pulumi_vsphere/get_vmfs_disks.py @@ -142,7 +142,7 @@ def get_vmfs_disks(filter: Optional[str] = None, def get_vmfs_disks_output(filter: Optional[pulumi.Input[Optional[str]]] = None, host_system_id: Optional[pulumi.Input[str]] = None, rescan: Optional[pulumi.Input[Optional[bool]]] = None, - opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetVmfsDisksResult]: + opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetVmfsDisksResult]: """ The `get_vmfs_disks` data source can be used to discover the storage devices available on an ESXi host. This data source can be combined with the @@ -180,7 +180,7 @@ def get_vmfs_disks_output(filter: Optional[pulumi.Input[Optional[str]]] = None, __args__['filter'] = filter __args__['hostSystemId'] = host_system_id __args__['rescan'] = rescan - opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts) + opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts) __ret__ = pulumi.runtime.invoke_output('vsphere:index/getVmfsDisks:getVmfsDisks', __args__, opts=opts, typ=GetVmfsDisksResult) return __ret__.apply(lambda __response__: GetVmfsDisksResult( disks=pulumi.get(__response__, 'disks'),