Book Image

Learning DevOps

By : Mikael Krief
Book Image

Learning DevOps

By: Mikael Krief

Overview of this book

The implementation of DevOps processes requires the efficient use of various tools, and the choice of these tools is crucial for the sustainability of projects and collaboration between development (Dev) and operations (Ops). This book presents the different patterns and tools that you can use to provision and configure an infrastructure in the cloud. You'll begin by understanding DevOps culture, the application of DevOps in cloud infrastructure, provisioning with Terraform, configuration with Ansible, and image building with Packer. You'll then be taken through source code versioning with Git and the construction of a DevOps CI/CD pipeline using Jenkins, GitLab CI, and Azure Pipelines. This DevOps handbook will also guide you in containerizing and deploying your applications with Docker and Kubernetes. You'll learn how to reduce deployment downtime with blue-green deployment and the feature flags technique, and study DevOps practices for open source projects. Finally, you'll grasp some best practices for reducing the overall application lead time to ensure faster time to market. By the end of this book, you'll have built a solid foundation in DevOps, and developed the skills necessary to enhance a traditional software delivery process using modern software delivery tools and techniques
Table of Contents (23 chapters)
Free Chapter
1
Section 1: DevOps and Infrastructure as Code
6
Section 2: DevOps CI/CD Pipeline
9
Section 3: Containerized Applications with Docker and Kubernetes
12
Section 4: Testing Your Application
16
Section 5: Taking DevOps Further

To get the most out of this book

No development knowledge is required to understand this book. The only languages you will see are declarative languages such as JSON or YAML. In addition to this, no specific IDE is required. If you do not have one, you can use Visual Studio Code, which is free and cross-platform. It is available here: https://code.visualstudio.com/.

As regards the operating systems you will need, there are no real prerequisites. Most of the tools we will use are cross-platform and compatible with Windows, Linux, and macOS. Their installations will be detailed in their respective chapters.

The cloud provider that serves as an example in this book is Microsoft Azure. If you don't have a subscription, you can create a free account here: https://azure.microsoft.com/en-us/free/.

Download the example code files

You can download the example code files for this book from your account at www.packt.com. If you purchased this book elsewhere, you can visit www.packtpub.com/support and register to have the files emailed directly to you.

You can download the code files by following these steps:

  1. Log in or register at www.packt.com.
  2. Select the Support tab.
  3. Click on Code Downloads.
  4. Enter the name of the book in the Search box and follow the onscreen instructions.

Once the file is downloaded, please make sure that you unzip or extract the folder using the latest version of:

  • WinRAR/7-Zip for Windows
  • Zipeg/iZip/UnRarX for Mac
  • 7-Zip/PeaZip for Linux

The code bundle for the book is also hosted on GitHub at https://github.com/PacktPublishing/Learning_DevOps. In case there's an update to the code, it will be updated on the existing GitHub repository.

We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing/. Check them out!

Download the color images

Code in Action

Conventions used

There are a number of text conventions used throughout this book.

CodeInText: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "To execute the initialization, run the init command."

A block of code is set as follows:

resource "azurerm_resource_group" "rg" {
name = var.resoure_group_name
location = var.location
tags {
environment = "Terraform Azure"
}

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

resource "azurerm_resource_group" "rg" {
name = "bookRg"
location = "West Europe"
tags {
environment = "Terraform Azure"
}
}

Any command-line input or output is written as follows:

git push origin master

Bold: Indicates a new term, an important word, or words that you see on screen. For example, words in menus or dialog boxes appear in the text like this. Here is an example: "Choose the integration of Git in Windows Explorer by marking the Windows Explorer integration checkbox."

Warnings or important notes appear like this.
Tips and tricks appear like this.