I'm getting a 403 Client Error when making an S3 connection on one of our production servers using the tinys3 python package. Any ideas? I think the credentials are right, as this script runs on my local machine without issue.
I'm getting the same issue on a test script I wrote to help debug this. Pasted below:
import tinys3 as s3
S3_ACCESS_KEY = "[redacted]"`
S3_SECRET_KEY = "[redacted]"
bucket = "test-bucket"
s3_image_prefix = "http://s3.amazonaws.com/" + bucket + "/"
conn = s3.Connection(S3_ACCESS_KEY, S3_SECRET_KEY, default_bucket=bucket)
conn.get('test_file.gif', bucket)
And the error:
requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: http://s3.amazonaws.com/test-bucket/test_file.gif