-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(toolkit): support multiple toolkit stacks in the same environment (…
…#1427) The `--toolkit-stack-name` option can be used to specify the name for the toolkit stack. However, since the the toolkit stack outputs had "Export"s, which must be unique within an environment, it was impossible to deploy multiple toolkit stacks. This change removes the "Export"s as they are actually not used or needed and also adds an integration test to verify that multiple toolkit stacks can be deployed into the same environment. `toolkitStackName` can also be specified in `cdk.json` or `~/.cdk.json`. Updated the toolkit documentation topic to describe this. Fixes #1416
- Loading branch information
Elad Ben-Israel
authored
Dec 27, 2018
1 parent
1dd56d4
commit 095da14
Showing
4 changed files
with
64 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
packages/aws-cdk/integ-tests/test-cdk-multiple-toolkit-stacks.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#!/bin/bash | ||
set -euo pipefail | ||
scriptdir=$(cd $(dirname $0) && pwd) | ||
source ${scriptdir}/common.bash | ||
# ---------------------------------------------------------- | ||
|
||
setup | ||
|
||
toolkit_stack_name_1="toolkit-stack-1-${RANDOM}" | ||
toolkit_stack_name_2="toolkit-stack-2-${RANDOM}" | ||
|
||
# deploy two toolkit stacks into the same environment (see #1416) | ||
cdk bootstrap --toolkit-stack-name ${toolkit_stack_name_1} | ||
cdk bootstrap --toolkit-stack-name ${toolkit_stack_name_2} | ||
|
||
# just check that the new stack exists | ||
aws cloudformation describe-stack-resources --stack-name ${toolkit_stack_name_1} | ||
aws cloudformation describe-stack-resources --stack-name ${toolkit_stack_name_2} | ||
|
||
# clean up | ||
aws cloudformation delete-stack --stack-name ${toolkit_stack_name_1} | ||
aws cloudformation delete-stack --stack-name ${toolkit_stack_name_2} | ||
|
||
echo "✅ success" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters