Package starcluster :: Module awsutils :: Class EasyEC2
[hide private]
[frames] | no frames]

Class EasyEC2

source code


Instance Methods [hide private]
 
__init__(self, aws_access_key_id, aws_secret_access_key, aws_ec2_path='/', aws_s3_path='/', aws_port=None, aws_region_name=None, aws_is_secure=True, aws_region_host=None, cache=False, **kwargs)
Create an EasyAWS object.
source code
 
__check_for_auth_failure(self, e) source code
 
get_registered_image(self, image_id) source code
 
create_group(self, name, description, auth_ssh=True, auth_group_traffic=False) source code
 
get_group_or_none(self, name) source code
 
get_or_create_group(self, name, description, auth_ssh=True, auth_group_traffic=False)
Try to return a security group by name.
source code
 
request_spot_instances(self, price, image_id, instance_type='m1.small', count=1, launch_group=None, key_name=None, availability_zone_group=None, security_groups=None, placement=None) source code
 
run_instances(self, image_id, instance_type='m1.small', min_count=1, max_count=1, key_name=None, security_groups=None, placement=None) source code
 
register_image(self, name, description=None, image_location=None, architecture=None, kernel_id=None, ramdisk_id=None, root_device_name=None, block_device_map=None) source code
 
get_keypair(self, keypair) source code
 
get_keypair_or_none(self, keypair) source code
 
__print_header(self, msg) source code
 
get_image_name(self, img) source code
 
get_instance(self, instance_id) source code
 
is_valid_conn(self) source code
 
get_all_instances(self, instance_ids=[]) source code
 
list_all_spot_instances(self, show_closed=False) source code
 
list_all_instances(self, show_terminated=False) source code
 
list_images(self, images) source code
 
list_registered_images(self) source code
 
list_executable_images(self) source code
 
__list_images(self, msg, imgs) source code
 
remove_image_files(self, image_name, pretend=True) source code
 
remove_image(*arg, **kargs)
Raw timing function
source code
 
list_starcluster_public_images(self) source code
 
remove_volume(self, volume_id) source code
 
list_zones(self) source code
 
get_zone(self, zone) source code
 
get_zone_or_none(self, zone) source code
 
get_image(self, image_id) source code
 
get_image_or_none(self, image_id) source code
 
get_image_files(self, image_id) source code
 
list_image_files(self, image_id) source code
 
terminate_instances(self, instances=None) source code
 
get_volumes(self) source code
 
get_volume(self, volume_id) source code
 
get_volume_or_none(self, volume_id) source code
 
list_volumes(self) source code
 
get_security_group(self, groupname) source code
 
get_security_groups(self) source code
 
get_spot_history(self, instance_type, start=None, end=None, plot=False) source code
 
show_console_output(self, instance_id) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]
  registered_images
  executable_images
  instances
  keypairs

Inherited from EasyAWS: conn

Inherited from object: __class__

Method Details [hide private]

__init__(self, aws_access_key_id, aws_secret_access_key, aws_ec2_path='/', aws_s3_path='/', aws_port=None, aws_region_name=None, aws_is_secure=True, aws_region_host=None, cache=False, **kwargs)
(Constructor)

source code 

Create an EasyAWS object.

Requires AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY from an Amazon Web Services (AWS) account and a CONNECTION_AUTHENTICATOR function that returns an authenticated AWS connection object

Providing only the keys will default to using Amazon EC2

kwargs are passed to the connection_authenticator constructor

Overrides: object.__init__
(inherited documentation)

get_or_create_group(self, name, description, auth_ssh=True, auth_group_traffic=False)

source code 

Try to return a security group by name. If the group is not found, attempt to create it. Description only applies to creation.

Authorizes all traffic between members of the group

remove_image(*arg, **kargs)

source code 

Raw timing function

Decorators:
  • @print_timing

Property Details [hide private]

registered_images

Get Method:
unreachable.registered_images(self)

executable_images

Get Method:
unreachable.executable_images(self)

instances

Get Method:
unreachable.instances(self)

keypairs

Get Method:
unreachable.keypairs(self)