Branch-per-feature, Environment branches and Azure Pipelines












0















Background:



We have an in-house CI/CD tool based on FAKE that performs the following workflow:




  • user enters 2 parameters: $source-branch and $target-environment

  • pull master

  • pull $source-branch

  • pull $target-environment (there is a git branch for every environment: DEV, TEST, etc, except for PROD which is hard-coded to master)

  • create a temporary branch from $target-environment called $target-environment-$current-date-$source-branch (for instance DEV-201811271840-SomeNewFeature)

  • merge master into temp branch

  • merge $source-branch into temp branch

  • execute build script

  • deploy

  • if deploy succeeds, then merge temp branch into $target-environment.

  • delete temp branch


Problem:



Without getting into too much detail about the build/deploy steps (which are a whole different conversation) I'd like to know if/how can I replicate this workflow in Azure Pipelines.



It seems that all documentation and even all the options in the UI refer to a different use case.



We want to be able to push our feature branches, have them merged to the environment branches (and eventually to master) after they're deployed, and not before, which is why we're performing build/test/deploy steps in a temporary branch, which gets merged into $environment ONLY after the build/test/deploy steps succeed.



Question:



Is this even possible using Azure Pipelines without resorting to custom code? I haven't found any documentation about it and the options in the UI don't seem to help either.










share|improve this question




















  • 1





    It's an interesting question, I think actually you'll not replicate this exact workflow in Pipelines, nor should you want to as pipelines has strong concepts around the environments you deploy to. I suspect there's a solution around using pull requests on feature branches that then release based on pull request triggers (docs.microsoft.com/en-us/azure/devops/pipelines/release/…), but I have to admit my experience here isn't enough to put this as a solid answer to your question.

    – Colin B
    Nov 28 '18 at 0:02
















0















Background:



We have an in-house CI/CD tool based on FAKE that performs the following workflow:




  • user enters 2 parameters: $source-branch and $target-environment

  • pull master

  • pull $source-branch

  • pull $target-environment (there is a git branch for every environment: DEV, TEST, etc, except for PROD which is hard-coded to master)

  • create a temporary branch from $target-environment called $target-environment-$current-date-$source-branch (for instance DEV-201811271840-SomeNewFeature)

  • merge master into temp branch

  • merge $source-branch into temp branch

  • execute build script

  • deploy

  • if deploy succeeds, then merge temp branch into $target-environment.

  • delete temp branch


Problem:



Without getting into too much detail about the build/deploy steps (which are a whole different conversation) I'd like to know if/how can I replicate this workflow in Azure Pipelines.



It seems that all documentation and even all the options in the UI refer to a different use case.



We want to be able to push our feature branches, have them merged to the environment branches (and eventually to master) after they're deployed, and not before, which is why we're performing build/test/deploy steps in a temporary branch, which gets merged into $environment ONLY after the build/test/deploy steps succeed.



Question:



Is this even possible using Azure Pipelines without resorting to custom code? I haven't found any documentation about it and the options in the UI don't seem to help either.










share|improve this question




















  • 1





    It's an interesting question, I think actually you'll not replicate this exact workflow in Pipelines, nor should you want to as pipelines has strong concepts around the environments you deploy to. I suspect there's a solution around using pull requests on feature branches that then release based on pull request triggers (docs.microsoft.com/en-us/azure/devops/pipelines/release/…), but I have to admit my experience here isn't enough to put this as a solid answer to your question.

    – Colin B
    Nov 28 '18 at 0:02














0












0








0


1






Background:



We have an in-house CI/CD tool based on FAKE that performs the following workflow:




  • user enters 2 parameters: $source-branch and $target-environment

  • pull master

  • pull $source-branch

  • pull $target-environment (there is a git branch for every environment: DEV, TEST, etc, except for PROD which is hard-coded to master)

  • create a temporary branch from $target-environment called $target-environment-$current-date-$source-branch (for instance DEV-201811271840-SomeNewFeature)

  • merge master into temp branch

  • merge $source-branch into temp branch

  • execute build script

  • deploy

  • if deploy succeeds, then merge temp branch into $target-environment.

  • delete temp branch


Problem:



Without getting into too much detail about the build/deploy steps (which are a whole different conversation) I'd like to know if/how can I replicate this workflow in Azure Pipelines.



It seems that all documentation and even all the options in the UI refer to a different use case.



We want to be able to push our feature branches, have them merged to the environment branches (and eventually to master) after they're deployed, and not before, which is why we're performing build/test/deploy steps in a temporary branch, which gets merged into $environment ONLY after the build/test/deploy steps succeed.



Question:



Is this even possible using Azure Pipelines without resorting to custom code? I haven't found any documentation about it and the options in the UI don't seem to help either.










share|improve this question
















Background:



We have an in-house CI/CD tool based on FAKE that performs the following workflow:




  • user enters 2 parameters: $source-branch and $target-environment

  • pull master

  • pull $source-branch

  • pull $target-environment (there is a git branch for every environment: DEV, TEST, etc, except for PROD which is hard-coded to master)

  • create a temporary branch from $target-environment called $target-environment-$current-date-$source-branch (for instance DEV-201811271840-SomeNewFeature)

  • merge master into temp branch

  • merge $source-branch into temp branch

  • execute build script

  • deploy

  • if deploy succeeds, then merge temp branch into $target-environment.

  • delete temp branch


Problem:



Without getting into too much detail about the build/deploy steps (which are a whole different conversation) I'd like to know if/how can I replicate this workflow in Azure Pipelines.



It seems that all documentation and even all the options in the UI refer to a different use case.



We want to be able to push our feature branches, have them merged to the environment branches (and eventually to master) after they're deployed, and not before, which is why we're performing build/test/deploy steps in a temporary branch, which gets merged into $environment ONLY after the build/test/deploy steps succeed.



Question:



Is this even possible using Azure Pipelines without resorting to custom code? I haven't found any documentation about it and the options in the UI don't seem to help either.







git deployment continuous-integration azure-devops continuous-deployment






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 28 '18 at 18:24







Federico Berasategui

















asked Nov 27 '18 at 21:54









Federico BerasateguiFederico Berasategui

37k1074127




37k1074127








  • 1





    It's an interesting question, I think actually you'll not replicate this exact workflow in Pipelines, nor should you want to as pipelines has strong concepts around the environments you deploy to. I suspect there's a solution around using pull requests on feature branches that then release based on pull request triggers (docs.microsoft.com/en-us/azure/devops/pipelines/release/…), but I have to admit my experience here isn't enough to put this as a solid answer to your question.

    – Colin B
    Nov 28 '18 at 0:02














  • 1





    It's an interesting question, I think actually you'll not replicate this exact workflow in Pipelines, nor should you want to as pipelines has strong concepts around the environments you deploy to. I suspect there's a solution around using pull requests on feature branches that then release based on pull request triggers (docs.microsoft.com/en-us/azure/devops/pipelines/release/…), but I have to admit my experience here isn't enough to put this as a solid answer to your question.

    – Colin B
    Nov 28 '18 at 0:02








1




1





It's an interesting question, I think actually you'll not replicate this exact workflow in Pipelines, nor should you want to as pipelines has strong concepts around the environments you deploy to. I suspect there's a solution around using pull requests on feature branches that then release based on pull request triggers (docs.microsoft.com/en-us/azure/devops/pipelines/release/…), but I have to admit my experience here isn't enough to put this as a solid answer to your question.

– Colin B
Nov 28 '18 at 0:02





It's an interesting question, I think actually you'll not replicate this exact workflow in Pipelines, nor should you want to as pipelines has strong concepts around the environments you deploy to. I suspect there's a solution around using pull requests on feature branches that then release based on pull request triggers (docs.microsoft.com/en-us/azure/devops/pipelines/release/…), but I have to admit my experience here isn't enough to put this as a solid answer to your question.

– Colin B
Nov 28 '18 at 0:02












0






active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53508781%2fbranch-per-feature-environment-branches-and-azure-pipelines%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53508781%2fbranch-per-feature-environment-branches-and-azure-pipelines%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Lallio

Unable to find Lightning Node

Futebolista