1. Packages
  2. Vcd Provider
  3. API Docs
  4. VmVgpuPolicy
vcd 3.14.1 published on Monday, Apr 14, 2025 by vmware

vcd.VmVgpuPolicy

Explore with Pulumi AI

Experimental in provider 3.11.

Note: This resource requires system administrator privileges.

Provides a resource to manage vGPU policies for virtual machines in VMware Cloud Director.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as vcd from "@pulumi/vcd";

const exampleOrg = vcd.getOrg({
    name: "test_org",
});
const exampleVgpuProfile = vcd.getVgpuProfile({
    name: "grid_a100-10c",
});
const exampleProviderVdc = vcd.getProviderVdc({
    name: "example_provider_vdc",
});
const vmGroupExample = vcd.getVmGroup({
    name: "vm-group-1",
});
const exampleVgpuPolicy = new vcd.VmVgpuPolicy("exampleVgpuPolicy", {
    description: "An example vGPU policy configuration",
    vgpuProfile: {
        id: exampleVgpuProfile.then(exampleVgpuProfile => exampleVgpuProfile.id),
        count: 1,
    },
    cpu: {
        shares: "886",
        limitInMhz: "2400",
        count: "9",
        speedInMhz: "2500",
        coresPerSocket: "3",
        reservationGuarantee: "0.55",
    },
    memory: {
        shares: "1580",
        sizeInMb: "3200",
        limitInMb: "2800",
    },
    providerVdcScopes: [{
        providerVdcId: exampleProviderVdc.then(exampleProviderVdc => exampleProviderVdc.id),
        clusterNames: ["cluster1"],
        vmGroupId: vmGroupExample.then(vmGroupExample => vmGroupExample.id),
    }],
});
const exampleOrgVdc = new vcd.OrgVdc("exampleOrgVdc", {
    org: exampleOrg.then(exampleOrg => exampleOrg.name),
    providerVdcName: exampleProviderVdc.then(exampleProviderVdc => exampleProviderVdc.name),
    allocationModel: "Flex",
    deleteForce: true,
    computeCapacity: {
        cpu: {
            allocated: 2048,
        },
        memory: {
            allocated: 2048,
        },
    },
    storageProfiles: [{
        name: "*",
        limit: 10240,
        "default": true,
    }],
    elasticity: true,
    includeVmMemoryOverhead: true,
    memoryGuaranteed: 1,
    defaultComputePolicyId: exampleVgpuPolicy.vmVgpuPolicyId,
    vmVgpuPolicyIds: [exampleVgpuPolicy.vmVgpuPolicyId],
});
const testVm = new vcd.Vm("testVm", {
    org: exampleOrg.then(exampleOrg => exampleOrg.name),
    vdc: exampleOrgVdc.name,
    computerName: "emptyVM",
    memory: 2048,
    cpus: 2,
    cpuCores: 1,
    powerOn: false,
    osType: "sles11_64Guest",
    hardwareVersion: "vmx-19",
    placementPolicyId: exampleVgpuPolicy.vmVgpuPolicyId,
});
Copy
import pulumi
import pulumi_vcd as vcd

example_org = vcd.get_org(name="test_org")
example_vgpu_profile = vcd.get_vgpu_profile(name="grid_a100-10c")
example_provider_vdc = vcd.get_provider_vdc(name="example_provider_vdc")
vm_group_example = vcd.get_vm_group(name="vm-group-1")
example_vgpu_policy = vcd.VmVgpuPolicy("exampleVgpuPolicy",
    description="An example vGPU policy configuration",
    vgpu_profile={
        "id": example_vgpu_profile.id,
        "count": 1,
    },
    cpu={
        "shares": "886",
        "limit_in_mhz": "2400",
        "count": "9",
        "speed_in_mhz": "2500",
        "cores_per_socket": "3",
        "reservation_guarantee": "0.55",
    },
    memory={
        "shares": "1580",
        "size_in_mb": "3200",
        "limit_in_mb": "2800",
    },
    provider_vdc_scopes=[{
        "provider_vdc_id": example_provider_vdc.id,
        "cluster_names": ["cluster1"],
        "vm_group_id": vm_group_example.id,
    }])
example_org_vdc = vcd.OrgVdc("exampleOrgVdc",
    org=example_org.name,
    provider_vdc_name=example_provider_vdc.name,
    allocation_model="Flex",
    delete_force=True,
    compute_capacity={
        "cpu": {
            "allocated": 2048,
        },
        "memory": {
            "allocated": 2048,
        },
    },
    storage_profiles=[{
        "name": "*",
        "limit": 10240,
        "default": True,
    }],
    elasticity=True,
    include_vm_memory_overhead=True,
    memory_guaranteed=1,
    default_compute_policy_id=example_vgpu_policy.vm_vgpu_policy_id,
    vm_vgpu_policy_ids=[example_vgpu_policy.vm_vgpu_policy_id])
test_vm = vcd.Vm("testVm",
    org=example_org.name,
    vdc=example_org_vdc.name,
    computer_name="emptyVM",
    memory=2048,
    cpus=2,
    cpu_cores=1,
    power_on=False,
    os_type="sles11_64Guest",
    hardware_version="vmx-19",
    placement_policy_id=example_vgpu_policy.vm_vgpu_policy_id)
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/vcd/v3/vcd"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleOrg, err := vcd.LookupOrg(ctx, &vcd.LookupOrgArgs{
			Name: "test_org",
		}, nil)
		if err != nil {
			return err
		}
		exampleVgpuProfile, err := vcd.GetVgpuProfile(ctx, &vcd.GetVgpuProfileArgs{
			Name: "grid_a100-10c",
		}, nil)
		if err != nil {
			return err
		}
		exampleProviderVdc, err := vcd.LookupProviderVdc(ctx, &vcd.LookupProviderVdcArgs{
			Name: "example_provider_vdc",
		}, nil)
		if err != nil {
			return err
		}
		vmGroupExample, err := vcd.GetVmGroup(ctx, &vcd.GetVmGroupArgs{
			Name: "vm-group-1",
		}, nil)
		if err != nil {
			return err
		}
		exampleVgpuPolicy, err := vcd.NewVmVgpuPolicy(ctx, "exampleVgpuPolicy", &vcd.VmVgpuPolicyArgs{
			Description: pulumi.String("An example vGPU policy configuration"),
			VgpuProfile: &vcd.VmVgpuPolicyVgpuProfileArgs{
				Id:    pulumi.String(exampleVgpuProfile.Id),
				Count: pulumi.Float64(1),
			},
			Cpu: &vcd.VmVgpuPolicyCpuArgs{
				Shares:               pulumi.String("886"),
				LimitInMhz:           pulumi.String("2400"),
				Count:                pulumi.String("9"),
				SpeedInMhz:           pulumi.String("2500"),
				CoresPerSocket:       pulumi.String("3"),
				ReservationGuarantee: pulumi.String("0.55"),
			},
			Memory: &vcd.VmVgpuPolicyMemoryArgs{
				Shares:    pulumi.String("1580"),
				SizeInMb:  pulumi.String("3200"),
				LimitInMb: pulumi.String("2800"),
			},
			ProviderVdcScopes: vcd.VmVgpuPolicyProviderVdcScopeArray{
				&vcd.VmVgpuPolicyProviderVdcScopeArgs{
					ProviderVdcId: pulumi.String(exampleProviderVdc.Id),
					ClusterNames: pulumi.StringArray{
						pulumi.String("cluster1"),
					},
					VmGroupId: pulumi.String(vmGroupExample.Id),
				},
			},
		})
		if err != nil {
			return err
		}
		exampleOrgVdc, err := vcd.NewOrgVdc(ctx, "exampleOrgVdc", &vcd.OrgVdcArgs{
			Org:             pulumi.String(exampleOrg.Name),
			ProviderVdcName: pulumi.String(exampleProviderVdc.Name),
			AllocationModel: pulumi.String("Flex"),
			DeleteForce:     pulumi.Bool(true),
			ComputeCapacity: &vcd.OrgVdcComputeCapacityArgs{
				Cpu: &vcd.OrgVdcComputeCapacityCpuArgs{
					Allocated: pulumi.Float64(2048),
				},
				Memory: &vcd.OrgVdcComputeCapacityMemoryArgs{
					Allocated: pulumi.Float64(2048),
				},
			},
			StorageProfiles: vcd.OrgVdcStorageProfileArray{
				&vcd.OrgVdcStorageProfileArgs{
					Name:    pulumi.String("*"),
					Limit:   pulumi.Float64(10240),
					Default: pulumi.Bool(true),
				},
			},
			Elasticity:              pulumi.Bool(true),
			IncludeVmMemoryOverhead: pulumi.Bool(true),
			MemoryGuaranteed:        pulumi.Float64(1),
			DefaultComputePolicyId:  exampleVgpuPolicy.VmVgpuPolicyId,
			VmVgpuPolicyIds: pulumi.StringArray{
				exampleVgpuPolicy.VmVgpuPolicyId,
			},
		})
		if err != nil {
			return err
		}
		_, err = vcd.NewVm(ctx, "testVm", &vcd.VmArgs{
			Org:               pulumi.String(exampleOrg.Name),
			Vdc:               exampleOrgVdc.Name,
			ComputerName:      pulumi.String("emptyVM"),
			Memory:            pulumi.Float64(2048),
			Cpus:              pulumi.Float64(2),
			CpuCores:          pulumi.Float64(1),
			PowerOn:           pulumi.Bool(false),
			OsType:            pulumi.String("sles11_64Guest"),
			HardwareVersion:   pulumi.String("vmx-19"),
			PlacementPolicyId: exampleVgpuPolicy.VmVgpuPolicyId,
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vcd = Pulumi.Vcd;

return await Deployment.RunAsync(() => 
{
    var exampleOrg = Vcd.GetOrg.Invoke(new()
    {
        Name = "test_org",
    });

    var exampleVgpuProfile = Vcd.GetVgpuProfile.Invoke(new()
    {
        Name = "grid_a100-10c",
    });

    var exampleProviderVdc = Vcd.GetProviderVdc.Invoke(new()
    {
        Name = "example_provider_vdc",
    });

    var vmGroupExample = Vcd.GetVmGroup.Invoke(new()
    {
        Name = "vm-group-1",
    });

    var exampleVgpuPolicy = new Vcd.VmVgpuPolicy("exampleVgpuPolicy", new()
    {
        Description = "An example vGPU policy configuration",
        VgpuProfile = new Vcd.Inputs.VmVgpuPolicyVgpuProfileArgs
        {
            Id = exampleVgpuProfile.Apply(getVgpuProfileResult => getVgpuProfileResult.Id),
            Count = 1,
        },
        Cpu = new Vcd.Inputs.VmVgpuPolicyCpuArgs
        {
            Shares = "886",
            LimitInMhz = "2400",
            Count = "9",
            SpeedInMhz = "2500",
            CoresPerSocket = "3",
            ReservationGuarantee = "0.55",
        },
        Memory = new Vcd.Inputs.VmVgpuPolicyMemoryArgs
        {
            Shares = "1580",
            SizeInMb = "3200",
            LimitInMb = "2800",
        },
        ProviderVdcScopes = new[]
        {
            new Vcd.Inputs.VmVgpuPolicyProviderVdcScopeArgs
            {
                ProviderVdcId = exampleProviderVdc.Apply(getProviderVdcResult => getProviderVdcResult.Id),
                ClusterNames = new[]
                {
                    "cluster1",
                },
                VmGroupId = vmGroupExample.Apply(getVmGroupResult => getVmGroupResult.Id),
            },
        },
    });

    var exampleOrgVdc = new Vcd.OrgVdc("exampleOrgVdc", new()
    {
        Org = exampleOrg.Apply(getOrgResult => getOrgResult.Name),
        ProviderVdcName = exampleProviderVdc.Apply(getProviderVdcResult => getProviderVdcResult.Name),
        AllocationModel = "Flex",
        DeleteForce = true,
        ComputeCapacity = new Vcd.Inputs.OrgVdcComputeCapacityArgs
        {
            Cpu = new Vcd.Inputs.OrgVdcComputeCapacityCpuArgs
            {
                Allocated = 2048,
            },
            Memory = new Vcd.Inputs.OrgVdcComputeCapacityMemoryArgs
            {
                Allocated = 2048,
            },
        },
        StorageProfiles = new[]
        {
            new Vcd.Inputs.OrgVdcStorageProfileArgs
            {
                Name = "*",
                Limit = 10240,
                Default = true,
            },
        },
        Elasticity = true,
        IncludeVmMemoryOverhead = true,
        MemoryGuaranteed = 1,
        DefaultComputePolicyId = exampleVgpuPolicy.VmVgpuPolicyId,
        VmVgpuPolicyIds = new[]
        {
            exampleVgpuPolicy.VmVgpuPolicyId,
        },
    });

    var testVm = new Vcd.Vm("testVm", new()
    {
        Org = exampleOrg.Apply(getOrgResult => getOrgResult.Name),
        Vdc = exampleOrgVdc.Name,
        ComputerName = "emptyVM",
        Memory = 2048,
        Cpus = 2,
        CpuCores = 1,
        PowerOn = false,
        OsType = "sles11_64Guest",
        HardwareVersion = "vmx-19",
        PlacementPolicyId = exampleVgpuPolicy.VmVgpuPolicyId,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vcd.VcdFunctions;
import com.pulumi.vcd.inputs.GetOrgArgs;
import com.pulumi.vcd.inputs.GetVgpuProfileArgs;
import com.pulumi.vcd.inputs.GetProviderVdcArgs;
import com.pulumi.vcd.inputs.GetVmGroupArgs;
import com.pulumi.vcd.VmVgpuPolicy;
import com.pulumi.vcd.VmVgpuPolicyArgs;
import com.pulumi.vcd.inputs.VmVgpuPolicyVgpuProfileArgs;
import com.pulumi.vcd.inputs.VmVgpuPolicyCpuArgs;
import com.pulumi.vcd.inputs.VmVgpuPolicyMemoryArgs;
import com.pulumi.vcd.inputs.VmVgpuPolicyProviderVdcScopeArgs;
import com.pulumi.vcd.OrgVdc;
import com.pulumi.vcd.OrgVdcArgs;
import com.pulumi.vcd.inputs.OrgVdcComputeCapacityArgs;
import com.pulumi.vcd.inputs.OrgVdcComputeCapacityCpuArgs;
import com.pulumi.vcd.inputs.OrgVdcComputeCapacityMemoryArgs;
import com.pulumi.vcd.inputs.OrgVdcStorageProfileArgs;
import com.pulumi.vcd.Vm;
import com.pulumi.vcd.VmArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var exampleOrg = VcdFunctions.getOrg(GetOrgArgs.builder()
            .name("test_org")
            .build());

        final var exampleVgpuProfile = VcdFunctions.getVgpuProfile(GetVgpuProfileArgs.builder()
            .name("grid_a100-10c")
            .build());

        final var exampleProviderVdc = VcdFunctions.getProviderVdc(GetProviderVdcArgs.builder()
            .name("example_provider_vdc")
            .build());

        final var vmGroupExample = VcdFunctions.getVmGroup(GetVmGroupArgs.builder()
            .name("vm-group-1")
            .build());

        var exampleVgpuPolicy = new VmVgpuPolicy("exampleVgpuPolicy", VmVgpuPolicyArgs.builder()
            .description("An example vGPU policy configuration")
            .vgpuProfile(VmVgpuPolicyVgpuProfileArgs.builder()
                .id(exampleVgpuProfile.applyValue(getVgpuProfileResult -> getVgpuProfileResult.id()))
                .count(1)
                .build())
            .cpu(VmVgpuPolicyCpuArgs.builder()
                .shares("886")
                .limitInMhz("2400")
                .count("9")
                .speedInMhz("2500")
                .coresPerSocket("3")
                .reservationGuarantee("0.55")
                .build())
            .memory(VmVgpuPolicyMemoryArgs.builder()
                .shares("1580")
                .sizeInMb("3200")
                .limitInMb("2800")
                .build())
            .providerVdcScopes(VmVgpuPolicyProviderVdcScopeArgs.builder()
                .providerVdcId(exampleProviderVdc.applyValue(getProviderVdcResult -> getProviderVdcResult.id()))
                .clusterNames("cluster1")
                .vmGroupId(vmGroupExample.applyValue(getVmGroupResult -> getVmGroupResult.id()))
                .build())
            .build());

        var exampleOrgVdc = new OrgVdc("exampleOrgVdc", OrgVdcArgs.builder()
            .org(exampleOrg.applyValue(getOrgResult -> getOrgResult.name()))
            .providerVdcName(exampleProviderVdc.applyValue(getProviderVdcResult -> getProviderVdcResult.name()))
            .allocationModel("Flex")
            .deleteForce(true)
            .computeCapacity(OrgVdcComputeCapacityArgs.builder()
                .cpu(OrgVdcComputeCapacityCpuArgs.builder()
                    .allocated(2048)
                    .build())
                .memory(OrgVdcComputeCapacityMemoryArgs.builder()
                    .allocated(2048)
                    .build())
                .build())
            .storageProfiles(OrgVdcStorageProfileArgs.builder()
                .name("*")
                .limit(10240)
                .default_(true)
                .build())
            .elasticity(true)
            .includeVmMemoryOverhead(true)
            .memoryGuaranteed(1)
            .defaultComputePolicyId(exampleVgpuPolicy.vmVgpuPolicyId())
            .vmVgpuPolicyIds(exampleVgpuPolicy.vmVgpuPolicyId())
            .build());

        var testVm = new Vm("testVm", VmArgs.builder()
            .org(exampleOrg.applyValue(getOrgResult -> getOrgResult.name()))
            .vdc(exampleOrgVdc.name())
            .computerName("emptyVM")
            .memory(2048)
            .cpus(2)
            .cpuCores(1)
            .powerOn(false)
            .osType("sles11_64Guest")
            .hardwareVersion("vmx-19")
            .placementPolicyId(exampleVgpuPolicy.vmVgpuPolicyId())
            .build());

    }
}
Copy
resources:
  exampleVgpuPolicy:
    type: vcd:VmVgpuPolicy
    properties:
      description: An example vGPU policy configuration
      vgpuProfile:
        id: ${exampleVgpuProfile.id}
        count: 1
      cpu:
        shares: '886'
        limitInMhz: '2400'
        count: '9'
        speedInMhz: '2500'
        coresPerSocket: '3'
        reservationGuarantee: '0.55'
      memory:
        shares: '1580'
        sizeInMb: '3200'
        limitInMb: '2800'
      providerVdcScopes:
        - providerVdcId: ${exampleProviderVdc.id}
          clusterNames:
            - cluster1
          vmGroupId: ${vmGroupExample.id}
  exampleOrgVdc:
    type: vcd:OrgVdc
    properties:
      org: ${exampleOrg.name}
      providerVdcName: ${exampleProviderVdc.name}
      allocationModel: Flex
      deleteForce: true
      computeCapacity:
        cpu:
          allocated: 2048
        memory:
          allocated: 2048
      storageProfiles:
        - name: '*'
          limit: 10240
          default: true
      elasticity: true
      includeVmMemoryOverhead: true
      memoryGuaranteed: 1
      defaultComputePolicyId: ${exampleVgpuPolicy.vmVgpuPolicyId}
      vmVgpuPolicyIds:
        - ${exampleVgpuPolicy.vmVgpuPolicyId}
  testVm:
    type: vcd:Vm
    properties:
      org: ${exampleOrg.name}
      vdc: ${exampleOrgVdc.name}
      computerName: emptyVM
      memory: 2048
      cpus: 2
      cpuCores: 1
      powerOn: false
      osType: sles11_64Guest
      hardwareVersion: vmx-19
      placementPolicyId: ${exampleVgpuPolicy.vmVgpuPolicyId}
variables:
  exampleOrg:
    fn::invoke:
      function: vcd:getOrg
      arguments:
        name: test_org
  exampleVgpuProfile:
    fn::invoke:
      function: vcd:getVgpuProfile
      arguments:
        name: grid_a100-10c
  exampleProviderVdc:
    fn::invoke:
      function: vcd:getProviderVdc
      arguments:
        name: example_provider_vdc
  vmGroupExample:
    fn::invoke:
      function: vcd:getVmGroup
      arguments:
        name: vm-group-1
Copy

Without A Sizing Policy)

import * as pulumi from "@pulumi/pulumi";
import * as vcd from "@pulumi/vcd";

const exampleVgpuPolicyWithoutSizing = new vcd.VmVgpuPolicy("exampleVgpuPolicyWithoutSizing", {
    description: "An example vGPU policy configuration",
    vgpuProfile: {
        id: data.vcd_vgpu_profile.example_vgpu_profile.id,
        count: 1,
    },
    providerVdcScopes: [{
        providerVdcId: data.vcd_provider_vdc.example_provider_vdc.id,
        clusterNames: ["cluster1"],
        vmGroupId: data.vcd_vm_group.vm_group_example.id,
    }],
});
Copy
import pulumi
import pulumi_vcd as vcd

example_vgpu_policy_without_sizing = vcd.VmVgpuPolicy("exampleVgpuPolicyWithoutSizing",
    description="An example vGPU policy configuration",
    vgpu_profile={
        "id": data["vcd_vgpu_profile"]["example_vgpu_profile"]["id"],
        "count": 1,
    },
    provider_vdc_scopes=[{
        "provider_vdc_id": data["vcd_provider_vdc"]["example_provider_vdc"]["id"],
        "cluster_names": ["cluster1"],
        "vm_group_id": data["vcd_vm_group"]["vm_group_example"]["id"],
    }])
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/vcd/v3/vcd"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := vcd.NewVmVgpuPolicy(ctx, "exampleVgpuPolicyWithoutSizing", &vcd.VmVgpuPolicyArgs{
			Description: pulumi.String("An example vGPU policy configuration"),
			VgpuProfile: &vcd.VmVgpuPolicyVgpuProfileArgs{
				Id:    pulumi.Any(data.Vcd_vgpu_profile.Example_vgpu_profile.Id),
				Count: pulumi.Float64(1),
			},
			ProviderVdcScopes: vcd.VmVgpuPolicyProviderVdcScopeArray{
				&vcd.VmVgpuPolicyProviderVdcScopeArgs{
					ProviderVdcId: pulumi.Any(data.Vcd_provider_vdc.Example_provider_vdc.Id),
					ClusterNames: pulumi.StringArray{
						pulumi.String("cluster1"),
					},
					VmGroupId: pulumi.Any(data.Vcd_vm_group.Vm_group_example.Id),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vcd = Pulumi.Vcd;

return await Deployment.RunAsync(() => 
{
    var exampleVgpuPolicyWithoutSizing = new Vcd.VmVgpuPolicy("exampleVgpuPolicyWithoutSizing", new()
    {
        Description = "An example vGPU policy configuration",
        VgpuProfile = new Vcd.Inputs.VmVgpuPolicyVgpuProfileArgs
        {
            Id = data.Vcd_vgpu_profile.Example_vgpu_profile.Id,
            Count = 1,
        },
        ProviderVdcScopes = new[]
        {
            new Vcd.Inputs.VmVgpuPolicyProviderVdcScopeArgs
            {
                ProviderVdcId = data.Vcd_provider_vdc.Example_provider_vdc.Id,
                ClusterNames = new[]
                {
                    "cluster1",
                },
                VmGroupId = data.Vcd_vm_group.Vm_group_example.Id,
            },
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vcd.VmVgpuPolicy;
import com.pulumi.vcd.VmVgpuPolicyArgs;
import com.pulumi.vcd.inputs.VmVgpuPolicyVgpuProfileArgs;
import com.pulumi.vcd.inputs.VmVgpuPolicyProviderVdcScopeArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var exampleVgpuPolicyWithoutSizing = new VmVgpuPolicy("exampleVgpuPolicyWithoutSizing", VmVgpuPolicyArgs.builder()
            .description("An example vGPU policy configuration")
            .vgpuProfile(VmVgpuPolicyVgpuProfileArgs.builder()
                .id(data.vcd_vgpu_profile().example_vgpu_profile().id())
                .count(1)
                .build())
            .providerVdcScopes(VmVgpuPolicyProviderVdcScopeArgs.builder()
                .providerVdcId(data.vcd_provider_vdc().example_provider_vdc().id())
                .clusterNames("cluster1")
                .vmGroupId(data.vcd_vm_group().vm_group_example().id())
                .build())
            .build());

    }
}
Copy
resources:
  exampleVgpuPolicyWithoutSizing:
    type: vcd:VmVgpuPolicy
    properties:
      description: An example vGPU policy configuration
      vgpuProfile:
        id: ${data.vcd_vgpu_profile.example_vgpu_profile.id}
        count: 1
      providerVdcScopes:
        - providerVdcId: ${data.vcd_provider_vdc.example_provider_vdc.id}
          clusterNames:
            - cluster1
          vmGroupId: ${data.vcd_vm_group.vm_group_example.id}
Copy

Create VmVgpuPolicy Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new VmVgpuPolicy(name: string, args: VmVgpuPolicyArgs, opts?: CustomResourceOptions);
@overload
def VmVgpuPolicy(resource_name: str,
                 args: VmVgpuPolicyArgs,
                 opts: Optional[ResourceOptions] = None)

@overload
def VmVgpuPolicy(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 vgpu_profile: Optional[VmVgpuPolicyVgpuProfileArgs] = None,
                 cpu: Optional[VmVgpuPolicyCpuArgs] = None,
                 description: Optional[str] = None,
                 memory: Optional[VmVgpuPolicyMemoryArgs] = None,
                 name: Optional[str] = None,
                 provider_vdc_scopes: Optional[Sequence[VmVgpuPolicyProviderVdcScopeArgs]] = None,
                 vm_vgpu_policy_id: Optional[str] = None)
func NewVmVgpuPolicy(ctx *Context, name string, args VmVgpuPolicyArgs, opts ...ResourceOption) (*VmVgpuPolicy, error)
public VmVgpuPolicy(string name, VmVgpuPolicyArgs args, CustomResourceOptions? opts = null)
public VmVgpuPolicy(String name, VmVgpuPolicyArgs args)
public VmVgpuPolicy(String name, VmVgpuPolicyArgs args, CustomResourceOptions options)
type: vcd:VmVgpuPolicy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. VmVgpuPolicyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. VmVgpuPolicyArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. VmVgpuPolicyArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. VmVgpuPolicyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. VmVgpuPolicyArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var vmVgpuPolicyResource = new Vcd.VmVgpuPolicy("vmVgpuPolicyResource", new()
{
    VgpuProfile = new Vcd.Inputs.VmVgpuPolicyVgpuProfileArgs
    {
        Count = 0,
        Id = "string",
    },
    Cpu = new Vcd.Inputs.VmVgpuPolicyCpuArgs
    {
        CoresPerSocket = "string",
        Count = "string",
        LimitInMhz = "string",
        ReservationGuarantee = "string",
        Shares = "string",
        SpeedInMhz = "string",
    },
    Description = "string",
    Memory = new Vcd.Inputs.VmVgpuPolicyMemoryArgs
    {
        LimitInMb = "string",
        ReservationGuarantee = "string",
        Shares = "string",
        SizeInMb = "string",
    },
    Name = "string",
    ProviderVdcScopes = new[]
    {
        new Vcd.Inputs.VmVgpuPolicyProviderVdcScopeArgs
        {
            ProviderVdcId = "string",
            ClusterNames = new[]
            {
                "string",
            },
            VmGroupId = "string",
        },
    },
    VmVgpuPolicyId = "string",
});
Copy
example, err := vcd.NewVmVgpuPolicy(ctx, "vmVgpuPolicyResource", &vcd.VmVgpuPolicyArgs{
VgpuProfile: &.VmVgpuPolicyVgpuProfileArgs{
Count: pulumi.Float64(0),
Id: pulumi.String("string"),
},
Cpu: &.VmVgpuPolicyCpuArgs{
CoresPerSocket: pulumi.String("string"),
Count: pulumi.String("string"),
LimitInMhz: pulumi.String("string"),
ReservationGuarantee: pulumi.String("string"),
Shares: pulumi.String("string"),
SpeedInMhz: pulumi.String("string"),
},
Description: pulumi.String("string"),
Memory: &.VmVgpuPolicyMemoryArgs{
LimitInMb: pulumi.String("string"),
ReservationGuarantee: pulumi.String("string"),
Shares: pulumi.String("string"),
SizeInMb: pulumi.String("string"),
},
Name: pulumi.String("string"),
ProviderVdcScopes: .VmVgpuPolicyProviderVdcScopeArray{
&.VmVgpuPolicyProviderVdcScopeArgs{
ProviderVdcId: pulumi.String("string"),
ClusterNames: pulumi.StringArray{
pulumi.String("string"),
},
VmGroupId: pulumi.String("string"),
},
},
VmVgpuPolicyId: pulumi.String("string"),
})
Copy
var vmVgpuPolicyResource = new VmVgpuPolicy("vmVgpuPolicyResource", VmVgpuPolicyArgs.builder()
    .vgpuProfile(VmVgpuPolicyVgpuProfileArgs.builder()
        .count(0)
        .id("string")
        .build())
    .cpu(VmVgpuPolicyCpuArgs.builder()
        .coresPerSocket("string")
        .count("string")
        .limitInMhz("string")
        .reservationGuarantee("string")
        .shares("string")
        .speedInMhz("string")
        .build())
    .description("string")
    .memory(VmVgpuPolicyMemoryArgs.builder()
        .limitInMb("string")
        .reservationGuarantee("string")
        .shares("string")
        .sizeInMb("string")
        .build())
    .name("string")
    .providerVdcScopes(VmVgpuPolicyProviderVdcScopeArgs.builder()
        .providerVdcId("string")
        .clusterNames("string")
        .vmGroupId("string")
        .build())
    .vmVgpuPolicyId("string")
    .build());
Copy
vm_vgpu_policy_resource = vcd.VmVgpuPolicy("vmVgpuPolicyResource",
    vgpu_profile={
        "count": 0,
        "id": "string",
    },
    cpu={
        "cores_per_socket": "string",
        "count": "string",
        "limit_in_mhz": "string",
        "reservation_guarantee": "string",
        "shares": "string",
        "speed_in_mhz": "string",
    },
    description="string",
    memory={
        "limit_in_mb": "string",
        "reservation_guarantee": "string",
        "shares": "string",
        "size_in_mb": "string",
    },
    name="string",
    provider_vdc_scopes=[{
        "provider_vdc_id": "string",
        "cluster_names": ["string"],
        "vm_group_id": "string",
    }],
    vm_vgpu_policy_id="string")
Copy
const vmVgpuPolicyResource = new vcd.VmVgpuPolicy("vmVgpuPolicyResource", {
    vgpuProfile: {
        count: 0,
        id: "string",
    },
    cpu: {
        coresPerSocket: "string",
        count: "string",
        limitInMhz: "string",
        reservationGuarantee: "string",
        shares: "string",
        speedInMhz: "string",
    },
    description: "string",
    memory: {
        limitInMb: "string",
        reservationGuarantee: "string",
        shares: "string",
        sizeInMb: "string",
    },
    name: "string",
    providerVdcScopes: [{
        providerVdcId: "string",
        clusterNames: ["string"],
        vmGroupId: "string",
    }],
    vmVgpuPolicyId: "string",
});
Copy
type: vcd:VmVgpuPolicy
properties:
    cpu:
        coresPerSocket: string
        count: string
        limitInMhz: string
        reservationGuarantee: string
        shares: string
        speedInMhz: string
    description: string
    memory:
        limitInMb: string
        reservationGuarantee: string
        shares: string
        sizeInMb: string
    name: string
    providerVdcScopes:
        - clusterNames:
            - string
          providerVdcId: string
          vmGroupId: string
    vgpuProfile:
        count: 0
        id: string
    vmVgpuPolicyId: string
Copy

VmVgpuPolicy Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The VmVgpuPolicy resource accepts the following input properties:

VgpuProfile This property is required. VmVgpuPolicyVgpuProfile
Defines the vGPU profile ID and count.
Cpu VmVgpuPolicyCpu
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
Description string
A brief description of the vGPU policy.
Memory VmVgpuPolicyMemory
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
Name string
The unique name assigned to the vGPU policy for a virtual machine.
ProviderVdcScopes List<VmVgpuPolicyProviderVdcScope>
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
VmVgpuPolicyId string
VgpuProfile This property is required. VmVgpuPolicyVgpuProfileArgs
Defines the vGPU profile ID and count.
Cpu VmVgpuPolicyCpuArgs
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
Description string
A brief description of the vGPU policy.
Memory VmVgpuPolicyMemoryArgs
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
Name string
The unique name assigned to the vGPU policy for a virtual machine.
ProviderVdcScopes []VmVgpuPolicyProviderVdcScopeArgs
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
VmVgpuPolicyId string
vgpuProfile This property is required. VmVgpuPolicyVgpuProfile
Defines the vGPU profile ID and count.
cpu VmVgpuPolicyCpu
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description String
A brief description of the vGPU policy.
memory VmVgpuPolicyMemory
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name String
The unique name assigned to the vGPU policy for a virtual machine.
providerVdcScopes List<VmVgpuPolicyProviderVdcScope>
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vmVgpuPolicyId String
vgpuProfile This property is required. VmVgpuPolicyVgpuProfile
Defines the vGPU profile ID and count.
cpu VmVgpuPolicyCpu
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description string
A brief description of the vGPU policy.
memory VmVgpuPolicyMemory
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name string
The unique name assigned to the vGPU policy for a virtual machine.
providerVdcScopes VmVgpuPolicyProviderVdcScope[]
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vmVgpuPolicyId string
vgpu_profile This property is required. VmVgpuPolicyVgpuProfileArgs
Defines the vGPU profile ID and count.
cpu VmVgpuPolicyCpuArgs
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description str
A brief description of the vGPU policy.
memory VmVgpuPolicyMemoryArgs
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name str
The unique name assigned to the vGPU policy for a virtual machine.
provider_vdc_scopes Sequence[VmVgpuPolicyProviderVdcScopeArgs]
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vm_vgpu_policy_id str
vgpuProfile This property is required. Property Map
Defines the vGPU profile ID and count.
cpu Property Map
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description String
A brief description of the vGPU policy.
memory Property Map
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name String
The unique name assigned to the vGPU policy for a virtual machine.
providerVdcScopes List<Property Map>
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vmVgpuPolicyId String

Outputs

All input properties are implicitly available as output properties. Additionally, the VmVgpuPolicy resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing VmVgpuPolicy Resource

Get an existing VmVgpuPolicy resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: VmVgpuPolicyState, opts?: CustomResourceOptions): VmVgpuPolicy
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        cpu: Optional[VmVgpuPolicyCpuArgs] = None,
        description: Optional[str] = None,
        memory: Optional[VmVgpuPolicyMemoryArgs] = None,
        name: Optional[str] = None,
        provider_vdc_scopes: Optional[Sequence[VmVgpuPolicyProviderVdcScopeArgs]] = None,
        vgpu_profile: Optional[VmVgpuPolicyVgpuProfileArgs] = None,
        vm_vgpu_policy_id: Optional[str] = None) -> VmVgpuPolicy
func GetVmVgpuPolicy(ctx *Context, name string, id IDInput, state *VmVgpuPolicyState, opts ...ResourceOption) (*VmVgpuPolicy, error)
public static VmVgpuPolicy Get(string name, Input<string> id, VmVgpuPolicyState? state, CustomResourceOptions? opts = null)
public static VmVgpuPolicy get(String name, Output<String> id, VmVgpuPolicyState state, CustomResourceOptions options)
resources:  _:    type: vcd:VmVgpuPolicy    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Cpu VmVgpuPolicyCpu
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
Description string
A brief description of the vGPU policy.
Memory VmVgpuPolicyMemory
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
Name string
The unique name assigned to the vGPU policy for a virtual machine.
ProviderVdcScopes List<VmVgpuPolicyProviderVdcScope>
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
VgpuProfile VmVgpuPolicyVgpuProfile
Defines the vGPU profile ID and count.
VmVgpuPolicyId string
Cpu VmVgpuPolicyCpuArgs
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
Description string
A brief description of the vGPU policy.
Memory VmVgpuPolicyMemoryArgs
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
Name string
The unique name assigned to the vGPU policy for a virtual machine.
ProviderVdcScopes []VmVgpuPolicyProviderVdcScopeArgs
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
VgpuProfile VmVgpuPolicyVgpuProfileArgs
Defines the vGPU profile ID and count.
VmVgpuPolicyId string
cpu VmVgpuPolicyCpu
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description String
A brief description of the vGPU policy.
memory VmVgpuPolicyMemory
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name String
The unique name assigned to the vGPU policy for a virtual machine.
providerVdcScopes List<VmVgpuPolicyProviderVdcScope>
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vgpuProfile VmVgpuPolicyVgpuProfile
Defines the vGPU profile ID and count.
vmVgpuPolicyId String
cpu VmVgpuPolicyCpu
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description string
A brief description of the vGPU policy.
memory VmVgpuPolicyMemory
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name string
The unique name assigned to the vGPU policy for a virtual machine.
providerVdcScopes VmVgpuPolicyProviderVdcScope[]
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vgpuProfile VmVgpuPolicyVgpuProfile
Defines the vGPU profile ID and count.
vmVgpuPolicyId string
cpu VmVgpuPolicyCpuArgs
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description str
A brief description of the vGPU policy.
memory VmVgpuPolicyMemoryArgs
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name str
The unique name assigned to the vGPU policy for a virtual machine.
provider_vdc_scopes Sequence[VmVgpuPolicyProviderVdcScopeArgs]
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vgpu_profile VmVgpuPolicyVgpuProfileArgs
Defines the vGPU profile ID and count.
vm_vgpu_policy_id str
cpu Property Map
Configuration options for CPU resources. If this is set, a VM created with this policy can't specify a custom sizing policy. See [cpu] for more details.
description String
A brief description of the vGPU policy.
memory Property Map
Memory resource configuration settings. If this is set, a VM created with this policy can't specify a custom sizing policy. See [memory] for more details.
name String
The unique name assigned to the vGPU policy for a virtual machine.
providerVdcScopes List<Property Map>
Defines the scope of the policy within provider virtual data centers. If not provided, applies to all the current ant future PVDCs. See provider_vdc_scope for more details.
vgpuProfile Property Map
Defines the vGPU profile ID and count.
vmVgpuPolicyId String

Supporting Types

VmVgpuPolicyCpu
, VmVgpuPolicyCpuArgs

CoresPerSocket string
The number of cores per socket for a VM. This is a VM hardware configuration. The number of vCPUs that is defined in the VM sizing policy must be divisible by the number of cores per socket. If the number of vCPUs is not divisible by the number of cores per socket, the number of cores per socket becomes invalid.
Count string
Defines the number of vCPUs configured for a VM. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, this count becomes the configured number of vCPUs for the VM.
LimitInMhz string
Defines the CPU limit in MHz for a VM. If not defined in the VDC compute policy, CPU limit is equal to the vCPU speed multiplied by the number of vCPUs. -1 means unlimited
ReservationGuarantee string
Defines how much of the CPU resources of a VM are reserved. The allocated CPU for a VM equals the number of vCPUs times the vCPU speed in MHz. The value of the attribute ranges between 0 and one. Value of 0 CPU reservation guarantee defines no CPU reservation. Value of 1 defines 100% of CPU reserved.
Shares string
Defines the number of CPU shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of CPU as another VM, it is entitled to consume twice as much CPU when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
SpeedInMhz string
Defines the vCPU speed of a core in MHz.
CoresPerSocket string
The number of cores per socket for a VM. This is a VM hardware configuration. The number of vCPUs that is defined in the VM sizing policy must be divisible by the number of cores per socket. If the number of vCPUs is not divisible by the number of cores per socket, the number of cores per socket becomes invalid.
Count string
Defines the number of vCPUs configured for a VM. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, this count becomes the configured number of vCPUs for the VM.
LimitInMhz string
Defines the CPU limit in MHz for a VM. If not defined in the VDC compute policy, CPU limit is equal to the vCPU speed multiplied by the number of vCPUs. -1 means unlimited
ReservationGuarantee string
Defines how much of the CPU resources of a VM are reserved. The allocated CPU for a VM equals the number of vCPUs times the vCPU speed in MHz. The value of the attribute ranges between 0 and one. Value of 0 CPU reservation guarantee defines no CPU reservation. Value of 1 defines 100% of CPU reserved.
Shares string
Defines the number of CPU shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of CPU as another VM, it is entitled to consume twice as much CPU when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
SpeedInMhz string
Defines the vCPU speed of a core in MHz.
coresPerSocket String
The number of cores per socket for a VM. This is a VM hardware configuration. The number of vCPUs that is defined in the VM sizing policy must be divisible by the number of cores per socket. If the number of vCPUs is not divisible by the number of cores per socket, the number of cores per socket becomes invalid.
count String
Defines the number of vCPUs configured for a VM. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, this count becomes the configured number of vCPUs for the VM.
limitInMhz String
Defines the CPU limit in MHz for a VM. If not defined in the VDC compute policy, CPU limit is equal to the vCPU speed multiplied by the number of vCPUs. -1 means unlimited
reservationGuarantee String
Defines how much of the CPU resources of a VM are reserved. The allocated CPU for a VM equals the number of vCPUs times the vCPU speed in MHz. The value of the attribute ranges between 0 and one. Value of 0 CPU reservation guarantee defines no CPU reservation. Value of 1 defines 100% of CPU reserved.
shares String
Defines the number of CPU shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of CPU as another VM, it is entitled to consume twice as much CPU when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
speedInMhz String
Defines the vCPU speed of a core in MHz.
coresPerSocket string
The number of cores per socket for a VM. This is a VM hardware configuration. The number of vCPUs that is defined in the VM sizing policy must be divisible by the number of cores per socket. If the number of vCPUs is not divisible by the number of cores per socket, the number of cores per socket becomes invalid.
count string
Defines the number of vCPUs configured for a VM. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, this count becomes the configured number of vCPUs for the VM.
limitInMhz string
Defines the CPU limit in MHz for a VM. If not defined in the VDC compute policy, CPU limit is equal to the vCPU speed multiplied by the number of vCPUs. -1 means unlimited
reservationGuarantee string
Defines how much of the CPU resources of a VM are reserved. The allocated CPU for a VM equals the number of vCPUs times the vCPU speed in MHz. The value of the attribute ranges between 0 and one. Value of 0 CPU reservation guarantee defines no CPU reservation. Value of 1 defines 100% of CPU reserved.
shares string
Defines the number of CPU shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of CPU as another VM, it is entitled to consume twice as much CPU when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
speedInMhz string
Defines the vCPU speed of a core in MHz.
cores_per_socket str
The number of cores per socket for a VM. This is a VM hardware configuration. The number of vCPUs that is defined in the VM sizing policy must be divisible by the number of cores per socket. If the number of vCPUs is not divisible by the number of cores per socket, the number of cores per socket becomes invalid.
count str
Defines the number of vCPUs configured for a VM. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, this count becomes the configured number of vCPUs for the VM.
limit_in_mhz str
Defines the CPU limit in MHz for a VM. If not defined in the VDC compute policy, CPU limit is equal to the vCPU speed multiplied by the number of vCPUs. -1 means unlimited
reservation_guarantee str
Defines how much of the CPU resources of a VM are reserved. The allocated CPU for a VM equals the number of vCPUs times the vCPU speed in MHz. The value of the attribute ranges between 0 and one. Value of 0 CPU reservation guarantee defines no CPU reservation. Value of 1 defines 100% of CPU reserved.
shares str
Defines the number of CPU shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of CPU as another VM, it is entitled to consume twice as much CPU when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
speed_in_mhz str
Defines the vCPU speed of a core in MHz.
coresPerSocket String
The number of cores per socket for a VM. This is a VM hardware configuration. The number of vCPUs that is defined in the VM sizing policy must be divisible by the number of cores per socket. If the number of vCPUs is not divisible by the number of cores per socket, the number of cores per socket becomes invalid.
count String
Defines the number of vCPUs configured for a VM. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, this count becomes the configured number of vCPUs for the VM.
limitInMhz String
Defines the CPU limit in MHz for a VM. If not defined in the VDC compute policy, CPU limit is equal to the vCPU speed multiplied by the number of vCPUs. -1 means unlimited
reservationGuarantee String
Defines how much of the CPU resources of a VM are reserved. The allocated CPU for a VM equals the number of vCPUs times the vCPU speed in MHz. The value of the attribute ranges between 0 and one. Value of 0 CPU reservation guarantee defines no CPU reservation. Value of 1 defines 100% of CPU reserved.
shares String
Defines the number of CPU shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of CPU as another VM, it is entitled to consume twice as much CPU when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
speedInMhz String
Defines the vCPU speed of a core in MHz.

VmVgpuPolicyMemory
, VmVgpuPolicyMemoryArgs

LimitInMb string
Defines the memory limit in MB for a VM. If not defined in the VM sizing policy, memory limit is equal to the allocated memory for the VM.
ReservationGuarantee string
Defines the reserved amount of memory that is configured for a VM. The value of the attribute ranges between 0 and one. Value of 0 memory reservation guarantee defines no memory reservation. Value of 1 defines 100% of memory reserved.
Shares string
Defines the number of memory shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of memory as another VM, it is entitled to consume twice as much memory when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
SizeInMb string
Defines the memory configured for a VM in MB. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, the VM receives the amount of memory defined by this attribute.
LimitInMb string
Defines the memory limit in MB for a VM. If not defined in the VM sizing policy, memory limit is equal to the allocated memory for the VM.
ReservationGuarantee string
Defines the reserved amount of memory that is configured for a VM. The value of the attribute ranges between 0 and one. Value of 0 memory reservation guarantee defines no memory reservation. Value of 1 defines 100% of memory reserved.
Shares string
Defines the number of memory shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of memory as another VM, it is entitled to consume twice as much memory when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
SizeInMb string
Defines the memory configured for a VM in MB. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, the VM receives the amount of memory defined by this attribute.
limitInMb String
Defines the memory limit in MB for a VM. If not defined in the VM sizing policy, memory limit is equal to the allocated memory for the VM.
reservationGuarantee String
Defines the reserved amount of memory that is configured for a VM. The value of the attribute ranges between 0 and one. Value of 0 memory reservation guarantee defines no memory reservation. Value of 1 defines 100% of memory reserved.
shares String
Defines the number of memory shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of memory as another VM, it is entitled to consume twice as much memory when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
sizeInMb String
Defines the memory configured for a VM in MB. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, the VM receives the amount of memory defined by this attribute.
limitInMb string
Defines the memory limit in MB for a VM. If not defined in the VM sizing policy, memory limit is equal to the allocated memory for the VM.
reservationGuarantee string
Defines the reserved amount of memory that is configured for a VM. The value of the attribute ranges between 0 and one. Value of 0 memory reservation guarantee defines no memory reservation. Value of 1 defines 100% of memory reserved.
shares string
Defines the number of memory shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of memory as another VM, it is entitled to consume twice as much memory when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
sizeInMb string
Defines the memory configured for a VM in MB. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, the VM receives the amount of memory defined by this attribute.
limit_in_mb str
Defines the memory limit in MB for a VM. If not defined in the VM sizing policy, memory limit is equal to the allocated memory for the VM.
reservation_guarantee str
Defines the reserved amount of memory that is configured for a VM. The value of the attribute ranges between 0 and one. Value of 0 memory reservation guarantee defines no memory reservation. Value of 1 defines 100% of memory reserved.
shares str
Defines the number of memory shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of memory as another VM, it is entitled to consume twice as much memory when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
size_in_mb str
Defines the memory configured for a VM in MB. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, the VM receives the amount of memory defined by this attribute.
limitInMb String
Defines the memory limit in MB for a VM. If not defined in the VM sizing policy, memory limit is equal to the allocated memory for the VM.
reservationGuarantee String
Defines the reserved amount of memory that is configured for a VM. The value of the attribute ranges between 0 and one. Value of 0 memory reservation guarantee defines no memory reservation. Value of 1 defines 100% of memory reserved.
shares String
Defines the number of memory shares for a VM. Shares specify the relative importance of a VM within a virtual data center. If a VM has twice as many shares of memory as another VM, it is entitled to consume twice as much memory when these two virtual machines are competing for resources. If not defined in the VDC compute policy, normal shares are applied to the VM.
sizeInMb String
Defines the memory configured for a VM in MB. This is a VM hardware configuration. When a tenant assigns the VM sizing policy to a VM, the VM receives the amount of memory defined by this attribute.

VmVgpuPolicyProviderVdcScope
, VmVgpuPolicyProviderVdcScopeArgs

ProviderVdcId This property is required. string
The ID of the provider VDC that should be in the scope.
ClusterNames List<string>
A set of vCenter cluster names on which the provider VDC is hosted. If none are provided, the provider attempts to find one automatically. Can be fetched using data.vcd_resource_pool.cluster_moref attribute.
VmGroupId string
Optional identifier for a VM group within the provider VDC scope.
ProviderVdcId This property is required. string
The ID of the provider VDC that should be in the scope.
ClusterNames []string
A set of vCenter cluster names on which the provider VDC is hosted. If none are provided, the provider attempts to find one automatically. Can be fetched using data.vcd_resource_pool.cluster_moref attribute.
VmGroupId string
Optional identifier for a VM group within the provider VDC scope.
providerVdcId This property is required. String
The ID of the provider VDC that should be in the scope.
clusterNames List<String>
A set of vCenter cluster names on which the provider VDC is hosted. If none are provided, the provider attempts to find one automatically. Can be fetched using data.vcd_resource_pool.cluster_moref attribute.
vmGroupId String
Optional identifier for a VM group within the provider VDC scope.
providerVdcId This property is required. string
The ID of the provider VDC that should be in the scope.
clusterNames string[]
A set of vCenter cluster names on which the provider VDC is hosted. If none are provided, the provider attempts to find one automatically. Can be fetched using data.vcd_resource_pool.cluster_moref attribute.
vmGroupId string
Optional identifier for a VM group within the provider VDC scope.
provider_vdc_id This property is required. str
The ID of the provider VDC that should be in the scope.
cluster_names Sequence[str]
A set of vCenter cluster names on which the provider VDC is hosted. If none are provided, the provider attempts to find one automatically. Can be fetched using data.vcd_resource_pool.cluster_moref attribute.
vm_group_id str
Optional identifier for a VM group within the provider VDC scope.
providerVdcId This property is required. String
The ID of the provider VDC that should be in the scope.
clusterNames List<String>
A set of vCenter cluster names on which the provider VDC is hosted. If none are provided, the provider attempts to find one automatically. Can be fetched using data.vcd_resource_pool.cluster_moref attribute.
vmGroupId String
Optional identifier for a VM group within the provider VDC scope.

VmVgpuPolicyVgpuProfile
, VmVgpuPolicyVgpuProfileArgs

Count This property is required. double
Specifies the number of vGPU profiles. Must be at least 1.
Id This property is required. string
The identifier of the vGPU profile.
Count This property is required. float64
Specifies the number of vGPU profiles. Must be at least 1.
Id This property is required. string
The identifier of the vGPU profile.
count This property is required. Double
Specifies the number of vGPU profiles. Must be at least 1.
id This property is required. String
The identifier of the vGPU profile.
count This property is required. number
Specifies the number of vGPU profiles. Must be at least 1.
id This property is required. string
The identifier of the vGPU profile.
count This property is required. float
Specifies the number of vGPU profiles. Must be at least 1.
id This property is required. str
The identifier of the vGPU profile.
count This property is required. Number
Specifies the number of vGPU profiles. Must be at least 1.
id This property is required. String
The identifier of the vGPU profile.

Package Details

Repository
vcd vmware/terraform-provider-vcd
License
Notes
This Pulumi package is based on the vcd Terraform Provider.