Part 5-Pipeline: "Running the Azure Release Pipeline"
Tags: azure, cicd, devops, beginners
Published: 2023-12-22 04:00:00

Let's conclude our Azure Pipelines series with the final part, where we will execute and run the release pipeline that we configured in the 4th part. Stay tuned for updates on the new Azure DevOps tool series.

=================================================================

*Note: *

When you are doing practical work, don't delete anything because our Azure DevOps series relies on continuity between each part. Ensure that you are not cleaning your workspace. Additionally, don't worry about charges, as our account is on a free trial. We are covering beginners or basic Azure DevOps, so our project is not large. If a bill is generated, it will not go higher. For some knowledge, you can budget or be ready to invest some money.

=================================================================

-> So, let's get started.

-> Now, open the 'pipeline' in a new tab, then click on 'edit,' remove the highlighted code, and finally, 'save.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/10jpf8hzafm4xz23weix.png)

-> Okay, so there is no error in the pipeline. Let's see if our 'Release Pipeline' is triggered or not.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/56w6who2fokwb2rcbm7i.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zkyjc5euw5cv3m0y0034.png)

-> Now, open it and check the logs. You will notice that our release has failed due to the presence of 'Work items.' We have a blocking item as per the query, stating that if there is a work item with the status of p1 and it is not in the 'Done' state, the deployment should not trigger. This is what happened, and the pipeline will attempt the evaluation again in 5 minutes.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dxvkyhnog8ton3k59qr7.png)

-> So, navigate to 'Work Items' again and update the status from 'Active' to 'Closed.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/k7b3yt7yrj5mbxdk6yg5.png)

-> So, go to 'Queries', open our query, then click on 'Editor.' Add one more 'clause' and save.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2vxelku7431tdmgcd8b6.png)

-> Click on 'Queries' again, open the three dots, then search for your project. Add this and give 'read' permission. This is an important step to read the queries for quality gates; otherwise, your release will fail.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dmexyf3r7fdxo88h1u13.png)

-> Now go back to our pipeline. Here you will see our 'Quality Gates' succeeded, and it's evaluating for the second time. So, wait until that also succeeds.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qmgh6p619krxm5qrcvyf.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s2pw8gtoq4qw04yaqyma.png)

-> Here, you can see that both quality gates have been verified, and our deployment is also successful. Now, click on 'Run on Agent,' then open 'Deploy Azure App Service.' You will find the staging link or URL, and the word 'Stage' is mentioned there.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/fm78fdo9e28rd4vlhfoz.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/l36xzohah9ak4jkt7pfr.png)

-> So, our production deployment is still pending. Let's go to that and 'Approve' it.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4dtr552drn5hj25e8zju.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/t8kxlig90uykhf00mo5o.png)

-> If you compare the YouTube image pictures for the staging and production stages, you will notice the URL change. This confirms that our staging and production deployments for YouTube have been completed successfully and are running. Additionally, you can see that YouTube videos are now visible in my app. In my previous deployment, they weren't showing.

=================================================================

Summary:

"In this Azure Pipelines series, we embarked on a comprehensive journey, starting with the setup of Azure App Service for hosting our YouTube clone web app. Moving through the classic editor, YAML pipelines, and blue-green deployment with release pipelines, we gained mastery over continuous integration and delivery. Quality gates and approvals added robustness. 

The series concluded with a successful run of the release pipeline, showcasing the seamless deployment of our app in both staging and production. This journey not only covered the technical aspects but also emphasized the importance of quality and collaboration in the DevOps lifecycle."

=================================================================

What Next?

As we bid farewell to the Azure Pipelines series, the next chapter awaits, delving into the Azure Test Plan service. Stay tuned for an in-depth exploration of testing methodologies and practices within the Azure DevOps ecosystem. 

In the meantime, apply the knowledge gained from the pipeline series to your projects, and don't forget to share your progress by posting a screenshot on LinkedIn. Your engagement and success stories bring joy and motivation to the DevOps community. Keep learning, applying, and thriving in your DevOps journey!

=================================================================

If you have any doubts, questions, or recommendations, feel free to drop a comment. Follow me for updates and happy learning! :)