You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to (route53/list-hosted-zones (:client-opts this))
Where (:client-opts this) looks like this:
{:endpoint "cn-northwest-1"}
produces :
INFO c.a.i.DefaultServiceEndpointBuilder - {route53, cn-northwest-1} was not found in region metadata, trying to construct an endpoint using the standard pattern for this region: 'route53.cn-northwest-1.amazonaws.com.cn'.
followed by:
Unable to execute HTTP request: route53.cn-northwest-1.amazonaws.com.cn
This would appear to be because Route53 endpoint in China is actually route53.amazonaws.com.cn
Changing client-opts to be
{:endpoint "route53.amazonaws.com.cn"}
results in:
com.amazonaws.services.route53.model.AmazonRoute53Exception: The security token included in the request is invalid.
(I'm assuming because it needs to know which region to use for IAM).
But trying to supply region as well in the client-opts:
Actually, going back through my cmds, I can see I tried get-hosted-zone using my AWS_PROFILE, not list-hosted-zones.
list-hosted-zones doesn't work with my profile (despite it being admin), so maybe this just isn't a thing in China?
EDIT: So, it does work in China but you have to supply the region as well as the profile:
aws route53 list-hosted-zones --profile china
An error occurred (InvalidClientTokenId) when calling the ListHostedZones operation: The security token included in the request is invalid.
Using version 0.3.152
Trying to
(route53/list-hosted-zones (:client-opts this))
Where (:client-opts this) looks like this:
produces :
INFO c.a.i.DefaultServiceEndpointBuilder - {route53, cn-northwest-1} was not found in region metadata, trying to construct an endpoint using the standard pattern for this region: 'route53.cn-northwest-1.amazonaws.com.cn'.
followed by:
Unable to execute HTTP request: route53.cn-northwest-1.amazonaws.com.cn
This would appear to be because Route53 endpoint in China is actually route53.amazonaws.com.cn
Changing client-opts to be
results in:
com.amazonaws.services.route53.model.AmazonRoute53Exception: The security token included in the request is invalid.
(I'm assuming because it needs to know which region to use for IAM).
But trying to supply region as well in the client-opts:
Still results in:
com.amazonaws.services.route53.model.AmazonRoute53Exception: The security token included in the request is invalid.
(I'm using AWS_PROFILEs and have checked that the credentials I'm using have access (they're admin).
I can see that cn-northwest-1 exists in aws-java-sdk-core/com.amazonaws/regions/Regions
And in com.amazonaws.services.route53.model/VPCRegion
So am assuming that for China, you need to override the endpoint and use the region provided?
The text was updated successfully, but these errors were encountered: