jenkinsci/aws-sqs-plugin

Using the EC2 instance's IAM role instead of specifying my AWS Acess Key in Jenkins

Closed this issue · 2 comments

I am running Jenkins in a Docker container inside an EC2 Instance in AWS. I feel that specifying my AWS Access Key in Jenkins is a little insecure and feels like a workaround instead of the desired behavior.

However I tried not specifying my access key and kind of hoped Jenkins would use the instance's IAM role, but instead it says it can't find my SQS Queue.

Is there a way of forcing Jenkins to use the instance's IAM role instead of requiring my access key to be stored in it?

Thanks!

Hi @darthcabs - we are using the instance's IAM role in our environment.
In the system configuration (Amazon SQS queue), (for each of your queues) leave the Credentials pull-down at - none -. When you click the Test access button, it will say No credentials set, but it works in the job.

@abeeskau you're absolutely right!

Thanks very much!