-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Closed
Labels
@aws-cdk/pipelinesCDK Pipelines libraryCDK Pipelines librarybugThis issue is a bug.This issue is a bug.effort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortneeds-triageThis issue or PR still needs to be triaged.This issue or PR still needs to be triaged.p1
Description
Stages deployed using pipelines do not support renamed bootstrap stacks. When a stage is synthesized for a different region or account, The /cdk-bootstrap/${Qualifier}/value
SSM parameter is not used. Instead the synthesizer looks for the default bootstrap stack with the default name. Non-pipeline stage deployments support random bootstrap stack names after the CDK was updated in version 1.87.0
Reproduction Steps
- Deploy the bootstrap stack to target regions using StackSets or using the non-default name
- Do not update the context file with the bootstrap stack name
- Create a CDK pipeline with a stage to a different region from the current one
- Deploy the pipeline
- Failure
What did you expect to happen?
A successful deployment of the pipeline to the target account
What actually happened?
Waiting for stack CDKToolkit to finish creating or updating...
Call failed: describeStacks({"StackName":"CDKToolkit"}) => Stack with id CDKToolkit does not exist (code=ValidationError)
Stack CDKToolkit does not exist
The environment aws://123456789012/us-east-2 doesn't have the CDK toolkit stack (CDKToolkit) installed. Use cdk bootstrap "aws://123456789012/us-east-2" to setup your environment for use with the toolkit.
❌ cross-region-stack-123456789012:us-east-2 (pipeline-stack-support-us-east-2) failed: Error: pipeline-stack-support-us-east-2: publishing assets requires bootstrap stack version '1', no bootstrap stack found. Please run 'cdk bootstrap'.
at CloudFormationDeployments.validateBootstrapStackVersion (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\lib\api\cloudformation-deployments.ts:286:13)
at CloudFormationDeployments.deployStack (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\lib\api\cloudformation-deployments.ts:157:16)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at CdkToolkit.deploy (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\lib\cdk-toolkit.ts:180:24)
at initCommandLine (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\bin\cdk.ts:204:9)
pipeline-stack-support-us-east-2: publishing assets requires bootstrap stack version '1', no bootstrap stack found. Please run 'cdk bootstrap'.
Error: pipeline-stack-support-us-east-2: publishing assets requires bootstrap stack version '1', no bootstrap stack found. Please run 'cdk bootstrap'.
at CloudFormationDeployments.validateBootstrapStackVersion (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\lib\api\cloudformation-deployments.ts:286:13)
at CloudFormationDeployments.deployStack (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\lib\api\cloudformation-deployments.ts:157:16)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at CdkToolkit.deploy (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\lib\cdk-toolkit.ts:180:24)
at initCommandLine (C:\Users\my_user\AppData\Roaming\npm\node_modules\aws-cdk\bin\cdk.ts:204:9)
Environment
- **CDK CLI Version : ** 1.87.0 (build be72c59)
- Framework Version: ??
- **Node.js Version: ** v12.13.0
- OS : Windows 10 (19042.746)
- Language (Version): TypeScript (3.9.7)
Other
The original renaming bootstrap stack feature was tracked here: #11420 and resolved here: #12594
This is 🐛 Bug Report
KevinHuang40856 and anikettstiwari
Metadata
Metadata
Assignees
Labels
@aws-cdk/pipelinesCDK Pipelines libraryCDK Pipelines librarybugThis issue is a bug.This issue is a bug.effort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortneeds-triageThis issue or PR still needs to be triaged.This issue or PR still needs to be triaged.p1