CodeSleeve / laravel-stapler

Stapler-based file upload package for the Laravel framework.
MIT License
556 stars 109 forks source link

Can't upload to Amazon s3 Error executing "CreateBucket" #128

Open Punksolid opened 7 years ago

Punksolid commented 7 years ago

I have it working on my localhost but in production even if I have the same configurations with exactly the same API_KEY and SECRET_KEY doesn't work. I tried putting a bucket that I created manually and another that doesn't exists, none of them worked. I think it is maybe a bug with aws-sdk-php but I don't have any idea what could be wrong.

Then, the response sends this message:

""" Error executing "CreateBucket" on "http://rsbucketalphad4.s3-us-west-2.amazonaws.com/"; AWS HTTP error: Client error:PUT http://rsbucketalphad4.s3-us-west-2.amazonaws.com/resulted in a403 Forbidden` response:\n <?xml version="1.0" encoding="UTF-8"?>\n

AccessDeniedAccess DeniedDCBF25 (truncated...)\n AccessDenied (client): Access Denied - \n AccessDeniedAccess DeniedDCBF25BF8A4D35B8J/1zgLRO/1jSux0U2yyEW3eH24dYFJvgqD29w7maVlWzY7z5H0h7GQRThcUjCCSvTQY2PN4AxCI= """`
Punksolid commented 7 years ago

Don't know what's the error though, but I found that actually both request were pointing to different controllers, as I see there I have the same code in both. So now I'm pointing to the endpoint that works.

Punksolid commented 7 years ago

The error persists, it wasn't the endpoint. It is exactly the same code that I have in localhost where it works. Sorry for posting too many messages.