compute#

async idem_vra.exec.vra.iaas.compute.attach_machine_disk(hub, ctx, p_id, blockDeviceId, **kwargs)[source]#

Attach machine disk Attach a disk to a machine. Performs POST /iaas/api/machines/{id}/disks

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • blockDeviceId (string) – (required in body) The id of the existing block device

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • scsiController (string) – (optional in body) Deprecated: The SCSI controller to be assigned

  • name (string) – (optional in body) A human-friendly name used as an identifier in APIs that support this option.

  • description (string) – (optional in body) A human-friendly description.

  • unitNumber (string) – (optional in body) Deprecated: The Unit Number to be assigned

  • diskAttachmentProperties (object) – (optional in body) Disk Attachment specific properties

async idem_vra.exec.vra.iaas.compute.change_security_groups(hub, ctx, p_id, _links, id, **kwargs)[source]#
Change security groups for a vSphere machine Change security groups for a vSphere machine network interfaces. Securing group

that is part of the same deployment can be added or removed for a machine network interface. Performs POST /iaas/api/machines/{id}/operations/change-security-groups

Parameters:
  • p_id (string) – (required in path) The id of the vSphere machine.

  • _links (object) – (required in body) HATEOAS of the entity

  • id (string) – (required in body) The id of this resource instance

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • owner (string) – (optional in body) Email of the user that owns the entity.

  • createdAt (string) – (optional in body) Date when the entity was created. The date is in ISO 8601 and UTC.

  • networkInterfaceSpecifications (array) – (optional in body) A set of network interface controller specifications for this machine. If not specified, then no reconfiguration will be performed.

  • name (string) – (optional in body) A human-friendly name used as an identifier in APIs that support this option.

  • description (string) – (optional in body) A human-friendly description.

  • orgId (string) – (optional in body) The id of the organization this entity belongs to.

  • updatedAt (string) – (optional in body) Date when the entity was last updated. The date is ISO 8601 and UTC.

async idem_vra.exec.vra.iaas.compute.create_machine_snapshot(hub, ctx, p_id, _links, id, **kwargs)[source]#

Create snapshot operation for machine Second day create snapshot operation for machine Performs POST /iaas/api/machines/{id}/operations/snapshots

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • _links (object) – (required in body) HATEOAS of the entity

  • id (string) – (required in body) The id of this resource instance

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • owner (string) – (optional in body) Email of the user that owns the entity.

  • createdAt (string) – (optional in body) Date when the entity was created. The date is in ISO 8601 and UTC.

  • snapshotMemory (boolean) – (optional in body) Captures the full state of a running virtual machine, including the memory.

  • customProperties (object) – (optional in body) Additional custom properties that may be used to extend the snapshot.

  • name (string) – (optional in body) A human-friendly name used as an identifier in APIs that support this option.

  • description (string) – (optional in body) A human-friendly description.

  • orgId (string) – (optional in body) The id of the organization this entity belongs to.

  • updatedAt (string) – (optional in body) Date when the entity was last updated. The date is ISO 8601 and UTC.

async idem_vra.exec.vra.iaas.compute.create_machine(hub, ctx, image, flavor, name, flavorRef, imageRef, projectId, **kwargs)[source]#

Create machine Create machine Performs POST /iaas/api/machines

Parameters:
  • image (string) – (required in body) Type of image used for this machine.

  • flavor (string) – (required in body) Flavor of machine instance.

  • name (string) – (required in body) A human-friendly name used as an identifier in APIs that support this option.

  • flavorRef (string) – (required in body) Provider specific flavor reference. Valid if no flavor property is provided

  • imageRef (string) – (required in body) Direct image reference used for this machine (name, path, location, uri, etc.). Valid if no image property is provided

  • projectId (string) – (required in body) The id of the project the current user belongs to.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • disks (array) – (optional in body) A set of disk specifications for this machine.

  • imageDiskConstraints (array) – (optional in body) Constraints that are used to drive placement policies for the image disk. Constraint expressions are matched against tags on existing placement targets.

  • description (string) – (optional in body) Describes machine within the scope of your organization and is not propagated to the cloud

  • machineCount (integer) – (optional in body) Number of machines to provision - default 1.

  • constraints (array) – (optional in body) Constraints that are used to drive placement policies for the virtual machine that is produced from this specification. Constraint expressions are matched against tags on existing placement targets.

  • tags (array) – (optional in body) A set of tag keys and optional values that should be set on any resource that is produced from this specification.

  • customProperties (object) – (optional in body) Additional custom properties that may be used to extend this resource.

  • saltConfiguration (Any) – (optional in body)

  • deploymentId (string) – (optional in body) The id of the deployment that is associated with this resource

  • bootConfig (Any) – (optional in body)

  • bootConfigSettings (Any) – (optional in body)

  • nics (array) – (optional in body) A set of network interface controller specifications for this machine. If not specified, then a default network connection will be created.

  • remoteAccess (Any) – (optional in body)

async idem_vra.exec.vra.iaas.compute.delete_machine_disk(hub, ctx, p_id, p_diskId, **kwargs)[source]#

Delete machine disk Remove a disk from a given machine. Performs DELETE /iaas/api/machines/{id}/disks/{diskId}

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • p_diskId (string) – (required in path) The ID of the disk.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.delete_machine_snapshot(hub, ctx, p_id, p_snapshotId, **kwargs)[source]#

Delete snapshot operation for machine Second day delete snapshot operation for machine Performs DELETE /iaas/api/machines/{id}/snapshots/{snapshotId}

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • p_snapshotId (string) – (required in path) Snapshot id to delete.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.delete_machine(hub, ctx, p_id, **kwargs)[source]#

Delete Machine Delete Machine with a given id Performs DELETE /iaas/api/machines/{id}

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • forceDelete (boolean) – (optional in query) Controls whether this is a force delete operation. If true, best effort is made for deleting this machine. Use with caution as force deleting may cause inconsistencies between the cloud provider and vRA.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.get_machine_disk(hub, ctx, p_id, p_diskId, **kwargs)[source]#

Get machine disk Get disk with a given id for specific machine Performs GET /iaas/api/machines/{id}/disks/{diskId}

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • p_diskId (string) – (required in path) The ID of the disk.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.get_machine_disks(hub, ctx, p_id, **kwargs)[source]#

Get machine disks Get all machine disks Performs GET /iaas/api/machines/{id}/disks

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.get_machine_network_interface(hub, ctx, p_id, p_networkId, **kwargs)[source]#

Get machine network interface Get network interface with a given id for specific machine Performs GET /iaas/api/machines/{id}/network-interfaces/{networkId}

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • p_networkId (string) – (required in path) The ID of the network interface.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.get_machine_snapshot(hub, ctx, p_id, p_snapshotId, **kwargs)[source]#

Get machine snapshot Get snapshot with a given id for specific machine Performs GET /iaas/api/machines/{id}/snapshots/{snapshotId}

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • p_snapshotId (string) – (required in path) The ID of the snapshot.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.get_machine_snapshots(hub, ctx, p_id, **kwargs)[source]#

Get machine snapshots information Get machine snapshots information Performs GET /iaas/api/machines/{id}/snapshots

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.get_machine(hub, ctx, p_id, **kwargs)[source]#

Get machine Get machine with a given id Performs GET /iaas/api/machines/{id}

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • select (string) – (optional in query) Select a subset of properties to include in the response.

async idem_vra.exec.vra.iaas.compute.get_machines(hub, ctx, **kwargs)[source]#

Get machines Get all machines Performs GET /iaas/api/machines

Parameters:
  • skipOperationLinks (boolean) – (optional in query) If set to true will not return operation links.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • top (integer) – (optional in query) Number of records you want to get.

  • skip (integer) – (optional in query) Number of records you want to skip.

  • count (boolean) – (optional in query) Flag which when specified, regardless of the assigned value, shows the total number of records. If the collection has a filter it shows the number of records matching the filter.

  • select (string) – (optional in query) Select a subset of properties to include in the response.

  • filter (string) – (optional in query) Filter the results by a specified predicate expression. Operators: eq, ne, and, or.

async idem_vra.exec.vra.iaas.compute.patch_machine_network_interface(hub, ctx, p_id, p_networkId, **kwargs)[source]#
Patch machine network interface Patch network interface with a given id for specific machine. Only name,

description, IPv4 address and custom property updates are supported. The change to name and IPv4 address will not propagate to cloud endpoint for provisioned machines. Performs PATCH /iaas/api/machines/{id}/network-interfaces/{networkId}

Parameters:
  • p_id (string) – (required in path) The ID of the machine.

  • p_networkId (string) – (required in path) The ID of the network interface.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • customProperties (object) – (optional in body) Additional custom properties that may be used to extend the machine. Internal custom properties (for example, prefixed with: “__”) can not be updated.

  • address (string) – (optional in body) Set IPv4 address for the machine network interface. The change will not propagate to cloud endpoint for provisioned machines.

  • name (string) – (optional in body) Network interface name used during machine network interface provisioning. This property only takes effect if it is set before machine provisioning starts. The change will not propagate to cloud endpoint for provisioned machines.

  • description (string) – (optional in body) Describes the network interface of the machine within the scope of your organization and is not propagated to the cloud

async idem_vra.exec.vra.iaas.compute.power_off_machine(hub, ctx, p_id, **kwargs)[source]#

Power-off operation for machine Second day power-off operation for machine Performs POST /iaas/api/machines/{id}/operations/power-off

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.power_on_machine(hub, ctx, p_id, **kwargs)[source]#

Power-on operation for machine Second day power-on operation for machine Performs POST /iaas/api/machines/{id}/operations/power-on

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.reboot_machine(hub, ctx, p_id, **kwargs)[source]#

Reboot operation for machine Second day reboot operation for machine Performs POST /iaas/api/machines/{id}/operations/reboot

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.reset_machine(hub, ctx, p_id, **kwargs)[source]#

Reset operation for machine Second day reset operation for machine Performs POST /iaas/api/machines/{id}/operations/reset

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.resize_machine(hub, ctx, p_id, **kwargs)[source]#

Resize operation for machine Second day resize operation for machine Performs POST /iaas/api/machines/{id}/operations/resize

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • name (string) – (optional in query) The desired flavor to resize the Machine.

  • cpuCount (string) – (optional in query) The desired number of CPUs to resize the Machine

  • memoryInMB (string) – (optional in query) The desired memory in MBs to resize the Machine

  • coreCount (string) – (optional in query) The desired number of cores per socket to resize the Machine

  • rebootMachine (boolean) – (optional in query) Only applicable for vSphere VMs with the CPU Hot Add or Memory Hot Plug options enabled. If set to false, VM is resized without reboot.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.restart_machine(hub, ctx, p_id, **kwargs)[source]#

Restart operation for machine Second day restart operation for machine Performs POST /iaas/api/machines/{id}/operations/restart

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.revert_machine_snapshot(hub, ctx, p_id, p_snapshotId, **kwargs)[source]#

Revert snapshot operation for machine Second day revert snapshot operation for machine Performs POST /iaas/api/machines/{id}/operations/revert/{snapshotId}

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • p_snapshotId (string) – (required in path) Snapshot id to revert.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.shutdown_machine(hub, ctx, p_id, **kwargs)[source]#

Shut down operation for machine Second day shut down operation machine Performs POST /iaas/api/machines/{id}/operations/shutdown

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.suspend_machine(hub, ctx, p_id, **kwargs)[source]#

Suspend operation for machine Second day suspend operation for machine Performs POST /iaas/api/machines/{id}/operations/suspend

Parameters:
  • p_id (string) – (required in path) The id of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.exec.vra.iaas.compute.update_machine(hub, ctx, p_id, **kwargs)[source]#
Update machine. Update machine. Only description, tag, custom property and bootConfig updates

are supported. Please note that all existing tags, assigned to this machine, that are not implicitly added in the Patch body, will be unassigned from this machine!All other properties in the MachineSpecification body are ignored. Performs PATCH /iaas/api/machines/{id}

Parameters:
  • p_id (string) – (required in path) The ID of the Machine.

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • customProperties (object) – (optional in body) Additional custom properties that may be used to extend the machine. Internal custom properties (for example, prefixed with: “__”) are discarded.

  • bootConfig (Any) – (optional in body)

  • description (string) – (optional in body) Describes machine within the scope of your organization and is not propagated to the cloud

  • tags (array) – (optional in body) A set of tag keys and optional values that should be set on any resource that is produced from this specification.