Reader small image

You're reading from  Azure for Architects. - Second Edition

Product typeBook
Published inJan 2019
PublisherPackt
ISBN-139781789614503
Edition2nd Edition
Tools
Right arrow
Author (1)
Ritesh Modi
Ritesh Modi
author image
Ritesh Modi

Ritesh Modi is a technologist with more than 18 years of experience. He holds a master's degree in science in AI/ML from LJMU. He has been recognized as a Microsoft Regional Director for his contributions to building tech communities, products, and services. He has published more than 10 tech books in the past and is a cloud architect, speaker, and leader who is popular for his contributions to data centers, Azure, Kubernetes, blockchain, cognitive services, DevOps, AI, and automation.
Read more about Ritesh Modi

Right arrow

Azure DevOps

Software development is a complex undertaking composed of multiple processes and tools, and involves people from different departments. They all need to come together and work in a cohesive manner. With so many variables, the risks are high while delivering to the end customers. One small omission or misconfiguration, and the application might come crashing down. This chapter is about adopting and implementing practices that reduce this risk considerably and ensure that high-quality software can be delivered to the customer again and again.

Before getting into the details of DevOps, let's list the problems faced by software companies that DevOps addresses:

  • Organizations are rigid and don't welcome change
  • Rigid and time-consuming processes
  • Isolated teams working in silos
  • Monolithic design and big bang deployments
  • Manual execution
  • Lack of innovation

In this...

DevOps

There's currently no industry-wide consensus regarding the definition of DevOps. Organizations have formulated their own definition of DevOps and tried to implement it. They have their own perspective and think they've implemented DevOps if they implement automation and configuration management, and use Agile processes.

DevOps is about the delivery mechanism of software systems. It's about bringing people together, making them collaborate and communicate, working together towards a common goal and vision. It's about taking joint responsibility, accountability, and ownership. It's about implementing processes that foster collaboration and a service mindset. It enables delivery mechanisms that bring agility and flexibility to the organization. Contrary to popular belief, DevOps isn't about tools, technology, and automation. These are enablers...

DevOps practices

DevOps consists of multiple practices, each providing a distinct functionality to the overall process. The following figure shows the relationship between them. Configuration management, continuous integration, and continuous deployment form the core practices that enable DevOps. When we deliver software services that combine these three services, we achieve continuous delivery. Continuous delivery is a capability and level of maturity of an organization dependent on the maturity of configuration management, continuous integration, and continuous deployment. Continuous feedback at all stages forms the feedback loop that helps to provide superior services to customers. It runs across all DevOps practices. Let's deep dive into each of these capabilities and DevOps practices:

...

Azure DevOps

Now, it's time to focus on another revolutionary online service that enables continuous integration, continuous deployment, and continuous delivery seamlessly: Azure DevOps. In fact, it would be more appropriate to call it a suite of services available under a single name. Azure DevOps is a PaaS provided by Microsoft and hosted on the cloud. The same service is available as Team Foundation Services (TFS) on-premise. All examples shown in this book use Azure DevOps.

According to Microsoft, Azure DevOps is a cloud-based collaboration platform that helps teams to share code, track work, and ship software. Azure DevOps is a new name; earlier, it was known as Visual Studio Team Services (VSTS). Azure DevOps is an enterprise software-development tool and service that enables organizations to provide automation facilities to their end-to-end application life cycle management...

Preparing for DevOps

Going forward, our focus will be on process and deployment automation using different patterns in Azure. These include the following:

  • DevOps for IaaS solutions
  • DevOps for PaaS solutions
  • DevOps for container-based solutions

Generally, there are shared services that aren't unique to any one application. Their services are consumed by multiple applications from different environments, such as development, testing, and production. The life cycle of these shared services is different for each application. Therefore, they have different version-control repositories, a different code base, and build and release management. They have their own cycle of plan, design, build, test, and release.

The resources that are part of this group are provisioned using ARM templates, PowerShell, and DSC configurations.

The overall flow for building these common components...

DevOps for PaaS solutions

The typical architecture for Azure PaaS app services is based on the following diagram:

The architecture shows some of the important components, such as Azure SQL, storage accounts, the version-control system, that participate in the Azure App Services-based cloud solution architecture. These artifacts should be created using Azure resource-manager templates. These ARM templates should be part of the overall configuration-management strategy. It can have its own build and release management pipelines, similar to the one shown in the following diagram:

The template should also configure continuous deployment by configuring Deployment options.

Azure App Services

Azure App Services provides managed...

DevOps for virtual machine (IaaS)-based solutions

The typical architecture for an IaaS virtual machine-based solution is shown here:

Azure Virtual Machines (VM)

Azure Virtual Machines that host web applications, application servers, database, and other services are provisioned using ARM templates. Each virtual machine has a single network card with a public IP assigned to it. They're attached to a virtual network and have a private IP address from the same network. The public IP for virtual machines is optional since they're attached to a public load balancer. These virtual machines are based on a Windows 2016 server image. Operational insight agents are installed on virtual machines to monitor the virtual machines...

DevOps for container-based (IaaS) solutions

The typical architecture for IaaS container-based solutions is shown here:

In the architecture shown before, container runtime are deployed on virtual machines and containers are run within them. These containers are managed by container orchestrators like Kubernetes. Monitoring services are provided by Log Analytics and all secrets and keys are stored in Azure Key Vault. There is also a pull server that could be on a virtual machines or Azure Automation providing configuration information to the virtual machines.

Containers

Containers are a virtualization technology; however, they don't virtualize physical servers. Instead, containers are an operating-system-level virtualization...

Azure DevOps and Jenkins

Azure DevOps is an open platform orchestrator that integrates with other orchestrator tools seamlessly. It provides all the necessary infrastructure and features that integrate well with Jenkins, as well. Organizations with well-established CI/CD pipelines built on Jenkins can reuse them with the advanced but simple features of Azure DevOps to orchestrate them.

Jenkins can be used as a repository and can execute CI/CD pipelines in Azure DevOps, while it's also possible to have a repo in Azure DevOps and execute CI/CD pipelines in Jenkins.

The Jenkins configuration can be added in Azure DevOps as service hooks, and whenever any code change is committed to the Azure DevOps repository, it can trigger pipelines in Jenkins. The next screenshot shows configuration of Jenkins from the Azure DevOps service hook configuration section:

There are multiple triggers...

Azure Automation

Azure Automation is Microsoft's platform for all automation implementation with regard to cloud, on-premise, and hybrid deployments. Azure Automation is a mature automation platform that provides rich capabilities in terms of the following:

  • Defining assets, such as variables, connections, credentials, certificates, and modules
  • Implementing runbooks using Python, PowerShell scripts, and PowerShell workflows
  • Providing user interfaces to create runbooks
  • Managing the full runbook life cycle, including building, testing, and publishing
  • Scheduling runbooks
  • The ability to run runbooks anywhere—on cloud or on-premise
  • DSC as a configuration-management platform
  • Managing and configuring environments—Windows and Linux, applications, and deployment
  • The ability to extend Azure Automation by importing custom modules

Azure Automation provides a DSC pull server...

Azure for DevOps

As mentioned before, Azure is a rich and mature platform that provides the following:

  • Multiple choices of languages
  • Multiple choices of operating systems
  • Multiple choices of tools and utilities
  • Multiple patterns for deploying solutions (virtual machines, app services, containers, micro-services)

With so many options and choices, Azure offers the following:

  • Open cloud: It is open for open source, Microsoft, and non-Microsoft products, tools, and services.
  • Flexible cloud: It is easy enough for both business users and developers to use it with their existing skills and knowledge.
  • Unified management: It provides seamless monitoring and management features.

All the features mentioned here are important for the successful implementation of DevOps. The next diagram shows the open source tools and utilities that can be used for different phases in managing the application...

Summary

DevOps is gaining a lot of traction and momentum in the industry. Most organizations have realized its benefits and are looking to implement DevOps. This is happening while most of them are moving to the cloud. Azure, as a cloud model, provides rich and mature DevOps services, making it easy for organizations to implement DevOps. In this chapter, we discussed DevOps along with its core practices, such as configuration management, continuous integration, continuous delivery, and deployment. We also discussed different cloud solutions based on PaaS, a virtual machine IaaS, and a container IaaS, along with their respective Azure resources, the build and release pipelines. Configuration management was the core part of this chapter, and we discussed DSC services from Azure Automation and using pull servers to configure virtual machines automatically. Finally, we covered Azure...

lock icon
The rest of the chapter is locked
You have been reading a chapter from
Azure for Architects. - Second Edition
Published in: Jan 2019Publisher: PacktISBN-13: 9781789614503
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at £13.99/month. Cancel anytime

Author (1)

author image
Ritesh Modi

Ritesh Modi is a technologist with more than 18 years of experience. He holds a master's degree in science in AI/ML from LJMU. He has been recognized as a Microsoft Regional Director for his contributions to building tech communities, products, and services. He has published more than 10 tech books in the past and is a cloud architect, speaker, and leader who is popular for his contributions to data centers, Azure, Kubernetes, blockchain, cognitive services, DevOps, AI, and automation.
Read more about Ritesh Modi