-
Notifications
You must be signed in to change notification settings - Fork 290
Configure the AWS Client
Pablo Cantero edited this page Jun 27, 2017
·
4 revisions
There are a few ways to configure the AWS client:
- Ensure the
AWS_ACCESS_KEY_IDandAWS_SECRET_ACCESS_KEYenv vars are set. - Create a
~/.aws/credentialsfile. - Set
Aws.config[:credentials]orShoryuken.sqs_client = Aws::SQS::Client.new(...)from Ruby code (e.g. in a Rails initializer) - Use the Instance Profiles feature. The IAM role of the targeted machine must have an adequate SQS Policy.
You can read about these in more detail here.
If you need to change specific SQS client options, such as wait_time_seconds (SQS Long Polling), you can do it through an initializer as follows:
Shoryuken.sqs_client_receive_message_opts = {
wait_time_seconds: ...
}