Created
April 29, 2014 19:47
-
-
Save ziadsawalha/d77d9e6db4a386b7677a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
context = pyrax.create_context(id_type="rackspace", username=username, tenant_id=tenant_id) | |
context.auth_with_token(auth_token, tenant_id=tenant_id) | |
if "compute" in context.services: | |
servers = pyrax.connect_to_cloudservers(context=identity, region=region) | |
print servers.list() | |
else: | |
print "You don't have a 'compute' endpoint in your catalog" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment