Skip to content

Commit

Permalink
Send debug logging to stderr
Browse files Browse the repository at this point in the history
  • Loading branch information
Joshua Delsman committed Sep 19, 2017
1 parent 2112bad commit f73e587
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
6 changes: 5 additions & 1 deletion internal/features/step_definitions.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,11 @@ import (
)

func getService() *route53.Route53 {
config := aws.Config{}
config := aws.Config{
Logger: aws.LoggerFunc(func(args ...interface{}) {
fmt.Fprintln(os.Stderr, args...)
}),
}
// ensures throttled requests are retried
config.MaxRetries = aws.Int(100)
return route53.New(session.New(), &config)
Expand Down
3 changes: 3 additions & 0 deletions util.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ func getConfig(c *cli.Context) (*aws.Config, error) {
config := aws.Config{
Endpoint: &endpoint,
Region: &region,
Logger: aws.LoggerFunc(func(args ...interface{}) {
fmt.Fprintln(os.Stderr, args...)
}),
}
if profile != "" {
config.Credentials = credentials.NewSharedCredentials("", profile)
Expand Down

0 comments on commit f73e587

Please sign in to comment.