l.c.d.o.OpenStack_1_0_NodeDriver(OpenStackNodeDriver) : class documentation

Part of libcloud.compute.drivers.openstack View Source View In Hierarchy

Known subclasses: libcloud.compute.drivers.rackspace.RackspaceNodeDriver

OpenStack node driver.

Extra node attributes:
    - password: root password, available after create.
    - hostId: represents the host your cloud server runs on
    - imageId: id of image
    - flavorId: id of flavor
Method __init__ @requires: key, secret
Method create_node Create a new node
Method ex_set_password Sets the Node's root password.
Method ex_set_server_name Sets the Node's name.
Method ex_resize Change an existing server flavor / scale the server up or down.
Method ex_confirm_resize Confirm a resize request which is currently in progress. If a resize request is not explicitly confirmed or reverted it's automatically confirmed after 24 hours.
Method ex_revert_resize Revert a resize request which is currently in progress. All resizes are automatically confirmed after 24 hours if they have not already been confirmed explicitly or reverted.
Method ex_rebuild Rebuilds the specified server.
Method ex_create_ip_group Creates a shared IP group.
Method ex_list_ip_groups Lists IDs and names for shared IP groups. If details lists all details for shared IP groups.
Method ex_delete_ip_group Deletes the specified shared IP group.
Method ex_share_ip Shares an IP address to the specified server.
Method ex_unshare_ip Removes a shared IP address from the specified server.
Method ex_list_ip_addresses List all server addresses.
Method ex_limits No summary
Method ex_save_image Create an image for node.
Method ex_delete_image Delete an image for node.
Method _to_images Undocumented
Method _to_image Undocumented
Method _change_password_or_name Undocumented
Method _metadata_to_xml Undocumented
Method _files_to_xml Undocumented
Method _reboot_node Undocumented
Method _node_action Undocumented
Method _to_nodes Undocumented
Method _to_node_from_obj Undocumented
Method _to_node Undocumented
Method _to_sizes Undocumented
Method _to_size Undocumented
Method _to_shared_ip_group Undocumented
Method _to_ip_addresses Undocumented
Method _get_size_price Undocumented

Inherited from OpenStackNodeDriver:

Method __new__ @requires: key, secret
Method destroy_node Destroy a node.
Method reboot_node Reboot a node.
Method list_nodes List all nodes @return: list of node objects @rtype: C{list} of L{Node}
Method list_images @inherits: L{NodeDriver.list_images}
Method list_sizes List sizes on a provider
Method list_locations List data centers for a provider
Method ex_get_node_details Lists details of the specified server.
Method ex_soft_reboot_node Soft reboots the specified server
Method ex_hard_reboot_node Hard reboots the specified server
Method _ex_connection_class_kwargs Return extra connection keyword arguments which are passed to the Connection class constructor.

Inherited from NodeDriver (via OpenStackNodeDriver):

Method deploy_node Create a new node, and start deployment.
Method create_volume Create a new volume.
Method destroy_volume Destroys a storage volume.
Method attach_volume Attaches volume to node.
Method detach_volume Detaches a volume from a node.
Method _wait_until_running Block until node is fully booted and has an IP address assigned.
Method _ssh_client_connect Try to connect to the remote SSH server. If a connection times out or is refused it is retried up to timeout number of seconds.
Method _run_deployment_script Run the deployment script on the provided node. At this point it is assumed that SSH connection has already been established.

Inherited from OpenStackDriverMixin (via OpenStackNodeDriver):

Method openstack_connection_kwargs @rtype: C{dict}
def __init__(self, *args, **kwargs): (source)
@requires: key, secret
def _to_images(self, object, ex_only_active): (source)
Undocumented
def _to_image(self, element): (source)
Undocumented
def _change_password_or_name(self, node, name=None, password=None): (source)
Undocumented
def create_node(self, **kwargs): (source)
Create a new node

@inherits: L{NodeDriver.create_node}

@keyword    ex_metadata: Key/Value metadata to associate with a node
@type       ex_metadata: C{dict}

@keyword    ex_files:   File Path => File contents to create on
                        the node
@type       ex_files:   C{dict}
def ex_set_password(self, node, password): (source)
Sets the Node's root password.

This will reboot the instance to complete the operation.

L{Node.extra['password']} will be set to the new value if the
operation was successful.

@param      node: node to set password
@type       node: L{Node}

@param      password: new password.
@type       password: C{str}

@rtype: C{bool}
def ex_set_server_name(self, node, name): (source)
Sets the Node's name.

This will reboot the instance to complete the operation.

@param      node: node to set name
@type       node: L{Node}

@param      name: new name
@type       name: C{str}

@rtype: C{bool}
def ex_resize(self, node, size): (source)
Change an existing server flavor / scale the server up or down.

@param      node: node to resize.
@type       node: L{Node}

@param      size: new size.
@type       size: L{NodeSize}

@rtype: C{bool}
def ex_confirm_resize(self, node): (source)
Confirm a resize request which is currently in progress. If a resize
request is not explicitly confirmed or reverted it's automatically
confirmed after 24 hours.

For more info refer to the API documentation: http://goo.gl/zjFI1

@param      node: node for which the resize request will be confirmed.
@type       node: L{Node}

@rtype: C{bool}
def ex_revert_resize(self, node): (source)
Revert a resize request which is currently in progress.
All resizes are automatically confirmed after 24 hours if they have
not already been confirmed explicitly or reverted.

For more info refer to the API documentation: http://goo.gl/AizBu

@param      node: node for which the resize request will be reverted.
@type       node: L{Node}

@rtype: C{bool}
def ex_rebuild(self, node_id, image_id): (source)
Rebuilds the specified server.

@param       node_id: ID of the node which should be used
@type        node_id: C{str}

@param       image_id: ID of the image which should be used
@type        image_id: C{str}

@rtype: C{bool}
def ex_create_ip_group(self, group_name, node_id=None): (source)
Creates a shared IP group.

@param       group_name:  group name which should be used
@type        group_name: C{str}

@param       node_id: ID of the node which should be used
@type        node_id: C{str}

@rtype: C{bool}
def ex_list_ip_groups(self, details=False): (source)
Lists IDs and names for shared IP groups.
If details lists all details for shared IP groups.

@param       details: True if details is required
@type        details: C{bool}

@rtype: C{list} of L{OpenStack_1_0_SharedIpGroup}
def ex_delete_ip_group(self, group_id): (source)
Deletes the specified shared IP group.

@param       group_id:  group id which should be used
@type        group_id: C{str}

@rtype: C{bool}
def ex_share_ip(self, group_id, node_id, ip, configure_node=True): (source)
Shares an IP address to the specified server.

@param       group_id:  group id which should be used
@type        group_id: C{str}

@param       node_id: ID of the node which should be used
@type        node_id: C{str}

@param       ip: ip which should be used
@type        ip: C{str}

@param       configure_node: configure node
@type        configure_node: C{bool}

@rtype: C{bool}
def ex_unshare_ip(self, node_id, ip): (source)
Removes a shared IP address from the specified server.

@param       node_id: ID of the node which should be used
@type        node_id: C{str}

@param       ip: ip which should be used
@type        ip: C{str}

@rtype: C{bool}
def ex_list_ip_addresses(self, node_id): (source)
List all server addresses.

@param       node_id: ID of the node which should be used
@type        node_id: C{str}

@rtype: C{bool}
def _metadata_to_xml(self, metadata): (source)
Undocumented
def _files_to_xml(self, files): (source)
Undocumented
def _reboot_node(self, node, reboot_type='SOFT'): (source)
Undocumented
def _node_action(self, node, body): (source)
Undocumented
def _to_nodes(self, object): (source)
Undocumented
def _to_node_from_obj(self, obj): (source)
Undocumented
def _to_node(self, el): (source)
Undocumented
def _to_sizes(self, object): (source)
Undocumented
def _to_size(self, el): (source)
Undocumented
def ex_limits(self): (source)
Extra call to get account's limits, such as
rates (for example amount of POST requests per day)
and absolute limits like total amount of available
RAM to be used by servers.

@return: dict with keys 'rate' and 'absolute'
@rtype: C{dict}
def ex_save_image(self, node, name): (source)
Create an image for node.

@param      node: node to use as a base for image
@type       node: L{Node}

@param      name: name for new image
@type       name: C{str}

@rtype: L{NodeImage}
def ex_delete_image(self, image): (source)
Delete an image for node.

@param      image: the image to be deleted
@type       image: L{NodeImage}

@rtype: C{bool}
def _to_shared_ip_group(self, el): (source)
Undocumented
def _to_ip_addresses(self, el): (source)
Undocumented
def _get_size_price(self, size_id): (source)
Undocumented
API Documentation for libcloud, generated by pydoctor at 2012-11-19 11:53:43.