Can we migrate published test results while migrating builds from one project to another in Azure DevOps? or is there any way to store those results.
Create a script using Azure DevOps Services REST API:
Get all Runs from old Azure DevOps: https://learn.microsoft.com/en-us/rest/api/azure/devops/test/runs/list?view=azure-devops-rest-6.0
Get all results for each run from old Azure DevOps: https://learn.microsoft.com/en-us/rest/api/azure/devops/test/results/list?view=azure-devops-rest-6.0
Create previously saved runs in new Azure DevOps: https://learn.microsoft.com/en-us/rest/api/azure/devops/test/runs/create?view=azure-devops-rest-6.0
Create previously saved results in new Azure DevOps: https://learn.microsoft.com/en-us/rest/api/azure/devops/test/results/add?view=azure-devops-rest-6.0
Published tests results will go into Tests Plan -> Runs after builds. You can go the Runs to check the result.
Related
I have 2 .NET 5 Azure Function Visual Studio projects . These 2 Functions to be deployed in a single Azure Function App.
I have 2 separate Build Pipelines for each of the projects and have separate Release Pipelines as well in Azure DevOps. I am not using YAML for release pipelines but depends on DevOps UI to choose a new Release pipeline.
My issue is that whenever running the Release pipeline, the last Release overrides the existing Function in Azure Function App. So, I am not getting 2 Functions as expected under a single Azure Function App. Always the last release deployment exists in Azure. Why one release deployment overrides existing Functions, even though they are from different Release pipelines?
In the MS documentation it states that if you perform a "Zip Deployment" to an Azure Function, it will always overwrite what is running on the Azure Function Service. I presume that the "Classic Pipeline" gives you the "Zip Deployment" option.
Link to MS Documentation: https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/deploy/azure-function-app?view=azure-devops#deployment-methods
For the moment, I do have a ticket open at Microsoft on how to manage different apps on the same Azure Function service. I only want changes made to the specific app where there are code changes without impacting any other existing apps on the Azure Function. For now, I only had one troubleshooting session with no solution in sight. I will share more information once I have received a solution/workaround.
I have an existing app service running on Azure that I previously published directly from Visual Studio. I am trying to get to grips with using DevOps and was wondering if it is possible to add a CI/CD pipeline to an existing app service.
I have seen a lot of tutorials on the web about how to create a pipeline for a new app service (many, of course, are out of date and do not actually relate to what one sees in the Azure portal!) So far, though, I have not come across anything about adding this to an existing app service.
Any advice or links to handy tutorials would be greatly appreciated!
I am hoping that the answer is not delete the existing service and start again from scratch!
If you are a beginner on Azure Devops, I will recommend to use the Azure Devops Starter project to create a pipeline, you can pick AppService as the deployment.
Once the pipelines are created on the Azure Devops , just open the pipeline and select the existing AppService where you want to deploy and also the source from where you want to pull the code. This makes easier rather than creating the stuffs from the scratch.
I’m trying to configure an Azure logic apps with an Azure Devops connector that would create a new pipeline release
The pipeline needs two variables, system and scope:
And looking at the azure DevOps connector doc
https://learn.microsoft.com/en-us/connectors/visualstudioteamservices/#create-a-new-release
How should I configure the name and value in the logic app ?, I tried this but it didn't work:
How to pass those variable to the release pipeline in Azure DevOps ?
Apparently adding the connector from Visual studio will give an incomplete connector, deleting it and recreated it from the portal gave the key and value options
Let's assume that we have 3 different container registries. Is there any available azure devops jobs/tasks that can provide a way to trigger my build pipeline when a new image is pushed on any of these 3 registries?
I have some insights with MS Flow but i want to limit the scope on azure devops.
Find a way or recommendation to trigger the build pipeline using devops jobs/tasks.
You can create in Azure Container Registry a web hook that trigger the build in Azure DevOps when new image pushed.
For this you need to write a service with Web API that handle the API Post calls. the ACR web hook send a Post call to the service when new image is pushed.
In the service you trigger the Azure DevOps build pipeline using the Azure DevOps .Net Libraries (if the service is in C#) or with Azure DevOps Rest API.
How to create ACR Web Hook? find here.
How to trigger build pipeline from code? find here.
you can have releases triggered with new images in the docker hub (reading). I dont think the same can be done for builds. You can create a release that would get triggered on the new image and that release would talk to the API to trigger the build.
I have created Azure Data Factory with Copy Activity using C# and Azure SDK.
How can deploy it using CI/CD ?
Any URL or link will help
Data Factory continuous integration and delivery is now possible with directly through the web user interface using ARM Templates or even Git (Github or Azure DevOps).
Just click on "Set up Code Repository" and follow the steps.
Check the following link for more information, including a video demostration: https://aka.ms/azfr/401/02
One idea that I got from Microsoft was that using the same Azure SDK you could deserialize the objects and save down the JSON files following the official directory structure into your local GitHub/Git working directory
In other words you would have to mimic what the UI Save All/Save button does from the portal.
Then using Git bash, you can just commit and push to your working branch (i.e. develop) and from the UI you can just publish (this will create an adf_publish release branch with the ARM objects)
Official reference for CI using VSTS and the UI Publish feature: https://learn.microsoft.com/en-us/azure/data-factory/continuous-integration-deployment
Unfortunately, CI/CD for ADF is not very intuitive at first glance.
Check out this blog post where I'm describing what/how/why step by step:
Deployment of Azure Data Factory with Azure DevOps
Let me know if you have any questions or concerns and finally - if that works for you.
Good luck!
My resources on how to enable CI/CD using Azure DevOps and Data Factory comes from the Microsoft site below:
Continuous integration and delivery (CI/CD) in Azure Data Factory
I am still new to DevOps and CI/CD, but I do know that other departments had this set up and it looks to be working for them.