[Openstack] Set quotas

Kevin L. Mitchell kevin.mitchell at rackspace.com
Tue Sep 11 18:47:15 UTC 2012


On Tue, 2012-09-11 at 13:20 -0500, Guillermo Alvarado wrote:
> I want to set the quotas of a tenant useing the python API. Which API
> I need to use? I am trying with the nova client but hte documentation
> is not complete and the python docs are
> broken, http://packages.python.org/python-novaclient/

>From the novaclient CLI, you have the quota_show ("List the quotas for a
tenant."), quota_defaults ("List the default quotas for a tenant.") and
quota_update ("Update the quotas for a tenant.").  (There are
corresponding subcommands for quota classes, if you're using those, but
you're probably not.)

>From the actual Python API, you want client.quotas.get(<tenant ID>),
client.quotas.defaults(<tenant ID>), and client.quotas.update(<tenant
ID>, **kwargs).
-- 
Kevin L. Mitchell <kevin.mitchell at rackspace.com>





More information about the Openstack mailing list