-
Notifications
You must be signed in to change notification settings - Fork 223
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
Remove explicit call to use credentials from environment variables #175
Conversation
pubsub/aws/aws.go
Outdated
Region: &cfg.Region, | ||
Endpoint: cfg.EndpointURL, | ||
} | ||
if creds != nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If creds
is already nil
then setting it into a nil
awsConfig.Credentials
as nil won't have any effect. With that in mind, I think we can drop this if
statement and use the prior, 1 liner for sns.New
, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I wasn't clear before, but that's what I meant: dropping the else
block should be the only change needed in this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure, done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✂️! 🌯!
For background, we run our application in a k8s container with an AWS role with SQS & SNS permissions already configured. We've been using a gizmo fork that doesn't configure credentials without trouble for the last few months.