Commit f1182ddc authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #39855 from justinsb/dns_logging

Automatic merge from submit-queue route53: configure verbose authentication errors Otherwise we get an error message which is confusingly written on authentication failures. Probably blocked on #39854
parents b437787a 66640c78
......@@ -20,6 +20,7 @@ package route53
import (
"io"
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/request"
"github.com/aws/aws-sdk-go/aws/session"
"github.com/aws/aws-sdk-go/service/route53"
......@@ -53,7 +54,13 @@ func route53HandlerLogger(req *request.Request) {
func newRoute53(config io.Reader) (*Interface, error) {
// Connect to AWS Route53 - TODO: Do more sophisticated auth
svc := route53.New(session.New())
awsConfig := aws.NewConfig()
// This avoids a confusing error message when we fail to get credentials
// e.g. https://github.com/kubernetes/kops/issues/605
awsConfig = awsConfig.WithCredentialsChainVerboseErrors(true)
svc := route53.New(session.New(), awsConfig)
// Add our handler that will log requests
svc.Handlers.Sign.PushFrontNamed(request.NamedHandler{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment