Last active
October 13, 2015 04:24
-
-
Save timrchavez/191fa451516d5e5d4ce0 to your computer and use it in GitHub Desktop.
Switch Openstack clouds in your shell using os-client-config config -- I almost feel bad about this one ;-) To use: $(switch-cloud foo)
This file contains 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
alias switch-cloud='python -c "from __future__ import print_function;import os_client_config as c, sys; [print(\"export OS_%s=%s\" % (a.upper(), b)) for (a,b) in c.OpenStackConfig().get_one_cloud(sys.argv[1]).auth.iteritems()]"' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment