5

Trying to fetch all the servers registered to our RackSpace account under a certain tag.

Using RackSpace's Python bindings for OpenStack, pyrax, we haven't found a way to do this. Is there some way to achieve it with that library, or is there another Python library that would do that?

Thanks very much!

Kyle Kelley
  • 13,804
  • 8
  • 49
  • 78
Juan Carlos Coto
  • 11,900
  • 22
  • 62
  • 102
  • Just as a complement: you can also use nova to access the API (http://developer.rackspace.com/blog/getting-started-using-python-novaclient-to-manage-cloud-servers.html), but anyway, if the API does not have tags information, it won't help. – Daniel Cukier Apr 22 '14 at 13:36

2 Answers2

8

I'm the author of pyrax. Currently there is no way to access tag information via pyrax, as that information is not returned from the API. But I agree that that would be useful information, so I'm talking to the various teams involved to see what might be possible. When I hear something I'll follow up here.

Ed Leafe
  • 130
  • 4
  • Excellent! Much better answer than I expected. Thanks so much! – Juan Carlos Coto Mar 01 '13 at 16:20
  • I would be interested if you have any new information on this? adding a new server with tags in the control panel doesn't appear to populate the metadata within the api at time of writing still. – davidcollom Oct 08 '13 at 13:30
  • As of this posting, Rackspace still has not added tag support to the API. There is a UserVoice request for that feature here: https://feedback.rackspace.com/forums/71021-product-feedback/suggestions/5709402-expose-cloud-server-tags-through-the-api – Joseph Sturtevant Sep 28 '14 at 01:16
0

It looks to me like the metadata for cloud servers is currently available, which appears to contain the labels of the server.

You could list servers using pxrax and filter on the metadata.