[Openstack-operators] how to get glance images for a specific tenant with the openstack client ?

Thomas Blank - Hetzner Online AG thomas.blank at hetzner.de
Mon Jan 25 15:49:34 UTC 2016


Hey there,

have you tried using the --property option of the openstack-client?
You could filter images by their owner (openstack_project_id or name).

"openstack image list --property owner=[openstack_project_id]"

see:

http://docs.openstack.org/developer/python-openstackclient/command-objects/image.html#cmdoption-image-list--property

thomas blank,



On 25.01.2016 16:19, Saverio Proto wrote:
> Hello there,
> 
> I need to delete some users  and tenants from my public cloud. Before
> deleting the users and tenants from keystone, I need to delete all the
> resources in the tenants.
> 
> I am stucked listing the glance images uploaded in a specific tenant.
> I cannot find the way, I always get either all the images in the
> system, or just the ones of the active OS_TENANT_NAME
> 
> openstack help image list
> usage: openstack image list [-h] [-f {csv,json,table,value,yaml}] [-c COLUMN]
>                             [--max-width <integer>] [--noindent]
>                             [--quote {all,minimal,none,nonnumeric}]
>                             [--public | --private | --shared]
>                             [--property <key=value>] [--long]
>                             [--sort <key>[:<direction>]]
> 
> As a work around I can add a user with member role in the tenant, and
> list in that way ... but, there is really no way to specifiy
> --tenant=id in the openstack client ?
> 
> thank you
> 
> Saverio
> 
> _______________________________________________
> OpenStack-operators mailing list
> OpenStack-operators at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-operators
> 



More information about the OpenStack-operators mailing list