New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Module does not work when running locally via Docker #26
Comments
You will need to update your yaml config to make sure the aws credentials are being used. In your /app/_config/app.yml or whatever yml config file you are using for your project, add something like the following -
By default it is expecting you to be on some type of amazon system but outside if you have the following in your config you will be all set. One thing you can do is also setup a separate yml file that is ignored from git like your .env file that contains this info as well separate from your main apps config (this is what we do locally) |
This worked! Thank you @obj63mc for the lightning fast response ⚡️ Is there any downside to leaving this |
Since I host on heroku and not amazon such as say on EC2, I am not sure if the environment variables are set for AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY by default, if those two variables are not set then you would probably get a connection error when trying to access the bucket. If those environment variables are set at your hosting provider, you can definitely leave it checked in. The main thing is that when hosting on amazon EC2 by example, as long as you have your servers configured to your S3 buckets then you shouldn't need to specify that information. |
I've installed this module on a 4.3 site and I'm stuck at the following error. I cannot run dev/build... this is the error I get when I try to do that:
[Emergency] Uncaught Aws\Exception\CredentialsException: Error retrieving credentials from the instance profile metadata server. (cURL error 28: Connection timed out after 1001 milliseconds (see http://curl.haxx.se/libcurl/c/libcurl-errors.html))
After some googling it seems that the module is behaving as-if installed on an EC2 instance... the error seems to indicate that it's trying to get information about the EC2 instance it's running on but I'm running it locally via docker.
Things I have tried:
~/.aws/credentials file
with the following contents:docker-compose.yml
Nothing I do seems to change how the client is being created... please advise if there's something I'm doing wrong or something missing from the docs (highly unlikely).
The text was updated successfully, but these errors were encountered: