mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
ROUTE53: Add AWS_PROFILE functionality (#567)
* Add AWS_PROFILE functionality for Route53 provider * Document named profiles authentication option for Route53
This commit is contained in:
committed by
Tom Limoncelli
parent
b928e7c22f
commit
0f396cd135
@ -36,6 +36,13 @@ $ export AWS_SESSION_TOKEN=ZZZZZZZZ
|
|||||||
}
|
}
|
||||||
{% endhighlight %}
|
{% endhighlight %}
|
||||||
|
|
||||||
|
Alternatively if you want to used [named profiles](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html) you need to export the following variables
|
||||||
|
|
||||||
|
```
|
||||||
|
$ export AWS_SDK_LOAD_CONFIG=1
|
||||||
|
$ export AWS_PROFILE=ZZZZZZZZ
|
||||||
|
```
|
||||||
|
|
||||||
You can find some other ways to authenticate to Route53 in the [go sdk configuration](https://docs.aws.amazon.com/sdk-for-go/v1/developer-guide/configuring-sdk.html).
|
You can find some other ways to authenticate to Route53 in the [go sdk configuration](https://docs.aws.amazon.com/sdk-for-go/v1/developer-guide/configuring-sdk.html).
|
||||||
|
|
||||||
## Metadata
|
## Metadata
|
||||||
|
@ -47,7 +47,7 @@ func newRoute53(m map[string]string, metadata json.RawMessage) (*route53Provider
|
|||||||
if keyID != "" || secretKey != "" {
|
if keyID != "" || secretKey != "" {
|
||||||
config.Credentials = credentials.NewStaticCredentials(keyID, secretKey, tokenID)
|
config.Credentials = credentials.NewStaticCredentials(keyID, secretKey, tokenID)
|
||||||
}
|
}
|
||||||
sess := session.New(config)
|
sess := session.Must(session.NewSession(config))
|
||||||
|
|
||||||
var dls *string = nil
|
var dls *string = nil
|
||||||
if val, ok := m["DelegationSet"]; ok {
|
if val, ok := m["DelegationSet"]; ok {
|
||||||
|
Reference in New Issue
Block a user