Direkt zum Inhalt

If I select the default branch (e.g., main) in CodePipeline but set the trigger filter to stage-*, which branch will the pipeline deploy—main or a stage-* branch?

0

Here, I'm using a code pipeline for the staging environment. Once the development environment is completed, a dynamic branch is created. The staging pipeline needs to use this dynamically created branch from development. When setting up the staging pipeline, I need to specify a default branch. However, at this point, the dynamic branch hasn't been created yet. So, I set the default branch to 'main' but configured the trigger to filter for branches following the 'stage-*'. My question is: which branch will the pipeline use for deployment – the default branch ('main') or the dynamically created 'stage-' branch?

gefragt vor einem Jahr282 Aufrufe
2 Antworten
2
Akzeptierte Antwort
  1. With Automatic Triggers: The pipeline will deploy the branch that matches stage-* and triggered the pipeline.
  2. With Manual Triggers: If manually triggered and no specific branch is provided, the pipeline will use the main branch by default.

Thus, in your case, when the stage-* branch is created and triggers the pipeline, the pipeline will deploy that stage-* branch, not the main branch.

AWS
EXPERTE
beantwortet vor einem Jahr
EXPERTE
überprüft vor einem Jahr
0

Thanks for the update

beantwortet vor einem Jahr

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.