Azure DevOps provides a wide variety of services for DevOps teams so that they can plan, work, collaborate on code development, and build and deploy software and services. Most DevOps teams rely on several tools and build custom toolchains for each phase in the application life cycle.
The following diagram shows the phases that are defined in the application life cycle:
Figure 1.3 – Application life cycle phases
In the following sections, we'll explain these phases and the corresponding Microsoft tooling and products in more detail.
Plan
During the planning phase, teams can use Kanban boards and backlogs to define, track, and lay out the work that needs to be done in Azure Boards. They can also use GitHub for this. In GitHub, an issue can be created by suggesting a new idea or stating that a bug should be tracked. These issues can be organized and assigned to teams.
Develop
The development phase is supported by Visual Studio Code and Visual Studio. Visual Studio Code is a cross-platform editor, while Visual Studio is a Windows- and Mac-only IDE. You can use Azure DevOps for automated testing and use Azure Pipelines to create automatic builds for building the source code. Code can be shared across teams with Azure DevOps or GitHub.
Deliver
The deliver phase is about deploying your applications and services to target environments. You can use Azure Pipelines to deploy code automatically to any Azure service or on-premises environments. You can use Azure Resource Manager templates or Terraform to spin up environments for your applications or infrastructure components. You can also integrate Jenkins and Spinnaker inside your Azure DevOps Pipelines.
Operate
In this phase, you implement full-stack monitoring for monitoring your applications and services. You can also manage your cloud environment with different automation tools, such as Azure Automation, Chef, and more. Keeping your applications and services secure is also part of this phase. Therefore, you can use features and services such as Azure Policy and Azure Security Center.
To support the full life cycle of analyzing, designing, building, deploying, and maintaining software and infrastructure products and services, Azure DevOps provides integrated features that can be accessed through any web browser.
Azure DevOps offers a combination of solutions and tooling that can be used to create unique and custom workflows throughout each of the application life cycle phases. These solutions will be described in the upcoming sections.
Continuous integration and continuous delivery (CI/CD)
You can automate each DevOps process with CI/CD (and continuous deployment) in Azure DevOps. CI is used in the development phase of a project and refers to building and testing code in a fully automated way. Every time you commit changes to the master branch, the changes will be validated and then packaged into a build artifact automatically. With CD, the delivery phase is automated. Every time a build artifact is available, the artifact is automatically deployed to the desired environment. When continuous integration and continuous deployment are both used by development teams, the code remains ready for production at any time. The only thing that teams must do to deploy a working application into production is trigger the transition from development to deploy. This will make the automated build artifact available for deployment. This triggering can be as simple as pressing a button.
With Azure DevOps, you also implement continuous deployment. Adding this to your development life cycle means that you can automate the entire process, from code commit to production. The trigger between the development and delivery phase is completely automatic. So, when code changes are validated and pass all the tests that are performed during the development phase, the changes will be published to production automatically as well. This means that customers will receive the new version, along with the improvements for it, as soon as they are available.
Agile development support
Azure DevOps supports teams that adopt Agile development methods with planning, tracking, and reporting capabilities. This will result in shorter release cycles and full visibility in the software development process. You can use Azure Boards, which will be covered in more detail in the next section of this chapter, to manage backlogs and define, assign, and track work items. You can also use advanced analytics and reporting and create custom dashboards to track progress.
Version control
A version control system, also known as a source control system, is an essential tool for multi-developer projects. It allows developers to collaborate on the code and track changes. The history of all the code files is also maintained in the version control system. This makes it easy to go back to a different version of the code files in case of errors or bugs.
Azure DevOps supports two different types of source control: Git (distributed) and Team Foundation Version Control (TFVS). With Git, each developer has a copy of the source repository on their development machine. All branch and history information is included inside the source repository. Each developer works directly with their copy of the repository and all the changes are shared between the local and source repositories as a separate step. Changes can be committed on the local filesystem, and version control operations can be executed without a network connection. Branches can be created easily on the dev machine and later, they can be merged, published, or disposed by the developer separately. With TFVC, developers have only one version of each file on their local dev machines. All the others, as well as the historical data, are maintained only on the server. The branches are created on the server as well.
Infrastructure as Code
Teams can also manage the infrastructure in Azure DevOps. Infrastructure components that are used in a project, such as networks, virtual machines, and load balancers, can be managed using the same versioning features and capabilities that are used for the source code.
Used together with continuous delivery, an Infrastructure as Code (IaC) model generates the same environment every time it is deployed. Without IaC, teams need to configure and maintain the settings of all the individual deployment environments manually, which is a time-consuming and error-prone task. The most plausible outcome is that, over time, each environment becomes a snowflake, which is a unique configuration that cannot be reproduced automatically anymore. This inconsistency across environments will lead to issues during the deployment phase.
Configuration Management
Configuration Management refers to all the items and artifacts that are relevant to the project and the relationship between them. Those items are stored, retrieved, and uniquely identified and modified. This includes items such as source code, files, and binaries. The configuration management system is the one true source of configuration items.
Using Azure DevOps, resource configuration across the entire system can be managed by teams to roll out configuration updates, enforce desired states, and automatically resolve unexpected changes and issues. Azure offers multiple DevOps tools and capabilities for configuration management, such as Chef, Puppet, Ansible, and Azure Automation.
Monitoring
You can use Azure Monitor to practice full-stack continuous monitoring. The health of your infrastructure and applications can be integrated into existing dashboards in Grafana, Kibana, and the Azure portal with Azure Monitor. You can also monitor the availability, performance, and usage of your applications, whether they are hosted on-premises or in Azure. Most popular languages and frameworks are supported by Azure Monitor, such as NET, Java, and Node.js, and they are integrated with DevOps processes and tools in Azure DevOps.