Hello Megha S,
Welcome to the Microsoft Q&A and thank you for posting your questions here.
Problem
I understand that you like to know if it is possible to configure release with multistage release pipeline in Azure DevOps and if it is, what are the best solution.
Solution
You can configure a multistage release pipeline in Azure DevOps to divide your CI/CD process into different stages. In Azure DevOps, you can achieve this by customizing your release pipeline. To achieve this, the best practice is to use YAML pipelines.
- After you've created an Azure DevOps Project
- Create your App Service Instances.
- Build a YAML Pipeline.
- In your repository, create a
azure-pipelines.yml
file. - Define three stages in your pipeline:
- Build > To build the source code and produce a package.
- Dev > To deploy the package to a development site for testing.
- Staging > To deploy to a staging Azure App Service instance with a manual approval check.
- Use tasks like
dotnet build
,dotnet publish
, andaz webapp deployment
to achieve this.
- In your repository, create a
- Configure Variables.
- In Azure DevOps, go to Pipelines > Library.
- Create a variable group named "Release."
- Add variables for your development and staging host names (replace the value 1234 with the correct instance value).
- Save and Trigger the Pipeline
- Save your YAML file.
- Commit your changes to trigger the pipeline.
- Verify the deployments in both development and staging environments.
References
Create a multistage pipeline with Azure DevOps.
Multi-Stages in release pipeline with Pre-deployment approvals -YouTube.
Accept Answer
I hope this is helpful! Do not hesitate to let me know if you have any other questions.
** Please don't forget to close up the thread here by upvoting and accept it as an answer if it is helpful ** so that others in the community facing similar issues can easily find the solution.
Best Regards,
Sina Salam