rubrik_polaris.compute package

Submodules

rubrik_polaris.compute.azurevm module

Collection of functions that manipulate AzureVM compute components

rubrik_polaris.compute.azurevm.get_compute_object_ids_azure(self, match_all=True, **kwargs)

Retrieves all Azure VM object IDs that match query

Parameters
  • match_all (bool) – Set to false to match ANY defined criteria

  • kwargs (str) – Any top level object from the get_compute_ec2 call

Returns

List of all the VM object id’s

Return type

list

Raises

RequestException – If the query to Polaris returned an error

rubrik_polaris.compute.azurevm.get_compute_azure(self)

Retrieves all Azure IAAS object details

Returns

details of Azure IAAS objects

Return type

dict

Raises

RequestException – If the query to Polaris returned an error

rubrik_polaris.compute.azurevm.submit_compute_restore_azure(self, snapshot_id, **kwargs)

Submits a Restore of a Azure VM

Parameters
  • snapshot_id (str) – Snapshot ID to be restored

  • should_power_on (bool) – Defaults to False

  • should_restore_tags (bool) – Defaults to False

  • wait (bool) – Return once complete Defaults to False

Returns

dict – List of errors if any occurred during the restore

rubrik_polaris.compute.common module

Collection of functions that manipulate compute components

rubrik_polaris.compute.ec2 module

Collection of functions that manipulate EC2 compute components

rubrik_polaris.compute.ec2.get_compute_object_ids_ec2(self, match_all=True, **kwargs)

Retrieves all AWS EC2 object IDs that match query

Parameters
  • match_all (bool) – Set to false to match ANY defined criteria

  • tags (dict) – Tags in {Name: Value} format to filter on

  • kwargs (str) – Any top level object from the get_compute_ec2 call

Returns

List of all the EC2 object id’s

Return type

list

Raises

RequestException – If the query to Polaris returned an error

rubrik_polaris.compute.ec2.get_compute_ec2(self, object_id=None)

Retrieves all AWS EC2 object details

Parameters

object_id (str) – optional specific object id to return

Returns

details of AWS instance objects

Return type

dict

Raises

RequestException – If the query to Polaris returned an error

rubrik_polaris.compute.ec2.submit_compute_restore_ec2(self, snapshot_id, **kwargs)

Submits a Restore of an EC2 instance

Parameters
  • snapshot_id (str) – Snapshot ID to be restored

  • should_power_on (bool) – Defaults to False

  • should_restore_tags (bool) – Defaults to False

  • wait (bool) – Return once complete Defaults to False

Returns

dict – List of errors if any occurred during the restore

rubrik_polaris.compute.ec2.submit_compute_export_ec2(self, snapshot_id=None, aws_account_number=None, aws_region=None, aws_vpc=None, aws_security_groups=None, aws_subnet=None, wait=False, aws_instance_type=None, aws_instance_name=None, copy_tags=True, use_replica=False)

Submits an export of a EC2 instance

Parameters
  • snapshot_id (str) – snapshot_id to export

  • aws_account_number (str) – aws account number to recover to

  • aws_region (str) – aws region to export to

  • aws_vpc (str) – aws vpc to assign to export

  • aws_security_groups (list) – aws security groups to assign to export

  • aws_subnet (str) – aws subnet to assign to export

  • wait (bool) – Return once complete Defaults to False

Returns

dict – List of errors if any occurred during the export

rubrik_polaris.compute.gce module

Collection of functions that manipulate GCE compute components

rubrik_polaris.compute.gce.get_compute_object_ids_gce(self, match_all=True, **kwargs)

Retrieves all GCP GCE object IDs that match query

Parameters
  • match_all (bool) – Set to false to match ANY defined criteria

  • kwargs (str) – Any top level object from the get_compute_gce call

Returns

List of all the GCE object id’s

Return type

list

Raises

RequestException – If the query to Polaris returned an error

rubrik_polaris.compute.gce.get_compute_gce(self)

Retrieves all GCP GCE object details

Returns

details of GCP GCE objects

Return type

dict

Raises

RequestException – If the query to Polaris returned an error

rubrik_polaris.compute.gce.submit_compute_restore_gce(self, snapshot_id, **kwargs)

Submits a Restore of a GCE instance

Parameters
  • snapshot_id (str) – Snapshot ID to be restored

  • should_power_on (bool) – Defaults to False

  • should_restore_tags (bool) – Defaults to False

  • wait (bool) – Return once complete Defaults to False

Returns

dict – List of errors if any occurred during the restore

rubrik_polaris.compute.vsphere module

Collection of functions that manipulate vSphere compute components

rubrik_polaris.compute.vsphere.get_compute_object_ids_vsphere(self, match_all=True, **kwargs)

Retrieves all vSphere objects that match query

Parameters
  • {bool} -- Set to false to match ANY defined criteria (match_all) –

  • {} -- Any top level object from the get_compute_ec2 call (kwargs) –

rubrik_polaris.compute.vsphere.get_compute_vsphere(self)

Retrieves all VMware VM object details (Under development)

Returns

details of VMware VM objects

Return type

dict

Raises

RequestException – If the query to Polaris returned an error

Module contents

Collection of functions that interact with Compute objects.