Book Image

Kubernetes – An Enterprise Guide - Second Edition

By : Marc Boorshtein, Scott Surovich
Book Image

Kubernetes – An Enterprise Guide - Second Edition

By: Marc Boorshtein, Scott Surovich

Overview of this book

Kubernetes has taken the world by storm, becoming the standard infrastructure for DevOps teams to develop, test, and run applications. With significant updates in each chapter, this revised edition will help you acquire the knowledge and tools required to integrate Kubernetes clusters in an enterprise environment. The book introduces you to Docker and Kubernetes fundamentals, including a review of basic Kubernetes objects. You’ll get to grips with containerization and understand its core functionalities such as creating ephemeral multinode clusters using KinD. The book has replaced PodSecurityPolicies (PSP) with OPA/Gatekeeper for PSP-like enforcement. You’ll integrate your container into a cloud platform and tools including MetalLB, externalDNS, OpenID connect (OIDC), Open Policy Agent (OPA), Falco, and Velero. After learning to deploy your core cluster, you’ll learn how to deploy Istio and how to deploy both monolithic applications and microservices into your service mesh. Finally, you will discover how to deploy an entire GitOps platform to Kubernetes using continuous integration and continuous delivery (CI/CD).
Table of Contents (17 chapters)
15
Other Books You May Enjoy
16
Index

Questions

  1. Are OPA and Gatekeeper the same thing?
    1. Yes
    2. No
  2. How is Rego code stored in Gatekeeper?
    1. It is stored as ConfigMap objects that are watched
    2. Rego has to be mounted to the Pod
    3. Rego needs to be stored as secret objects
    4. Rego is saved as a ConstraintTemplate
  3. How do you test Rego policies?
    1. In production
    2. Using an automated framework built directly into OPA
    3. By first compiling to WebAssembly
  4. In Rego, how do you write a for loop?
    1. You don't need to; Rego will identify iterative steps.
    2. By using the for all syntax.
    3. By initializing counters in a loop.
    4. There are no loops in Rego.
  5. What is the best way to debug Rego policies?
    1. Use an IDE to attach to the Gatekeeper container in a cluster
    2. In production
    3. Add trace functions to your code and...