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

Using the kubectl get command

The first essential command to run is kubectl get nodes. It gives us the number of Kubernetes nodes available:

$ kubectl get nodes
NAME STATUS ROLES AGE VERSION
minikube Ready <none> 2h v1.9.0

In our case, the number of nodes will be equal to one, since we are using one VM for our practice. As we mentioned already, in order for different projects to coexist on the same or different nodes, namespaces are used. You may guess that the command we should use is kubectl get namespaces:

$ kubectl get namespaces
NAME STATUS AGE
default Active 15h
kube-public Active 15h
kube-system Active 15h

It says No resources found, all because the pod is a Kubernetes resource, similar to other resources we are going to cover in this book.

Similarly to kubectl get pods, you can get the status of any other Kubernetes resource. We will discuss other Kubernetes resources later in this chapter.  
主站蜘蛛池模板: 义马市| 宁德市| 甘肃省| 昆明市| 阜新| 延吉市| 福贡县| 英吉沙县| 临猗县| 陈巴尔虎旗| 祁阳县| 侯马市| 资阳市| 舞阳县| 黑河市| 淮北市| 利辛县| 缙云县| 岫岩| 日喀则市| 剑川县| 金平| 甘德县| 徐闻县| 肃北| 清镇市| 邢台县| 宜川县| 余江县| 景宁| 株洲县| 安塞县| 清河县| 鞍山市| 嫩江县| 阜南县| 靖西县| 焉耆| 永丰县| 道孚县| 阜城县|