Developer Documentation

VMRegisterSpec

The VM.RegisterSpec structure contains information used to create a virtual machine from existing virtual machine files on storage. The location of the virtual machine files on storage must be specified by providing either VM.RegisterSpec.datastore and VM.RegisterSpec.path or by providing VM.RegisterSpec.datastore-path. If VM.RegisterSpec.datastore and VM.RegisterSpec.path are set, VM.RegisterSpec.datastore-path must be unset, and if VM.RegisterSpec.datastore-path is set, VM.RegisterSpec.datastore and VM.RegisterSpec.path must be unset.


Properties

Required Property Name Type Description
optional datastore string

Identifier of the datastore on which the virtual machine’s configuration state is stored. If unset, VM.RegisterSpec.path must also be unset and VM.RegisterSpec.datastore-path must be set. 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.

optional datastore_path string

Datastore path for the virtual machine’s configuration file in the format “[datastore name] path”. For example “[storage1] Test-VM/Test-VM.vmx”. If unset, both VM.RegisterSpec.datastore and VM.RegisterSpec.path must be set.

optional name string

Virtual machine name. If unset, the display name from the virtual machine’s configuration file will be used.

optional path string

Path to the virtual machine’s configuration file on the datastore corresponding to {@link #datastore). If unset, VM.RegisterSpec.datastore must also be unset and VM.RegisterSpec.datastore-path must be set.

required placement VMRegisterPlacementSpec

Virtual machine placement information. This field is currently required. In the future, if this field is unset, the system will attempt to choose suitable resources on which to place the virtual machine.

Feedback

Was this page helpful?