2
votes

I want to setup continuous deployment of our development branch to staging environment in VSTS. Also we have dev environment where deployments should be performed from any branch and only manually.

Having experience with Octopus I was thinking about the following workflow:

  • build is triggered from any branch
  • release is created after every build
  • if branch is develop then trigger deployment to staging

I've created a build definition and release definition. My release definition is the following:

enter image description here

However I don't see anything related to branch / tag filtering in release trigger. Am I missing anything?

UPDATE

OK, so I tried old editor, as @Yan and @Harshil suggested and still cannot get it working. Seems like it allows to specify a tag that should trigger the deployment. I did not manage to find a way to provide a branch name. More screens:

enter image description here enter image description here

2
The new editor doesn't have this. Try the old editor, you have the edit in old editor button at right top.Harshil Lodhi
Which source control are you using? I think branches come up only with vsts git.Aseem Bansal

2 Answers

3
votes

Based on the screenshot, you specified develop tag instead of branch. You need to specify branch in dropdown box.

enter image description here

Update:

Regarding build tag, you can add tag to build per to current branch (Build.SourceBranchName) by using ##vso[build.addbuildtag]build tag logging command.

2
votes

I failed to find how to set it up with the new release editor, but the old one has this Triggers tab:

enter image description here