Skip to content

Commit

Permalink
Merge pull request #3 from fterrag/kube2iam-workaround
Browse files Browse the repository at this point in the history
  • Loading branch information
fterrag authored May 17, 2018
2 parents e8e4f90 + fa47723 commit 6104891
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmd/simplesqsd/simplesqsd.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,16 +71,16 @@ func main() {
WithRegion(c.QueueRegion).
WithHTTPClient(httpClient)

sqsSvc := sqs.New(awsSess, sqsConfig)

// To workaround a kube2iam issue, expire credentials every minute.
go func() {
for {
sqsConfig.Credentials.Expire()
sqsSvc.Config.Credentials.Expire()
time.Sleep(time.Minute)
}
}()

sqsSvc := sqs.New(awsSess, sqsConfig)

wConf := supervisor.WorkerConfig{
QueueURL: c.QueueURL,
QueueMaxMessages: c.QueueMaxMessages,
Expand Down

0 comments on commit 6104891

Please sign in to comment.