Created
August 27, 2015 22:01
-
-
Save hughdbrown/de183a06cb889f6d19e1 to your computer and use it in GitHub Desktop.
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
import ConfigParser | |
import os.path | |
def get_creds(): | |
botofile = os.path.expanduser("~/.boto") | |
with open(botofile) as f: | |
c = ConfigParser.ConfigParser() | |
c.readfp(f) | |
return tuple( | |
c.get("Credentials", key) | |
for key in ("aws_access_key_id", "aws_secret_access_key") | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment