setting up aws credential in flask
Create a file called settings.py
, place your keys inside of it, load it with import settings
and then reference them as settings.AWS_ACCESS_KEY_ID
.
However, from a security perspective you should really use IAM Roles instead. They automatically provide temporary keys to each EC2 instance.
http://docs.aws.amazon.com/IAM/latest/UserGuide/roles-usingrole-ec2instance.html