aws-cdk-local: latest cdklocal/localstack fails to bootstrap
I upgraded cdklocal and localstack
I’m running localstack on Windows 10 . Below are the versions of the tools
$ cdklocal --version
1.77.0 (build a941c53)
$ docker images | grep localstack
localstack/localstack latest 25b151909437 58 minutes ago 638MB
$ localstack --version
0.12.2
I have started localstack by running
$ localstack start
Then when I run
$ cdklocal bootstrap
I get the following errors
⏳ Bootstrapping environment aws://000000000000/eu-central-1...
CDKToolkit: creating CloudFormation changeset...
0/3 | 14:00:48 | REVIEW_IN_PROGRESS | AWS::CloudFormation::Stack | CDKToolkit User Initiated
0/3 | 14:00:48 | CREATE_IN_PROGRESS | AWS::CloudFormation::Stack | CDKToolkit
0/3 | 14:00:48 | UPDATE_IN_PROGRESS | AWS::CloudFormation::Stack | CDKToolkit
0/3 | 14:00:48 | UPDATE_COMPLETE | AWS::CloudFormation::Stack | CDKToolkit
0/3 | 14:00:48 | CREATE_COMPLETE | AWS::CloudFormation::Stack | CDKToolkit
0/3 | 14:00:48 | CREATE_COMPLETE | AWS::CloudFormation::Stack | CDKToolkit
0/3 | 14:00:48 | CREATE_FAILED | AWS::CloudFormation::Stack | CDKToolkit
❌ Environment aws://000000000000/eu-central-1 failed bootstrapping: Error: The stack named CDKToolkit failed to deploy: CREATE_FAILED
at Object.waitForStackDeploy (C:\Users\lwong1\.npm-packages\node_modules\aws-cdk\lib\api\util\cloudformation.ts:307:11)
at processTicksAndRejections (node:internal/process/task_queues:93:5)
at Object.deployStack (C:\Users\lwong1\.npm-packages\node_modules\aws-cdk\lib\api\deploy-stack.ts:283:26)
at C:\Users\lwong1\.npm-packages\node_modules\aws-cdk\lib\cdk-toolkit.ts:358:24
at async Promise.all (index 0)
at CdkToolkit.bootstrap (C:\Users\lwong1\.npm-packages\node_modules\aws-cdk\lib\cdk-toolkit.ts:355:5)
at initCommandLine (C:\Users\lwong1\.npm-packages\node_modules\aws-cdk\bin\cdk.ts:201:9)
The stack named CDKToolkit failed to deploy: CREATE_FAILED
Prior to upgrading localstack it was still working. But perhaps this issue has the same cause as https://github.com/localstack/aws-cdk-local/issues/5 ?
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 27 (6 by maintainers)
Thanks for the update @Tehnix @denisdifazio @sbassin . We just did a quick test with the versions specified above (
aws-cdk-local@1.65.2
,aws-cdk@1.81.0
), and it seems to be working with latest. Can you please do adocker pull localstack/localstack
and give it another try with thelatest
Docker image?What are the error logs you’re seeing - is it the same message as @denisdifazio posted above:
Unable to determine the default AWS account: 404:
…? Can you please share a minimal example (e.g., as a small project in a Github repo) to help reproduce this issue? Thanks for your help@whummer awesome, I just tested and with latest and aws-cdk version 1.81.0 (build 6ef67c7) the whole flow worked 😃
Just wanted to also say thanks for all the effort y’all are doing! Especially responding on weekends like this 😅
I’m having a very similar issue, though with different output. Also on the latest localstack, but I’m on
1.78.0
ofcdklocal
.When I
cdklocal bootstrap
, I get:When I
cdklocal bootstrap aws://000000000000/us-east-1
like @guoliang, I get:This was working recently with
1.76.0
. The only change that stood out to me as a possible breaking one between the two versions of CDK was https://github.com/aws/aws-cdk/pull/11966, but I can’t find anything in that PR itself that looks like it would cause this problem. Though thataws-cdk/lib/api/aws-auth/sdk-provider.ts:149:46
is part of the change set.Edit More Context: FWIW, my local I have in my
config
file:and in my
credentials
file:This is also failing in my CI environment where I use environment variables:
Using localstack latest (0.12.6) when CDK attempts to lookup default account ID from STS, localstack outputs:
Followed the advice, all working now 😊
@whummer Yep, it’s working with the latest release. Thanks very much! 👍
@sbassin Perhaps you may need to clean the existing state in your
~/.cdk/...
or localcdk.out
folder…?