GET /api/compute_resources
List all compute resources.

參數

參數名字 描述
search
選填

篩選結果

Validations:

  • Must be a String

order
選填

排序結果

Validations:

  • Must be a String

page
選填

編頁結果

Validations:

  • Must be a String

per_page
選填

每個請求的項目數量

Validations:

  • Must be a String


GET /api/compute_resources/:id
Show an compute resource.

參數

參數名字 描述
id
必填

Validations:

  • Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.


POST /api/compute_resources
Create a compute resource.

參數

參數名字 描述
compute_resource
必填

Validations:

  • Must be a Hash

compute_resource[name]
必填

Validations:

  • Must be a String

compute_resource[provider]
選填

Providers include Libvirt, Ovirt, EC2, Vmware, Openstack, Rackspace, GCE

Validations:

  • Must be a String

compute_resource[url]
選填

URL for Libvirt, oVirt, and OpenStack

Validations:

  • Must be a String

compute_resource[description]
選填

Validations:

  • Must be a String

compute_resource[user]
選填

oVirt、EC2、VMware、OpenStack 的使用者名稱。EC2 的存取金鑰。

Validations:

  • Must be a String

compute_resource[password]
選填

Ovirt、EC2、Vmware、Openstack 的密碼。EC2 的祕密金鑰

Validations:

  • Must be a String

compute_resource[uuid]
選填

適用於 Ovirt、Vmware Datacenter

Validations:

  • Must be a String

compute_resource[region]
選填

僅適用於 EC2

Validations:

  • Must be a String

compute_resource[tenant]
選填

僅適用於 Openstack

Validations:

  • Must be a String

compute_resource[server]
選填

適用於 Vmware

Validations:

  • Must be a String

compute_resource[set_console_password]
選填

僅適用於 Libvirt 和 VMware

Validations:

  • Must be one of: true, false, 1, 0


PUT /api/compute_resources/:id
Update a compute resource.

參數

參數名字 描述
id
必填

Validations:

  • Must be a String

compute_resource
必填

Validations:

  • Must be a Hash

compute_resource[name]
選填

Validations:

  • Must be a String

compute_resource[provider]
選填

Providers include Libvirt, Ovirt, EC2, Vmware, Openstack, Rackspace, GCE

Validations:

  • Must be a String

compute_resource[url]
選填

URL for Libvirt, oVirt, and OpenStack

Validations:

  • Must be a String

compute_resource[description]
選填

Validations:

  • Must be a String

compute_resource[user]
選填

oVirt、EC2、VMware、OpenStack 的使用者名稱。EC2 的存取金鑰。

Validations:

  • Must be a String

compute_resource[password]
選填

Ovirt、EC2、Vmware、Openstack 的密碼。EC2 的祕密金鑰

Validations:

  • Must be a String

compute_resource[uuid]
選填

適用於 Ovirt、Vmware Datacenter

Validations:

  • Must be a String

compute_resource[region]
選填

僅適用於 EC2

Validations:

  • Must be a String

compute_resource[tenant]
選填

僅適用於 Openstack

Validations:

  • Must be a String

compute_resource[server]
選填

適用於 Vmware

Validations:

  • Must be a String


DELETE /api/compute_resources/:id
Delete a compute resource.

參數

參數名字 描述
id
必填

Validations:

  • Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.