top of page
Writer's pictureALIF Consulting

Design and Build a CI/CD pipeline using Azure DevOps

Updated: May 31

Azure DevOps is a software as a service (SaaS) platform that offers users an end-to-end DevOps toolchain to develop and deploy software.

Azure DevOps is not a single program but instead consists of the following services:

  • Azure Boards: This covers agile planning, work item tracking, visualization, and reporting tools.

  • Azure Pipelines: This is a language, platform, and cloud-agnostic CI/CD platform with support for containers or Kubernetes.is

  • Azure Repos: This offers a cloud-hosted private Git repository with pull requests, advanced file management, and other benefits.

  • Azure Artifacts: The artifacts in question provide developers with integrated package management, including support for Maven, npm, Python, and NuGet package feeds from either public or private sources.

  • Azure Test Plans: This service provides an integrated, all-in-one, planned, and exploratory testing solution.

Features of Azure DevOps

Azure DevOps services offer a great selection of features for development teams. For instance:

  • Dashboard Control - Using the DevOps dashboard feature, you can quickly navigate to different areas of the project, add and manage dashboards, and configure dashboard widgets.

  • Improved Source Control - Azure DevOps systems support two popular types of source control: Git (distributed) or Team Foundation Version Control (TFVC), which is a centralized, client-server system. You can add and manage Azure Git tags and review, download, and edit files to see change history.

  • Plan and Track Your Work - Azure DevOps systems provide you with a couple of types of work items used to monitor features, requirements, user stories, tasks, bugs, and more. For planning purposes, you can access several kinds of backlogs and boards to support the main agile methods: Scrum, Scrumban, or Kanban. You can add and update relevant work items, manage product backlogs, use sprint backlogs to plan sprints and use Kanban boards to visualize the workflow and update statuses.

  • Continuous Integration and Deployment (CI/CD) - Many developers employ the practice of CI/CD, and Azure DevOps supports them. By using Azure pipelines, developers can automate many of the design processes, including defining builds and their steps, creating test instructions, and managing simultaneous releases.

  • Support for Manual and Exploratory Testing - Azure DevOps’ test features facilitate manual, exploratory, and continuous testing, including workflow customization, end-to-end traceability, criteria-based selection, and real-time charts that track test activity.

  • Integrated Collaboration Services - The feature that enables teams to collaborate across the entire collection of Azure DevOps features and functions:

    • Team dashboards

    • Project wiki

    • Discussion within work item forms

    • Linking work items commits, pull requests, and other artifacts that support traceability

    • Alerts and change notifications are managed per user, team, project, or organization

    • The ability to request and manage feedback

    • Analytics service, analytic views, and Power BI reporting

  • Azure Cloud-hosted Services - Azure provides DevOps teams with cloud-hosted services that support application development and deployment. These services can be used by themselves or in combination with Azure DevOps.

Azure DevOps Benefits

Azure DevOps provides DevOps teams with powerful tools.

  • Timely Access to New Features - Every three weeks, DevOps users receive access to new features. No need to scramble around and wonder what’s new. These are not to be confused with upgrades, and speaking of which:

  • No Upgrades to Worry About - Users need not worry about upgrading or patching up the toolchain because Azure DevOps is a SaaS product. Companies that run on a CI/CD model no longer need to slow things down for the sake of upgrading.

  • Reliability - Azure DevOps is backed by 24 x7 support and a 99.9% SLA.

  • Flexibility - if your DevOps team doesn’t want or need the full suite of services, they can acquire them independently.

  • It’s Platform-agnostic - DevOps is designed to run on any platform (Linux, macOS, and Windows) or language (e.g., Android, C/C++, Node.js, Python, Java, PHP, Ruby, .Net, and iOS apps).

  • It’s cloud-agnostic, and Azure DevOps works with AWS and GCP.

This scenario provides architecture and design guidance for building a continuous integration (CI) and continuous deployment (CD) pipeline. In this example, the CI/CD pipeline deploys a two-tier .NET web application to the Azure App Service.

Migrating to modern CI/CD processes provides many benefits for application builds, deployments, testing, and monitoring. By using Azure DevOps along with other services such as App Service, organizations can focus on the development of their apps rather than the management of the supporting infrastructure.


Relevant use cases

Consider Azure DevOps and CI/CD processes for:

  • Accelerating application development and development lifecycles.

  • Building quality and consistency into an automated build and release process

  • Increasing application stability and uptime

Architecture

Azure DevOps

The data flows through the scenario as follows:

  1. A developer changes the application source code.

  2. Application code, including the web. The config file is committed to the source code repository in Azure Repos.

  3. Continuous integration triggers application build and unit tests using Azure Test Plans.

  4. Continuous deployment within Azure Pipelines triggers an automated deployment of application artifacts with environment-specific configuration values.

  5. The artifacts are deployed to Azure App Service.

  6. Azure Application Insights collects and analyzes health, performance, and usage data.

  7. Developers monitor and manage health, performance, and usage information.

  8. Backlog information is used to prioritize new features and bug fixes using Azure Boards.

Components

  • Azure DevOps is a service for managing your development lifecycle end-to-end—from planning and project management to code management and continuing to build and release.

  • Azure Web Apps is a PaaS service for hosting web applications, REST APIs, and mobile backends. While this article focuses on .NET, there are several additional development platform options supported.

  • Application Insights is a first-party, extensible Application Performance Management (APM) service for web developers on multiple platforms.

Alternatives

While this article focuses on Azure DevOps, Azure DevOps Server (previously known as Team Foundation Server) could be used as an on-premises substitute. Alternatively, you could also use a set of technologies for an open-source development pipeline using Jenkins.

From an infrastructure-as-code perspective, Resource Manager templates were used as part of the Azure DevOps project, but you could consider other management technologies such as Terraform or Chef. If you prefer an infrastructure-as-a-service (IaaS)-based deployment and require configuration management, you could consider either Azure Automation State Configuration, Ansible, or Chef.


You could consider these alternatives to hosting in Azure Web Apps :


  • Azure Virtual Machines handles workloads that require a high degree of control or depend on OS components and services that are not possible with Web Apps (for example, the Windows GAC or COM).

  • Service Fabric is a good option if the workload architecture is focused on distributed components that benefit from being deployed and run across a cluster with a high degree of control. Service Fabric can also be used to host containers.

  • Azure Functions provides an effective serverless approach if the workload architecture is centred around fine-grained distributed components, requiring minimal dependencies, where individual components are only required to run on demand (not continuously), and orchestration of components is not required.

Management and Security Considerations

  • Consider leveraging one of the tokenization tasks available in the VSTS marketplace.

  • Azure Key Vault tasks can download secrets from an Azure Key Vault into your release. You can then use those secrets as variables in your release definition, which avoids storing them in source control.

  • Use release variables in your release definitions to drive configuration changes in your environments. Release variables can be scoped to an entire release or a given environment. When using variables for secret information, ensure that you select the padlock icon.

  • Deployment gates should be used in your release pipeline. This lets you leverage monitoring data in association with external systems (for example, incident management or additional bespoke systems) to determine whether a release should be promoted.

  • Where manual intervention in a release pipeline is required, use the approvals functionality.

  • Consider using Application Insights and additional monitoring tools as early as possible in your release pipeline. Many organizations only begin monitoring in their production environment. By monitoring your other environments, you can identify bugs earlier in the development process and avoid issues in your production environment.

Deploy the scenario

Prerequisites

  • You must have an existing Azure account. If you don't have an Azure subscription, create a free account before you begin.

  • You must sign up for an Azure DevOps organization. For more information

Walk-through

Azure DevOps Projects will deploy an App Service Plan, App Service, and an App Insights resource for you, as well as configure an Azure Pipelines pipeline for you.

Once you've configured a pipeline with Azure DevOps Projects and the build is completed, review the associated code changes, work items, and test results. You will notice that no test results are displayed because the code does not contain any tests to run.

The pipeline creates a release definition and a continuous deployment trigger, deploying our application into the Dev environment. As part of a continuous deployment process, you may see releases that span multiple environments. A release can span both infrastructures (using techniques such as infrastructure-as-code) and can also deploy the application packages required along with any post-configuration tasks.


Pricing

Azure DevOps costs depend on the number of users in your organization that require access, along with other factors like the number of concurrent builds/releases required and the number of test users.

This pricing calculator provides an estimate for running Azure DevOps with 20 users.

Azure DevOps is billed on a per-user per-month basis. There may be additional charges depending on concurrent pipelines needed, in addition to any additional test users or basic user licenses.



782 views0 comments

Recent Posts

See All

コメント


bottom of page