In AWS Bahrain region (me-south-1), establishing an EKS cluster with cdk has been failed,
with this error message:
"AWS was not able to validate the provided access credentials"
While it succeeded in AWS Seoul region (ap-northeast-2)
It seems to be related to the STS endpoint problem.
Reproduction Steps
My Stack contains:
import * as cdk from '@aws-cdk/core'
import * as eks from '@aws-cdk/aws-eks'
export class EksStack extends cdk.Stack {
constructor(scope: cdk.Construct, id: string, props: cdk.StackProps) {
super(scope, id, props)
new eks.Cluster(this, 'cluster', {})
}
}
// ...
const app = new cdk.App()
new EksStack(app, 'eks', { env: { region: 'me-south-1' } })
app.synth()
When I run it:
It is aborted with an error like:
ERROR: AWS was not able to validate the provided access credentials
What did you expect to happen?
The stack should be successfully deployed.
What actually happened?
Failed to create resource. The security token included in the request is invalid
Logs: /aws/lambda/eks-awscdkawseksClusterReso-OnEventHandler42BEBAE0-4QPUO1YX3M0U
Failed to delete resource. The security token included in the request is invalid
Logs: /aws/lambda/eks-awscdkawseksClusterRe-IsCompleteHandler7073F4D-ER83I62J68AJ
The stack deployment was aborted at this stage:
|
const resource = this._clusterResource = new ClusterResource(this, 'Resource', { |
|
name: this.physicalName, |
|
environment: props.clusterHandlerEnvironment, |
|
roleArn: this.role.roleArn, |
|
version: props.version.version, |
|
resourcesVpcConfig: { |
|
securityGroupIds: [securityGroup.securityGroupId], |
|
subnetIds, |
|
}, |
|
...(props.secretsEncryptionKey ? { |
|
encryptionConfig: [{ |
|
provider: { |
|
keyArn: props.secretsEncryptionKey.keyArn, |
|
}, |
|
resources: ['secrets'], |
|
}], |
|
} : {} ), |
|
endpointPrivateAccess: this.endpointAccess._config.privateAccess, |
|
endpointPublicAccess: this.endpointAccess._config.publicAccess, |
|
publicAccessCidrs: this.endpointAccess._config.publicCidrs, |
|
secretsEncryptionKey: props.secretsEncryptionKey, |
|
vpc: this.vpc, |
|
subnets: placeClusterHandlerInVpc ? privateSubents : undefined, |
|
}); |
Environment
- CDK CLI Version : 1.94.1
- Framework Version:
- Node.js Version: 14.16.0
- OS : macOS BigSur 11.2.3(20D91)
- Language (Version): TypeScript 4.2.3
Other
This is 🐛 Bug Report
In AWS Bahrain region (me-south-1), establishing an EKS cluster with cdk has been failed,
with this error message:
"AWS was not able to validate the provided access credentials"While it succeeded in AWS Seoul region (ap-northeast-2)
It seems to be related to the STS endpoint problem.
Reproduction Steps
My Stack contains:
When I run it:
It is aborted with an error like:
What did you expect to happen?
The stack should be successfully deployed.
What actually happened?
The stack deployment was aborted at this stage:
aws-cdk/packages/@aws-cdk/aws-eks/lib/cluster.ts
Lines 1007 to 1030 in 77ce45d
Environment
Other
This is 🐛 Bug Report