libcloud.backup.drivers.ebs module

class libcloud.backup.drivers.ebs.EBSBackupDriver(access_id, secret, region)[source]

Bases: BackupDriver

Parameters:
  • key (str) – API key or username to used (required)

  • secret (str) – Secret password to be used (required)

  • secure (bool) – Whether to use HTTPS or HTTP. Note: Some providers only support HTTPS, and it is on by default.

  • host (str) – Override hostname used for connections.

  • port (int) – Override port used for connections.

Returns:

None

cancel_target_job(job)[source]

Cancel a backup job on a target

Parameters:

job (Instance of BackupTargetJob) – Backup target job to cancel

Return type:

bool

connectionCls

alias of EBSConnection

create_target(name, address, type='Volume', extra=None)[source]

Creates a new backup target

Parameters:
  • name (str) – Name of the target

  • address (str) – The volume ID.

  • type (BackupTargetType) – Backup target type (Physical, Virtual, …).

  • extra (dict) – (optional) Extra attributes (driver specific).

Return type:

Instance of BackupTarget

create_target_from_container(container, type='Object', extra=None)[source]

Creates a new backup target from an existing storage container

Parameters:
  • node (Container) – The Container to backup

  • type (BackupTargetType) – Backup target type (Physical, Virtual, …).

  • extra (dict) – (optional) Extra attributes (driver specific).

Return type:

Instance of BackupTarget

create_target_from_node(node, type='Virtual', extra=None)[source]

Creates a new backup target from an existing node

Parameters:
  • node (Node) – The Node to backup

  • type (BackupTargetType) – Backup target type (Physical, Virtual, …).

  • extra (dict) – (optional) Extra attributes (driver specific).

Return type:

Instance of BackupTarget

create_target_job(target, extra=None)[source]

Create a new backup job on a target

Parameters:
  • target (Instance of BackupTarget) – Backup target with the backup data

  • extra (dict) – (optional) Extra attributes (driver specific).

Return type:

Instance of BackupTargetJob

delete_target(target)[source]

Delete a backup target

Parameters:

target (Instance of BackupTarget) – Backup target to delete

ex_get_target_by_volume_id(volume_id)[source]
get_supported_target_types()[source]

Get a list of backup target types this driver supports

Returns:

list of :class:BackupTargetType

get_target_job(target, id)[source]

Get a specific backup job by ID

Parameters:
  • target (Instance of BackupTarget) – Backup target with the backup data

  • id (Instance of BackupTarget) – Backup target with the backup data

Return type:

BackupTargetJob

list_recovery_points(target, start_date=None, end_date=None)[source]

List the recovery points available for a target

Parameters:
  • target (Instance of BackupTarget) – Backup target to delete

  • start_date (datetime.datetime) – The start date to show jobs between (optional)

  • end_date (datetime.datetime`) – The end date to show jobs between (optional)

Return type:

list of BackupTargetRecoveryPoint

list_target_jobs(target)[source]

List the backup jobs on a target

Parameters:

target (Instance of BackupTarget) – Backup target with the backup data

Return type:

list of BackupTargetJob

list_targets()[source]

List all backuptargets

Return type:

list of BackupTarget

name = 'Amazon EBS Backup Driver'
recover_target(target, recovery_point, path=None)[source]

Recover a backup target to a recovery point

Parameters:
  • target (Instance of BackupTarget) – Backup target to delete

  • recovery_point (Instance of BackupTarget) – Backup target with the backup data

  • path (str) – The part of the recovery point to recover (optional)

Return type:

Instance of BackupTargetJob

recover_target_out_of_place(target, recovery_point, recovery_target, path=None)[source]

Recover a backup target to a recovery point out-of-place

Parameters:
  • target (Instance of BackupTarget) – Backup target with the backup data

  • recovery_point (Instance of BackupTarget) – Backup target with the backup data

  • recovery_target (Instance of BackupTarget) – Backup target with to recover the data to

  • path (str) – The part of the recovery point to recover (optional)

Return type:

Instance of BackupTargetJob

resume_target_job(job)[source]

Resume a suspended backup job on a target

Parameters:

job (Instance of BackupTargetJob) – Backup target job to resume

Return type:

bool

suspend_target_job(job)[source]

Suspend a running backup job on a target

Parameters:

job (Instance of BackupTargetJob) – Backup target job to suspend

Return type:

bool

update_target(target, name, address, extra)[source]

Update the properties of a backup target

Parameters:
  • target (Instance of BackupTarget) – Backup target to update

  • name (str) – Name of the target

  • address (str) – Hostname, FQDN, IP, file path etc.

  • extra (dict) – (optional) Extra attributes (driver specific).

Return type:

Instance of BackupTarget

website = 'http://aws.amazon.com/ebs/'