diff --git a/providers/dns/route53/route53.go b/providers/dns/route53/route53.go index 3c86b0b3..da881d63 100644 --- a/providers/dns/route53/route53.go +++ b/providers/dns/route53/route53.go @@ -25,6 +25,7 @@ type Config struct { PropagationTimeout time.Duration PollingInterval time.Duration HostedZoneID string + Client *route53.Route53 } // NewDefaultConfig returns a default configuration for the DNSProvider @@ -86,6 +87,10 @@ func NewDNSProviderConfig(config *Config) (*DNSProvider, error) { return nil, errors.New("route53: the configuration of the Route53 DNS provider is nil") } + if config.Client != nil { + return &DNSProvider{client: config.Client, config: config}, nil + } + retry := customRetryer{} retry.NumMaxRetries = config.MaxRetries sessionCfg := request.WithRetryer(aws.NewConfig(), retry)