yakumo.nova.v2.server.Manager

Package yakumo :: Package nova :: Package v2 :: Module server :: Class Manager |
[hide private]
[frames] | no frames]

# Class Manager

source code

      object --+
               |
    base.Manager --+
                   |
                  Manager

Manager class for servers in Compute API v2

Nested Classes | [hide private]
| resource_class Resource class for servers in Compute API v2

Instance Methods | [hide private]
_json2attr(self, json_params) | source code
yakumo.nova.v2.server.Resource |
create(self, name=`'``__UNDEF__``'`, image=`'``__UNDEF__``'`, flavor=`'``__UNDEF__``'`, personality=`'``__UNDEF__``'`, disks=`'``__UNDEF__``'`, max_count=`'``__UNDEF__``'`, min_count=`'``__UNDEF__``'`, networks=`'``__UNDEF__``'`, security_groups=`'``__UNDEF__``'`, availability_zone=`'``__UNDEF__``'`, metadata=`'``__UNDEF__``'`, config_drive=`'``__UNDEF__``'`, key_pair=`'``__UNDEF__``'`, user_data=`'``__UNDEF__``'`) Create a new server | source code
Inherited from `base.Manager`: `__init__`, `find`, `find_one`, `get`, `get_empty`, `list` Inherited from `base.Manager` (private): `_attr2json`, `_find_gen`, `_no_such_api` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__sizeof__`, `__str__`, `__subclasshook__`

Class Variables | [hide private]
| service_type = ``'``compute``'``
| _attr_mapping = ``[``(``'``id``'``,` `'``id``'``,` <yakumo.mapper.NoopClass object `...``
| _hidden_methods = ``[``'``update``'``]``
| _json_resource_key = ``'``server``'``
| _json_resources_key = ``'``servers``'``
| _url_resource_path = ``'``/servers``'``
| _url_resource_list_path = ``'``/servers/detail``'``
Inherited from `base.Manager` (private): `_has_detail`, `_has_extra_attr`, `_id_attr`, `_update_method`

Properties | [hide private]
Inherited from `object`: `__class__`

Method Details | [hide private]

### _json2attr(self, json_params) | source code
Overrides: base.Manager._json2attr

### create(self, name=`'``__UNDEF__``'`, image=`'``__UNDEF__``'`, flavor=`'``__UNDEF__``'`, personality=`'``__UNDEF__``'`, disks=`'``__UNDEF__``'`, max_count=`'``__UNDEF__``'`, min_count=`'``__UNDEF__``'`, networks=`'``__UNDEF__``'`, security_groups=`'``__UNDEF__``'`, availability_zone=`'``__UNDEF__``'`, metadata=`'``__UNDEF__``'`, config_drive=`'``__UNDEF__``'`, key_pair=`'``__UNDEF__``'`, user_data=`'``__UNDEF__``'`) | source code
Create a new server Parameters: `name` (str) - name of the new server (required) `flavor` (yakumo.nova.v2.flavor.Resource) - Flavor object to use (required) `image` (yakumo.image.Resource) - Image object to use for ephemeral disk `key_pair` (yakumo.nova.v2.key_pair.Resource) - KeyPair object to use `networks` ([yakumo.network.Resource]) - list of networks or ones with tag and/or fixed IP `security_groups` ([yakumo.nova.v2.security_group.Resource]) - list of SecurityGroup object(s) to use `disks` ([dict]) - block device mapping `personality` (dict) - file path and the content to embed `max_count` (int) - the maximum number of server(s) to create `min_count` (int) - the minimun number of server(s) to create `availability_zone` (yakumo.availability_zone.Resource) - Availability Zone `metadata` (dict) - Metadata `config_drive` (bool) - config drive exists or not (bool) `user_data` (str) - content of a batch file (str) Returns: yakumo.nova.v2.server.Resource Created server Overrides: base.Manager.create

Class Variable Details | [hide private]

  ### _attr_mapping Value:
      [('id', 'id', mapper.Noop), ('name', 'name', mapper.Noop), ('access_ip
      v4', 'accessIPv4', mapper.Noop), ('access_ipv6', 'accessIPv6', mapper.
      Noop), ('addresses', 'addresses', mapper.Noop), ('host', 'OS-EXT-SRV-A
      TTR:host', mapper.Noop), ('networks', 'networks', mapper.Noop), ('disk
      s', 'block_device_mapping_v2', mapper.Noop), ('user_data', 'user_data'
      , mapper.Base64), ('progress', 'progress', mapper.Noop), ('status', 's
      tatus', mapper.Noop), ('task_state', 'OS-EXT-STS:task_state', mapper.N
      oop), ('created_at', 'created', mapper.DateTime), ('updated_at', 'upda
      ...