Beispiele

POST /api/compute_resources
{
  "compute_resource": {
    "name": "Ovirt-create-test",
    "url": "https://myovirt/api",
    "provider": "ovirt",
    "datacenter": "8c30ea90-9bc8-4a90-867b-1a8ccdef44e8",
    "user": "user@example.com",
    "password": "secret"
  }
}
201
{
  "description": null,
  "url": "https://myovirt/api",
  "created_at": "2019-09-11 14:37:28 UTC",
  "updated_at": "2019-09-11 14:37:28 UTC",
  "id": 980190963,
  "name": "Ovirt-create-test",
  "provider": "Ovirt",
  "provider_friendly_name": "oVirt",
  "user": "user@example.com",
  "datacenter": "8c30ea90-9bc8-4a90-867b-1a8ccdef44e8",
  "use_v4": false,
  "ovirt_quota": null,
  "display_type": "vnc",
  "keyboard_layout": "en-us",
  "images": [],
  "compute_attributes": [],
  "locations": [],
  "organizations": []
}

Parameter

Parametername Beschreibung
location_id
optional

Scope nach Standorten

Validations:

  • Must be a Integer

organization_id
optional

Scope nach Organisationen

Validations:

  • Must be a Integer

compute_resource
verpflichtend

Validations:

  • Must be a Hash

compute_resource[name]
verpflichtend

Validations:

  • Must be a String

compute_resource[provider]
optional , nil erlaubt

Provider umfassen Libvirt, Ovirt, EC2, Vmware, Openstack, Rackspace, GCE

Validations:

  • Must be a String

compute_resource[url]
optional , nil erlaubt

URL für Libvirt, oVirt, OpenStack und Rackspace

Validations:

  • Must be a String

compute_resource[description]
optional , nil erlaubt

Validations:

  • Must be a String

compute_resource[user]
optional , nil erlaubt

Benutzername für oVirt, EC2, VMware, OpenStack. Access Key für EC2.

Validations:

  • Must be a String

compute_resource[password]
optional , nil erlaubt

Passwort für oVirt, EC2, VMware, OpenStack. Geheimer Schlüssel für EC2

Validations:

  • Must be a String

compute_resource[uuid]
optional , nil erlaubt

Veraltet, bitte Datacenter verwenden

Validations:

  • Must be a String

compute_resource[datacenter]
optional , nil erlaubt

für oVirt, VMware Datacenter

Validations:

  • Must be a String

compute_resource[use_v4]
optional , nil erlaubt

nur für oVirt

Validations:

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

compute_resource[ovirt_quota]
optional , nil erlaubt

for oVirt only, ID of quota to use

Validations:

  • Must be a String

compute_resource[public_key]
optional , nil erlaubt

nur für oVirt

Validations:

  • Must be a String

compute_resource[region]
optional , nil erlaubt

for EC2 only, use ‘us-gov-west-1’ for GovCloud region

Validations:

  • Must be a String

compute_resource[tenant]
optional , nil erlaubt

nur für OpenStack

Validations:

  • Must be a String

compute_resource[domain]
optional , nil erlaubt

for OpenStack (v3) only

Validations:

  • Must be a String

compute_resource[project_domain_name]
optional , nil erlaubt

for OpenStack (v3) only

Validations:

  • Must be a String

compute_resource[project_domain_id]
optional , nil erlaubt

for OpenStack (v3) only

Validations:

  • Must be a String

compute_resource[server]
optional , nil erlaubt

für VMware

Validations:

  • Must be a String

compute_resource[set_console_password]
optional , nil erlaubt

nur für Libvirt und VMware

Validations:

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

compute_resource[display_type]
optional , nil erlaubt

for Libvirt and oVirt only

Validations:

  • Must be one of: VNC, SPICE.

compute_resource[keyboard]
optional , nil erlaubt

nur für oVirt

Validations:

  • Must be one of: ar, de-ch, es, fo, fr-ca, hu, ja, mk, no, pt-br, sv, da, en-gb, et, fr, fr-ch, is, lt, nl, pl, ru, th, de, en-us, fi, fr-be, hr, it, lv, nl-be, pt, sl, tr.

compute_resource[caching_enabled]
optional , nil erlaubt

Caching aktivieren, nur für VMware

Validations:

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

compute_resource[project]
optional , nil erlaubt

Project id for GCE only

Validations:

  • Must be a String

compute_resource[email]
optional , nil erlaubt

Email for GCE only

Validations:

  • Must be a String

compute_resource[key_path]
optional , nil erlaubt

Certificate path for GCE only

Validations:

  • Must be a String

compute_resource[zone]
optional , nil erlaubt

for GCE only

Validations:

  • Must be a String

compute_resource[location_ids]
optional , nil erlaubt

Standorte durch angegebene Kennungen ERSETZEN

Validations:

  • Must be an array of any type

compute_resource[organization_ids]
optional , nil erlaubt

Organisationen durch angegebene Kennungen ERSETZEN

Validations:

  • Must be an array of any type