Hi,
I am trying to attach a vdisk to a VM. So far I have found that the only way to create and attach a new vdisk to VM is via this API
POST /vms/{uuid}/disks/attach
I am trying using this curl expression:
curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' -d '{
"uuid": "IDEMPOTENT_UUID",
"vm_disks": s
{
"is_cdrom": false,
"is_empty": false,
"is_scsi_pass_through": false,
"is_thin_provisioned": false,
"vm_disk_create": {
"size": 1,
"storage_container_uuid": "CONTAINER_UUID"
}
}
]
}' 'https://10.10.10.10:9440/api/nutanix/v2.0/vms/VM_UUID/disks/attach' \
--insecure --basic --user obfuscated_username:obfuscated_password
The task fails and error is: “InvalidArgument: Invalid disk size 0”.
What am I missing here?
Thanks for your time,
Ivars