Defines the attributes for creating a virtual machine. An instance of this class is passed to resource.createInstance(), resource.createTemplate(), resource.clone().
VmSpec(GridObjectInfo): Constructs a default VmSpec.
Set facts for preparing the new VM.
Set facts for preparing the new VM.
Sets the name of the VM to be created.
Sets the name of a repository for creating the VM if required by the provisioning adapter.
Sets whether to use the autoprep facts on the resource for creating the new VM.
VmSpec here is used for creating a clone on a named host from a template resource:
resource = getMatrix().getGridObject(TYPE_RESOURCE,"myTemplate") spec = VmSpec() spec.setNewName("newvm") spec.setHost('vmhost-qa') resource.clone(spec)
Javadoc: VmSpec