API tạo VM từ Template
Last updated
Last updated
Trong tài liệu này, bạn sẽ tìm thấy thông tin chi tiết về cách chuẩn bị và tạo VM từ template
API này tạo một VM với tên mặc định (tên VM của template), network mặc định "VM Network," và compute và storage mặc định
Bước 1: Thu thập thông tin
Đăng nhập vào IAM portal -> vCD portal: thu thập thông tin
{{vcd_url}}
{{vdc_uuid}}: Đăng nhập vào vCD portal -> chọn VDC -> xem và ghi lại vdc_uuid trên URL
{{network_uuid}}: Trên vCD portal -> Networking -> Networks -> New
Lưu ý tên network phải là "VM Network"
Chọn “VM Network” -> và ghi lại thông tin network uuid trên url.
{{vappTemplate_uuid}}: Trên vCD portal -> Content Hub -> Catalogs ->HIGIO Shared Catalogs
-> vApp Templates -> Chọn template mà bạn muốn tạo VM -> ghi lại vappTemplate_uuid trên url.
{{Bearer Token}}: Làm theo hướng dẫn “Api đăng nhập băng token” .
Bước 2: Tạo VM từ template.
Postman:
OST https://{{vcd_url}}/api/vdc
/{{vdc_uuid}}/action/instantiateVAppTemplate
Authorization: {{Bearer Token }}
Headers:
- 'Accept: */*;version=37.2
- ‘Content-type’: application/vnd.vmware.vcloud.instantiateVAppTemplateParams+xml; charset=ISO-8859-1
Body: {{Chọn Raw, Sao chép, Dán và Chỉnh sửa code bên dưới}}
SEND request.