GetVappContainer
The vsphere..VappContainer data source can be used to discover the ID of a
vApp container in vSphere. This is useful to fetch the ID of a vApp container
that you want to use to create virtual machines in using the
vsphere..VirtualMachine resource.
Example Usage
using Pulumi;
using VSphere = Pulumi.VSphere;
class MyStack : Stack
{
public MyStack()
{
var datacenter = Output.Create(VSphere.GetDatacenter.InvokeAsync(new VSphere.GetDatacenterArgs
{
Name = "dc1",
}));
var pool = datacenter.Apply(datacenter => Output.Create(VSphere.GetVappContainer.InvokeAsync(new VSphere.GetVappContainerArgs
{
DatacenterId = datacenter.Id,
Name = "vapp-container-1",
})));
}
}
Coming soon!
import pulumi
import pulumi_vsphere as vsphere
datacenter = vsphere.get_datacenter(name="dc1")
pool = vsphere.get_vapp_container(datacenter_id=datacenter.id,
name="vapp-container-1")import * as pulumi from "@pulumi/pulumi";
import * as vsphere from "@pulumi/vsphere";
const datacenter = pulumi.output(vsphere.getDatacenter({
name: "dc1",
}, { async: true }));
const pool = datacenter.apply(datacenter => vsphere.getVappContainer({
datacenterId: datacenter.id,
name: "vapp-container-1",
}, { async: true }));Using GetVappContainer
function getVappContainer(args: GetVappContainerArgs, opts?: InvokeOptions): Promise<GetVappContainerResult>function get_vapp_container(datacenter_id=None, name=None, opts=None)func LookupVappContainer(ctx *Context, args *LookupVappContainerArgs, opts ...InvokeOption) (*LookupVappContainerResult, error)Note: This function is named
LookupVappContainerin the Go SDK.
public static class GetVappContainer {
public static Task<GetVappContainerResult> InvokeAsync(GetVappContainerArgs args, InvokeOptions? opts = null)
}The following arguments are supported:
- Datacenter
Id string The managed object reference ID of the datacenter the vApp container is located in.
- Name string
The name of the vApp container. This can be a name or path.
- Datacenter
Id string The managed object reference ID of the datacenter the vApp container is located in.
- Name string
The name of the vApp container. This can be a name or path.
- datacenter
Id string The managed object reference ID of the datacenter the vApp container is located in.
- name string
The name of the vApp container. This can be a name or path.
- datacenter_
id str The managed object reference ID of the datacenter the vApp container is located in.
- name str
The name of the vApp container. This can be a name or path.
GetVappContainer Result
The following output properties are available:
Package Details
- Repository
- https://github.com/pulumi/pulumi-vsphere
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
vsphereTerraform Provider.