Skip to content
This repository has been archived by the owner on Apr 30, 2023. It is now read-only.

Deploying multiple Stacks #48

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Deploying multiple Stacks #48

wants to merge 1 commit into from

Conversation

cdalar
Copy link

@cdalar cdalar commented Jan 3, 2022

I would like to deploy multiple Stacks. cdk deploy allows to you do that . like
cdk deploy TestStack Test2Stack

so by removing the double quotes should fix it. Didn't tested though.

So when I put multiple stacks on input.cdk_stack, it should work.

@bogdannazarenko
Copy link

I think this would not work with asterisks cdk deploy 'production-*'. Right?

@danieldspx
Copy link

danieldspx commented Oct 12, 2022

I ran into the same problem, looked into the CDK internals and it uses minimatch under the hood as you can see here. With that, you can turn what you pass to the cdk_stack input into a glob expression.

For my case I had several stacks but I wanted to deploy only 2 (lets call them stackA and stackB). So my glob expression became @(stackA|stackB). This works exactly as I expect since the @ means Match exactly one item from the group.

@cdalar If this solves your issue, consider closing this PR.

**One other thing to notice is that your PR might break existing implementarions of people using the "*" glob expression.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants