Manager¶
-
class
cloudify.manager.NodeInstance(node_instance_id, node_id, runtime_properties=None, state=None, version=None, host_id=None, relationships=None)[source]¶ Bases:
objectRepresents a deployment node instance. An instance of this class contains runtime information retrieved from Cloudify’s runtime storage as well as the node’s state.
-
runtime_properties¶ The node instance runtime properties.
To update the properties, make changes on the returned dict and call
update_node_instancewith the modified instance.
-
state¶ The node instance state.
To update the node instance state, change this property value and call
update_node_instancewith the modified instance.
-
node_id¶
-
relationships¶
-
-
cloudify.manager.get_rest_client()[source]¶ Returns: A REST client configured to connect to the manager in context Return type: cloudify_rest_client.CloudifyClient
-
cloudify.manager.download_resource(resource_path, logger, target_path=None)[source]¶ Download resource from the manager file server.
Parameters: - resource_path – path to resource on the file server
- logger – logger to use for info output
- target_path – optional target path for the resource
Returns: path to the downloaded resource
-
cloudify.manager.download_blueprint_resource(blueprint_id, resource_path, logger, target_path=None)[source]¶ Download resource from the manager file server with path relative to the blueprint denoted by
blueprint_id.Parameters: - blueprint_id – the blueprint id of the blueprint to download the resource from
- resource_path – path to resource relative to blueprint folder
- logger – logger to use for info output
- target_path – optional target path for the resource
Returns: path to the downloaded resource
-
cloudify.manager.get_resource(resource_path, base_url=None)[source]¶ Get resource from the manager file server.
Parameters: resource_path – path to resource on the file server Returns: resource content
-
cloudify.manager.get_blueprint_resource(blueprint_id, resource_path)[source]¶ Get resource from the manager file server with patch relative to the blueprint denoted by
blueprint_id.Parameters: - blueprint_id – the blueprint id of the blueprint to download the resource from
- resource_path – path to resource relative to blueprint folder
Returns: resource content
-
cloudify.manager.get_node_instance(node_instance_id)[source]¶ Read node instance data from the storage.
Parameters: node_instance_id – the node instance id Return type: NodeInstance
-
cloudify.manager.update_node_instance(node_instance)[source]¶ Update node instance data changes in the storage.
Parameters: node_instance – the node instance with the updated data
-
cloudify.manager.get_node_instance_ip(node_instance_id)[source]¶ Get the IP address of the host the node instance denoted by
node_instance_idis contained in.