I have two stacks connecting to same repo `abc` bu...
# pulumi-deployments
s
I have two stacks connecting to same repo
abc
but with different branch in the settings. stack 1:
qa
branch in
abc
repo stack 2:
main
branch in
abc
repo Now, every time I create PR for qa and merge it.
pulumi preview
and
pulumi up
triggers both stack to run. Am I doing anything wrong here? I want want stack 1 to run when changing
qa
branch and only run stack 2 when changing
main
branch.
l
Would you mind giving a little bit more detail?
Now, every time I create PR for qa and merge it.
What are the source and destination branches for this PR?
pulumi preview
and
pulumi up
triggers both stack to run.
A preview and up are triggered on both stack1 and stack2?
s
Source: feat-1 Destination: qa this will trigger both stack 1 and 2 to run preview and up
l
I have just tried to reproduce this and was unable to. What I did: • stack
main
with deployment settings on branch
main
• stack
patch
with deployment settings on branch patch • create a new branch
patch2
and open a PR to merge into
patch
This only resulted in a preview deployment on stack
patch
I wonder if there is more detail you could provide on your setup.
Here is what I did observe: If I have stacked PRs open IE: • PR open against
main
branch from
patch
• PR open against
patch
branch from
patch2
If I merge the second PR, it triggers an update on stack
patch
- and a preview deployment on stack
main
This is expected because the first open PR receives new commits when the
patch2
PR is merged.
If you have step by step instructions, or a gif that you could share, that would greatly help.