I'm trying to use boto to automate some operations on amazon ec2, but I can't even run the most simple example without getting:
boto.exception.EC2ResponseError: EC2ResponseError: 403 Forbidden
My code is:
import boto.ec2
conn = boto.ec2.connect_to_region("us-west-2",
aws_access_key_id='CENSOREDCENSORED',
aws_secret_access_key='CENSOREDCENSOREDCENSOREDCENSORED')
instances = conn.get_all_instances()
I'm sure that aws_access_key_id and aws_secret_access_key are correct, because I use them in the CLI Tools and I can succesfully run ec2-describe-instances
I'm using boto version: 2.35.1
Aucun commentaire:
Enregistrer un commentaire