Teamcity checkout rules / VCS root branch specification
Hi,
My understanding is that if there 5 branches in bitbucket repo as A,B,C,D,E. And if I specify "A" in the default branch field, and B,C,D and E in branch specification field. Then that build can be build using any of the branches specified during the build time from the drop down list.
And if directory structure is same for all the branches , then in checkout rules i can define the rule that applies for all the branches.
But weird thing is that when I am trying to do the build by selecting specific branch, temacity is not checking out the code from that branch but from the default branch that "A".
I also tried unchecking the check box for "allow build on default branch" but anyways it checking out from the default branch.
However when I changed the default branch value to branch which I wanted to checkout from it is doing fine.
This concludes that branch specification is not working, is it a bug?
TeamCity version is 2017.1.1
Please sign in to leave a comment.
Hi,
branch specification is a thoroughly tested feature, we use it everywhere, so we are certain it works. There has to be something else happening here. We might need to check the build logs, check how your branch specification is set up, how the checkout rules are set up and what the results are, but it should definitely work. Please collect screenshots of all those configuration options, collect build logs of wrongly produced builds, then send it to us using the submit a request button above.
Hi Denis,
Thanks for the reply. Please find the attached snaps below:
1: Shows the VCS root branch configuratio.
2: Shows the VCS checkout options
3: Shows the artifacts that are available after the code gets checkout.
However, the build happened from development branch, but the list shows directories of master branch, below are bitbucket master and development branch code:
Master:
4: Shows the lsit of branches that I get in the drop down after making branch specification.
5: Shows the logs when I triggered the build:
[2018-09-03 16:16:19,260] INFO - tbrains.buildServer.ACTIVITIES - Build added to queue; Queued build {Build promotion {promotion id=102199, configuration={id=MuleSoftBuildProjectReleases_MulesoftBuildProjectAllReleases_PivotPolicyGwQuestO, internal id=bt11686}, branch=development, queued}, triggered by "Abdul Latif"}
[2018-09-03 16:16:19,829] INFO - tbrains.buildServer.ACTIVITIES - Build started; PIVOT Build Projects :: MuleSoft Build Project Releases :: Mulesoft Build Project - All releases :: Pivot_pivot-policy-gw-quest-outbound {id=MuleSoftBuildProjectReleases_MulesoftBuildProjectAllReleases_PivotPolicyGwQuestO, internal id=bt11686} #26 {build id=102199, promotion id=102199, branch=development, history=false, agent="BuildAgent7" {id=10}, triggered by "'gwatatif' (Abdul Latif) {id=65}" (##userId='65' type='user'). Started 2018-09-03 16:16:19.760, running}
[2018-09-03 16:17:08,496] INFO - tbrains.buildServer.ACTIVITIES - Finished build PIVOT Build Projects :: MuleSoft Build Project Releases :: Mulesoft Build Project - All releases :: Pivot_pivot-policy-gw-quest-outbound {id=MuleSoftBuildProjectReleases_MulesoftBuildProjectAllReleases_PivotPolicyGwQuestO, internal id=bt11686} #26 {build id=102199, promotion id=102199, branch=development, history=false, agent="BuildAgent7" {id=10}, triggered by "'gwatif' (Abdul Latif) {id=65}" (##userId='65' type='user'). Started 2018-09-03 16:16:21.033, running}
[2018-09-03 16:17:13,938] INFO - tbrains.buildServer.ACTIVITIES - Build added to queue; Queued build {Build promotion {promotion id=102200, configuration={id=Aws_AwsConfigStage, internal id=bt1577}, queued}, triggered by "Snapshot dependency; Finish Build Trigger; PIVOT Deployment Projects :: Series#3 Deployment Environments :: Mulesoft :: DEV3 :: deploy_pivot-policy-gw-quest-outbound"}
[2018-09-03 16:17:13,972] INFO - tbrains.buildServer.ACTIVITIES - Build added to queue; Queued build {Build promotion {promotion id=102201, configuration={id=MuleSoftDeploymentProjectsReleases_MuleSoftDeploymentRelease12_MulesoftDev3r1_35, internal id=bt10024}, queued}, triggered by "Finish Build Trigger; PIVOT Build Projects :: MuleSoft Build Project Releases :: Mulesoft Build Project - All releases :: Pivot_pivot-policy-gw-quest-outbound, build #26"}
[