官术网_书友最值得收藏!

  • The Kubernetes Workshop
  • Zachary Arnold Sahil Dua Wei Huang Faisal Masood Melony Qin Mohammed Abu Taleb
  • 383字
  • 2021-06-11 18:17:56

Introduction

In Chapter 1, Introduction to Kubernetes and Containers, we saw that Kubernetes is a portable and highly extensible open-source container orchestration tool. It provides very powerful capabilities that can be used to manage containerized workloads at scale. In the previous chapter, you got the big picture of how the different components of Kubernetes work together to achieve the desired goals. We also demonstrated some basic usage of kubectl in Chapter 2, An Overview of Kubernetes. In this chapter, we will take a closer look at this utility and look at how we can make use of its potential.

To reiterate, kubectl is a command-line utility for interacting with Kubernetes clusters and performing various operations. There are two ways to use kubectl while managing your cluster - imperative management, which focuses on commands rather than the YAML manifests to achieve the desired state, and declarative management, which focuses on creating and updating YAML manifest files. kubectl can support both these management techniques to manage Kubernetes API objects (also called Kubernetes API primitives). In the previous chapter, we saw how the various components constantly try to change the state of the cluster from the actual state to the desired state. This can be achieved by using kubectl commands or YAML manifests.

kubectl allows you to send commands to Kubernetes clusters. The kubectl command can be used to deploy applications, inspect, and manage Kubernetes objects, or troubleshoot and view logs. Interestingly, even though kubectl is the standard tool for controlling and communicating with a Kubernetes cluster, it doesn't come with Kubernetes. So, even if you are running kubectl on any of the nodes of your cluster, you need to install the kubectl binary separately, which we did in Exercise 2.01, Getting Started with Minikube and Kubernetes Clusters, in the previous chapter.

This chapter will walk you through the behind-the-scenes functionality of kubectl and provide more insights into how to use kubectl commands to interact with some commonly used Kubernetes objects. We will learn how to set up some shortcuts for kubectl. We will walk you through not only creating new objects with kubectl but also making changes to a live Deployment in Kubernetes. But before that, let's take a peek behind the curtains and get an idea of exactly how kubectl communicates with Kubernetes.

主站蜘蛛池模板: 元氏县| 双流县| 巧家县| 宜章县| 西藏| 沛县| 中牟县| 山东| 建德市| 南丰县| 全州县| 楚雄市| 敦煌市| 高密市| 永城市| 简阳市| 宜兰市| 兰坪| 双江| 甘德县| 沙河市| 敦煌市| 桃园县| 元谋县| 梁平县| 阳谷县| 北流市| 漯河市| 兖州市| 嘉祥县| 阳城县| 兰州市| 当涂县| 沙雅县| 阳新县| 镇巴县| 孙吴县| 顺义区| 浠水县| 得荣县| 天水市|