vcenter vm template library items: deploy spec

The deploy_spec structure defines the deployment parameters that can be specified for the deploy operation. This structure was added in vSphere API 6.8.

Representation:

{
    "disk_storage"{
        "datastore""obj-103",
        "storage_policy"{
            "type""USE_SPECIFIED_POLICY",
            "policy""obj-103"
        }
    },
    "hardware_customization"{
        "cpu_update"{
            "num_cpus"1,
            "num_cores_per_socket"1
        },
        "memory_update"{
            "memory"1
        },
        "nics"{
            "obj-103"{
                "network""obj-103"
            }
        },
        "disks_to_remove"[
            "obj-103",
            "obj-103"
        ],
        "disks_to_update"{
            "obj-103"{
                "capacity"1
            }
        }
    },
    "name""string",
    "description""string",
    "vm_home_storage"{
        "datastore""obj-103",
        "storage_policy"{
            "type""USE_SPECIFIED_POLICY",
            "policy""obj-103"
        }
    },
    "guest_customization"{
        "name""string"
    },
    "disk_storage_overrides"{
        "obj-103"{
            "datastore""obj-103",
            "storage_policy"{
                "type""USE_SPECIFIED_POLICY",
                "policy""obj-103"
            }
        }
    },
    "placement"{
        "cluster""obj-103",
        "folder""obj-103",
        "host""obj-103",
        "resource_pool""obj-103"
    },
    "powered_on"true
}
{
    "disk_storage"{
        "datastore""obj-103",
        "storage_policy"{
            "type""USE_SPECIFIED_POLICY",
            "policy""obj-103"
        }
    },
    "hardware_customization"{
        "cpu_update"{
            "num_cpus"1,
            "num_cores_per_socket"1
        },
        "memory_update"{
            "memory"1
        },
        "nics"[
            {
                "value"{
                    "network""obj-103"
                },
                "key""obj-103"
            }
        ],
        "disks_to_remove"[
            "obj-103",
            "obj-103"
        ],
        "disks_to_update"[
            {
                "value"{
                    "capacity"1
                },
                "key""obj-103"
            }
        ]
    },
    "name""string",
    "description""string",
    "vm_home_storage"{
        "datastore""obj-103",
        "storage_policy"{
            "type""USE_SPECIFIED_POLICY",
            "policy""obj-103"
        }
    },
    "guest_customization"{
        "name""string"
    },
    "disk_storage_overrides"[
        {
            "value"{
                "datastore""obj-103",
                "storage_policy"{
                    "type""USE_SPECIFIED_POLICY",
                    "policy""obj-103"
                }
            },
            "key""obj-103"
        }
    ],
    "placement"{
        "cluster""obj-103",
        "folder""obj-103",
        "host""obj-103",
        "resource_pool""obj-103"
    },
    "powered_on"true
}

Attributes:

Name Type Description
Required
-.name string Name of the deployed virtual machine. This attribute was added in vSphere API 6.8.

-.vm_home_storage.storage_policy.type string Policy type to be used when creating the deployed virtual machine's configuration and log files. This attribute was added in vSphere API 6.8.

Policy type for the deployed virtual machine's configuration and log files. This enumeration was added in vSphere API 6.8. Value is one of:
USE_SPECIFIED_POLICY: Use the specified policy. This constant was added in vSphere API 6.8.
USE_SOURCE_POLICY: Use the storage policy that is associated with the source virtual machine template's configuration and log files. This constant was added in vSphere API 6.8.

-.disk_storage.storage_policy.type string Policy type to be used when creating the deployed virtual machine's disk. This attribute was added in vSphere API 6.8.

Policy type for the deployed virtual machine's disk. This enumeration was added in vSphere API 6.8. Value is one of:
USE_SPECIFIED_POLICY: Use the specified policy. This constant was added in vSphere API 6.8.
USE_SOURCE_POLICY: Use the storage policy that is associated with the corresponding disk in the source virtual machine template. This constant was added in vSphere API 6.8.

Optional
-.description string Description of the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If unset, the deployed virtual machine has the same description as the source library item.

-.vm_home_storage deploy_spec_vm_home_storage Storage location for the deployed virtual machine's configuration and log files. This attribute was added in vSphere API 6.8.

Optional. If unset, the deployed virtual machine's configuration and log files are created with the same storage spec as the source virtual machine template's configuration and log files.

-.vm_home_storage.datastore string Identifier of the datastore for the deployed virtual machine's configuration and log files. This attribute was added in vSphere API 6.8.

Optional. This field is currently required.

When storage_policy is also specified and is incompatible with the datastore, then the deployed virtual machine will be flagged as being out of compliance with the specified storage policy.

. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: Datastore. When operations return a value of this structure as a result, the field will be an identifier for the resource type: Datastore.
-.vm_home_storage.storage_policy deploy_spec_vm_home_storage_policy Storage policy for the deployed virtual machine's configuration and log files. This attribute was added in vSphere API 6.8.

Optional. If unset, datastore must be specified and the deployed virtual machine's configuration and log files are created with the default storage policy associated with the datastore.

-.vm_home_storage.storage_policy.policy string Identifier for the storage policy to use. This attribute was added in vSphere API 6.8.

Optional. It is only relevant when type has value USE_SPECIFIED_POLICY. This field is optional and it is only relevant when the value of type is USE_SPECIFIED_POLICY.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.spbm.StorageProfile. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.spbm.StorageProfile.

-.disk_storage deploy_spec_disk_storage Storage specification for the deployed virtual machine's disks. This attribute was added in vSphere API 6.8.

Optional. If both disk_storage_overrides and disk_storage are unset, the deployed virtual machine's disks are created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.

If disk_storage_overrides is unset and disk_storage is specified, all of the deployed virtual machine's disks are created with the storage spec specified by disk_storage.

If disk_storage_overrides is specified and disk_storage is unset, disks with identifiers that are not in disk_storage_overrides are created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.

If both disk_storage_overrides and disk_storage are specified, disks with identifiers that are not in disk_storage_overrides are created with the storage spec specified by disk_storage.

.
-.disk_storage.datastore string Identifier for the datastore associated the deployed virtual machine's disk. This attribute was added in vSphere API 6.8.

Optional. This field is currently required.

If storage_policy is also specified and is incompatible with the datastore, then the disk will be flagged as being out of compliance with the specified storage policy.

. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: Datastore. When operations return a value of this structure as a result, the field will be an identifier for the resource type: Datastore.
-.disk_storage.storage_policy deploy_spec_disk_storage_policy Storage policy for the deployed virtual machine's disk. This attribute was added in vSphere API 6.8.

Optional. If unset, datastore must be specified and the deployed virtual machine's disk is created with the default storage policy associated with the datastore.

-.disk_storage.storage_policy.policy string Identifier of the storage policy to use. This attribute was added in vSphere API 6.8.

Optional. It is only relevant when type has value USE_SPECIFIED_POLICY. This field is optional and it is only relevant when the value of type is USE_SPECIFIED_POLICY.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.spbm.StorageProfile. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.spbm.StorageProfile.

-.disk_storage_overrides object Storage specification for individual disks in the deployed virtual machine. This is specified as a mapping between disk identifiers in the source virtual machine template contained in the library item and their storage specifications. This attribute was added in vSphere API 6.8.

Optional. If both disk_storage_overrides and disk_storage are unset, the deployed virtual machine's disks are created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.

If disk_storage_overrides is unset and disk_storage is specified, all of the deployed virtual machine's disks are created with the storage spec specified by disk_storage.

If disk_storage_overrides is specified and disk_storage is unset, disks with identifiers that are not in disk_storage_overrides are created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.

If both disk_storage_overrides and disk_storage are specified, disks with identifiers that are not in disk_storage_overrides are created with the storage spec specified by disk_storage.

. When clients pass a value of this structure as a parameter, the key in the field key/value pairs must be an identifier for the resource type: com.vmware.vcenter.vm.hardware.Disk. When operations return a value of this structure as a result, the key in the field key/value pairs will be an identifier for the resource type: com.vmware.vcenter.vm.hardware.Disk.
-.placement deploy_placement_spec Information used to place the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. This field is currently required. In the future, if this field is unset, the system will use the values from the source virtual machine template contained in the library item.

If specified, each field will be used for placement. If the fields result in disjoint placement, the operation will fail. If the fields along with the placement values of the source virtual machine template result in disjoint placement, the operation will fail.

.
-.placement.folder string Virtual machine folder into which the deployed virtual machine should be placed. This attribute was added in vSphere API 6.8.

Optional. This field is currently required.

If unset, the system will attempt to choose a suitable folder for the virtual machine; if a folder cannot be chosen, the virtual machine deployment operation will fail.

. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: Folder. When operations return a value of this structure as a result, the field will be an identifier for the resource type: Folder.
-.placement.resource_pool string Resource pool into which the deployed virtual machine should be placed. This attribute was added in vSphere API 6.8.

Optional. If unset, the system will attempt to choose a suitable resource pool for the virtual machine; if a resource pool cannot be chosen, the virtual machine deployment operation will fail.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: ResourcePool. When operations return a value of this structure as a result, the field will be an identifier for the resource type: ResourcePool.

-.placement.host string Host onto which the virtual machine should be placed. If host and resource_pool are both specified, resource_pool must belong to host. If host and cluster are both specified, host must be a member of cluster. This attribute was added in vSphere API 6.8.

Optional. This field may be unset if resource_pool or cluster is specified. If unset, the system will attempt to choose a suitable host for the virtual machine; if a host cannot be chosen, the virtual machine deployment operation will fail.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: HostSystem. When operations return a value of this structure as a result, the field will be an identifier for the resource type: HostSystem.

-.placement.cluster string Cluster onto which the deployed virtual machine should be placed. If cluster and resource_pool are both specified, resource_pool must belong to cluster. If cluster and host are both specified, host must be a member of cluster. This attribute was added in vSphere API 6.8.

Optional. If resource_pool or host is specified, it is recommended that this field be unset.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: ClusterComputeResource. When operations return a value of this structure as a result, the field will be an identifier for the resource type: ClusterComputeResource.

-.powered_on boolean Specifies whether the deployed virtual machine should be powered on after deployment. This attribute was added in vSphere API 6.8.

Optional. If unset, the virtual machine will not be powered on after deployment.

-.guest_customization guest_customization_spec Guest customization spec to apply to the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If unset, the guest operating system is not customized after deployment.

-.guest_customization.name string Name of the customization specification. This attribute was added in vSphere API 6.8.

Optional. If unset, no guest customization is performed.

-.hardware_customization hardware_customization_spec Hardware customization spec which specifies updates to the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If unset, the deployed virtual machine has the same hardware configuration as the source virtual machine template contained in the library item.

-.hardware_customization.nics object Map of Ethernet network adapters to update. This attribute was added in vSphere API 6.8.

Optional. If unset, all Ethernet adapters will remain connected to the same network as they were in the source virtual machine template. An Ethernet adapter with a MacAddressType of MANUAL will not change. An Ethernet adapter with a MacAddressType of GENERATED or ASSIGNED will receive a new address.When clients pass a value of this structure as a parameter, the key in the field key/value pairs must be an identifier for the resource type: com.vmware.vcenter.vm.hardware.Ethernet. When operations return a value of this structure as a result, the key in the field key/value pairs will be an identifier for the resource type: com.vmware.vcenter.vm.hardware.Ethernet.

-.hardware_customization.disks_to_remove string[] Idenfiers of disks to remove from the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If unset, all disks will be copied.When clients pass a value of this structure as a parameter, the field must contain identifiers for the resource type: com.vmware.vcenter.vm.hardware.Disk. When operations return a value of this structure as a result, the field will contain identifiers for the resource type: com.vmware.vcenter.vm.hardware.Disk.

-.hardware_customization.disks_to_update object Disk update specification for individual disks in the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If unset, disks in the deployed virtual machine will have the same settings as the corresponding disks in the source virtual machine template contained in the library item.When clients pass a value of this structure as a parameter, the key in the field key/value pairs must be an identifier for the resource type: com.vmware.vcenter.vm.hardware.Disk. When operations return a value of this structure as a result, the key in the field key/value pairs will be an identifier for the resource type: com.vmware.vcenter.vm.hardware.Disk.

-.hardware_customization.cpu_update cpu_update_spec CPU update specification for the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If {@term.unset}, the deployed virtual machine has the same CPU settings as the source virtual machine template contained in the library item.

-.hardware_customization.cpu_update.num_cpus long Number of virtual processors in the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If {@term.unset}, the deployed virtual machine has the same CPU count as the source virtual machine template contained in the library item.

-.hardware_customization.cpu_update.num_cores_per_socket long Number of cores among which to distribute CPUs in the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If {@term.unset}, the deployed virtual machine has the same number of cores per socket as the source virtual machine template contained in the library item.

-.hardware_customization.memory_update memory_update_spec Memory update specification for the deployed virtual machine. This attribute was added in vSphere API 6.8.

Optional. If {@term.unset}, the deployed virtual machine has the same memory settings as the source virtual machine template contained in the library item.

-.hardware_customization.memory_update.memory long Size of a virtual machine's memory in MB. This attribute was added in vSphere API 6.8.

Optional. If {@term.unset}, the deployed virtual machine has the same memory size as the source virtual machine template.