Why are so many companies adopting GitOps for their DevOps and cloud native strategy? This reliable framework is quickly becoming the standard method for deploying apps to Kubernetes. With this practical, developer-oriented book, DevOps engineers, developers, IT architects, and SREs will learn the most useful recipes and examples for following GitOps practices.
Through their years of experience in application modernization, CI/CD, and automation, authors Alex Soto Bueno and Natale Vinto from Red Hat walk you through all the steps necessary for successful hands-on application development and deployment with GitOps. Once you start using the recipes in this book, you'll have a head start in development cycles on Kubernetes following the GitOps approach.
You'll learn how to:
• Develop and deploy applications on Kubernetes
• Understand the basics of CI/CD and automation on Kubernetes, and apply GitOps practices to
• Implement development cycles on the platform
• Prepare the app for deployment on multiple environments and/or multiple Kubernetes clusters
• Deploy apps for either multiple environments using GitOps and Argo CD, or for Kubernetes clusters
• Create Kubernetes-native pipelines with Tekton
• Provide and extend DevOps skills for the team working on Kubernetes
• Use progressive delivery to put your applications into production
Author(s): Natale Vinto, Alex Bueno
Edition: 1
Publisher: O'Reilly Media
Year: 2023
Language: English
Commentary: Publisher's PDF
Pages: 242
City: Sebastopol, CA
Tags: DevOps; Security; Cookbook; Docker; Deployment; GitHub; Continuous Delivery; Kubernetes; Continuous Integration; Automation; Infrastructure as Code; Helm; Docker Hub; GitOps; Argo CD; Containers; Kustomize; Tekton
Cover
Copyright
Table of Contents
Foreword
Preface
Conventions Used in This Book
Using Code Examples
O’Reilly Online Learning
How to Contact Us
Acknowledgments
Alex Soto
Natale Vinto
Chapter 1. Introduction
1.1 What Is GitOps?
1.2 Why GitOps?
1.3 Kubernetes CI/CD
1.4 App Deployment with GitOps on Kubernetes
1.5 DevOps and Agility
Chapter 2. Requirements
2.1 Registering for a Container Registry
Problem
Solution
Discussion
See Also
2.2 Registering for a Git Repository
Problem
Solution
Discussion
See Also
2.3 Creating a Local Kubernetes Cluster
Problem
Solution
Discussion
See Also
Chapter 3. Containers
3.1 Building a Container Using Docker
Problem
Solution
Discussion
See Also
3.2 Building a Container Using Dockerless Jib
Problem
Solution
Discussion
See Also
3.3 Building a Container Using Buildah
Problem
Solution
Discussion
See Also
3.4 Building a Container with Buildpacks
Problem
Solution
Discussion
See Also
3.5 Building a Container Using Shipwright and kaniko in Kubernetes
Problem
Solution
Discussion
3.6 Final Thoughts
Chapter 4. Kustomize
4.1 Using Kustomize to Deploy Kubernetes Resources
Problem
Solution
Discussion
See Also
4.2 Updating the Container Image in Kustomize
Problem
Solution
Discussion
4.3 Updating Any Kubernetes Field in Kustomize
Problem
Solution
Discussion
See Also
4.4 Deploying to Multiple Environments
Problem
Solution
Discussion
4.5 Generating ConfigMaps in Kustomize
Problem
Solution
Discussion
See Also
4.6 Final Thoughts
Chapter 5. Helm
5.1 Creating a Helm Project
Problem
Solution
Discussion
See Also
5.2 Reusing Statements Between Templates
Problem
Solution
Discussion
5.3 Updating a Container Image in Helm
Problem
Solution
Discussion
5.4 Packaging and Distributing a Helm Chart
Problem
Solution
Discussion
See Also
5.5 Deploying a Chart from a Repository
Problem
Solution
Discussion
5.6 Deploying a Chart with a Dependency
Problem
Solution
5.7 Triggering a Rolling Update Automatically
Problem
Solution
5.8 Final Thoughts
Chapter 6. Cloud Native CI/CD
6.1 Install Tekton
Problem
Solution
See Also
6.2 Create a Hello World Task
Problem
Solution
See Also
6.3 Create a Task to Compile and Package an App from Git
Problem
Solution
See Also
6.4 Create a Task to Compile and Package an App from Private Git
Problem
Solution
See Also
6.5 Containerize an Application Using a Tekton Task and Buildah
Problem
Solution
See Also
6.6 Deploy an Application to Kubernetes Using a Tekton Task
Problem
Solution
See Also
6.7 Create a Tekton Pipeline to Build and Deploy an App to Kubernetes
Problem
Solution
See Also
6.8 Using Tekton Triggers to Compile and Package an Application Automatically When a Change Occurs on Git
Problem
Solution
See Also
6.9 Update a Kubernetes Resource Using Kustomize and Push the Change to Git
Problem
Solution
6.10 Update a Kubernetes Resource Using Helm and Create a Pull Request
Problem
Solution
6.11 Use Drone to Create a Pipeline for Kubernetes
Problem
Solution
See Also
6.12 Use GitHub Actions for CI
Problem
Solution
See Also
Chapter 7. Argo CD
7.1 Deploy an Application Using Argo CD
Problem
Solution
Discussion
7.2 Automatic Synchronization
Problem
Solution
Discussion
See Also
7.3 Kustomize Integration
Problem
Solution
Discussion
See Also
7.4 Helm Integration
Problem
Solution
Discussion
See Also
7.5 Image Updater
Problem
Solution
Discussion
See Also
7.6 Deploy from a Private Git Repository
Problem
Solution
Discussion
7.7 Order Kubernetes Manifests
Problem
Solution
Discussion
See Also
7.8 Define Synchronization Windows
Problem
Solution
Discussion
Chapter 8. Advanced Topics
8.1 Encrypt Sensitive Data (Sealed Secrets)
Problem
Solution
8.2 Encrypt Secrets with ArgoCD (ArgoCD + HashiCorp Vault + External Secret)
Problem
Solution
8.3 Trigger the Deployment of an Application Automatically (Argo CD Webhooks)
Problem
Solution
8.4 Deploy to Multiple Clusters
Problem
Solution
Discussion
See Also
8.5 Deploy a Pull Request to a Cluster
Problem
Solution
Discussion
8.6 Use Advanced Deployment Techniques
Problem
Solution
Discussion
See Also
Index
About the Authors