cc1
v2.1
CC1 source code docs
|
Functions | |
def | check_resources |
Checks if there is enough resources to start a farm. | |
def | create |
Method creates new caller's Farm. | |
def | destroy |
Destroys specified caller's farm. | |
def | get_by_id |
Returns requested Farm. | |
def | get_list |
Returns list of the caller's farms. | |
def | save_and_shutdown |
Safely saves and shutdowns Farm's Head. |
def src.cm.views.user.farm.check_resources | ( | caller_id, | |
count, | |||
head_template_id, | |||
template_id | |||
) |
Checks if there is enough resources to start a farm.
http_request | (HttpRequest ) |
caller_id | (POST int ) |
count | (POST int ) |
head_template_id | (POST int ) |
template_id | (POST int ) |
Boolean
) def src.cm.views.user.farm.create | ( | caller_id, | |
name, | |||
description, | |||
image_id, | |||
head_template_id, | |||
worker_template_id, | |||
public_ip_id, | |||
iso_list, | |||
disk_list, | |||
vnc, | |||
groups, | |||
count | |||
) |
Method creates new caller's Farm.
http_request | (HttpRequest ) |
caller_id | (POST int ) |
name | (POST string ) Farm's name |
description | (POST string ) |
image_id | (POST int ) image for WNs and Head |
head_template_id | (POST int ) Head's template |
worker_template_id | (POST int ) Worker Node's template |
public_ip_id | (POST int ) Worker Node's template |
iso_list | (POST list ) |
disk_list | (POST list ) |
vnc | (POST list ) |
groups | (POST list ) |
count | (POST int ) number of Worker Nodes |
CMException('farm_create') |
def src.cm.views.user.farm.destroy | ( | caller_id, | |
farm_id | |||
) |
Destroys specified caller's farm.
http_request | (HttpRequest ) |
caller_id | (POST int ) |
farm_id | (POST int ) destroyed farm's id |
def src.cm.views.user.farm.get_by_id | ( | caller_id, | |
farm_id | |||
) |
Returns requested Farm.
http_request | (HttpRequest ) |
caller_id | (POST int ) |
farm_id | (POST int ) id of the requested Farm |
dict
) Farm.dict property of the requested Farm def src.cm.views.user.farm.get_list | ( | caller_id | ) |
Returns list of the caller's farms.
http_request | (HttpRequest ) |
caller_id | (POST int ) |
list(dict)
) data of the requested Farms def src.cm.views.user.farm.save_and_shutdown | ( | caller_id, | |
farm_id, | |||
name, | |||
description | |||
) |
Safely saves and shutdowns Farm's Head.
http_request | (HttpRequest ) |
caller_id | (POST int ) |
farm_id | (POST int ) |
name | (POST string ) |
description | (POST string ) |
src.cm.manager.farm.utils.save_and_shutdown()
)