SHARE
TWEET

glance get size of image

a guest Dec 3rd, 2015 21 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. from glanceclient import Client
  2.  
  3. OS_IMAGE_ENDPOINT = 'http://16.164.217.124:9292'
  4. OS_AUTH_TOKEN = '6aec4894efbc474d93b6ed139d023ad0'
  5.  
  6. glance = Client('1', endpoint=OS_IMAGE_ENDPOINT, token=OS_AUTH_TOKEN)
  7. images = glance.images.list()
  8. print images
  9. for image in images:
  10.     image_dict = image.to_dict()
  11.     print image_dict['size']
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top